Search found 3821 matches
- Mon Apr 27, 2015 5:25 am
- Forum: MicroPython pyboard
- Topic: low power support?
- Replies: 26
- Views: 23544
Re: low power support?
During a normal boot, the green LED is turned on here: https://github.com/micropython/micropython/blob/master/stmhal/main.c#L317 and turned off here: https://github.com/micropython/micropython/blob/master/stmhal/main.c#L470 So that adds virtually no delay. I think you'd need to profile the boot to s...
- Sun Apr 26, 2015 8:05 pm
- Forum: Other Boards
- Topic: Installing Micropython on a blank STM
- Replies: 24
- Views: 20065
Re: Installing Micropython on a blank STM
The next thing is to make sure that the firmware was configured with the crystal frequency you're actually using. The pyboard uses an 8Mhz crystal. I did a port to the Cerb40 II, which is basically just a 405 on a DIP carrier. If you look at stmhal/boards/CERB40 you can see the files which were crea...
- Sun Apr 26, 2015 2:34 am
- Forum: Other Boards
- Topic: Installing Micropython on a blank STM
- Replies: 24
- Views: 20065
Re: Installing Micropython on a blank STM
Thanks- that helps a lot. Looks like I missed several things, especially the tricky little circuit on the bottom of P19. It appears you have to pull USB-DP up to 3.3V, although I don't see where that happens on the Pyboard.... Still don't have it working, but I have a bunch of things to try. Those ...
- Sat Apr 25, 2015 11:12 pm
- Forum: Other Boards
- Topic: Installing Micropython on a blank STM
- Replies: 24
- Views: 20065
Re: Installing Micropython on a blank STM
You didn't mention BOOT1. I believe it has to be low and BOOT0 has to be high (at RESET time) to enter DFU mode. There are a bunch of other pins which need to have pullups/pulldowns on them. See this document: http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf Page ...
- Fri Apr 24, 2015 10:51 pm
- Forum: MicroPython pyboard
- Topic: Using git revision to program on the pyboard
- Replies: 10
- Views: 8249
Re: Using git revision to program on the pyboard
The only caution I have is that sometimes the pyboard will decide to erase it's flash memory (I've had this happen - typically when I'm messing around with interrupts and such). If that happens, then you'll lose all of the your changes since the last commit. I use git repositories as well, but I ten...
- Fri Apr 24, 2015 3:39 pm
- Forum: MicroPython pyboard
- Topic: Which firmware version do I have installed?
- Replies: 11
- Views: 54683
Re: Which firmware version do I have installed?
Perhaps to help demystify the GC (garbage collector) a bit. When python needs to allocate memory, it goes to the heap, and tries to allocate it. If the allocation succeeds, then life is good and your program continues. If, however, the allocation fails, then the GC is run. The GC figures out which c...
- Wed Apr 22, 2015 10:04 pm
- Forum: General Discussion and Questions
- Topic: Simulating Tone
- Replies: 7
- Views: 6482
Re: Simulating Tone
I'm thinking so.
Now that you've confirmed that resetting the counter to zero fixes the problem, I've created a pull request to fix freq and period so that they reset the counter to zero.
Now that you've confirmed that resetting the counter to zero fixes the problem, I've created a pull request to fix freq and period so that they reset the counter to zero.
- Wed Apr 22, 2015 6:26 pm
- Forum: General Discussion and Questions
- Topic: Simulating Tone
- Replies: 7
- Views: 6482
Re: Simulating Tone
I think I would reorder this slightly and make it:
Code: Select all
for i in note:
tim.freq(i)
ch.pulse_width_percent(20)
tim.counter(0)
print(i)
pyb.delay(300)
- Wed Apr 22, 2015 6:18 pm
- Forum: General Discussion and Questions
- Topic: Simulating Tone
- Replies: 7
- Views: 6482
Re: Simulating Tone
I have a guess as to what's happening. The way that the timers work is that they have a counter and a limit (reload register). When the counter reaches the limit (i.e. is equal to) then it gets reinitialized to zero and continues to count. If the current counter value is larger than the limit regist...
- Tue Apr 21, 2015 8:54 pm
- Forum: Hardware Projects
- Topic: Self balancing robot
- Replies: 49
- Views: 71886