I've cut my non working program down to a bare minimum.
I have a function that open a file on an SD Card, appends to it and closes it.
If I cut the code out of the function and put it in the main loop, it works,
If I make it a function and call that from the main loop, it works.
If I attach it to a ticker, and ask it to tick every 2 secs for instance.
It ticks once, then my mbed hangs.. (not even the LED1 in my main loop which should flash, flashes)
It doesn't do the strobing lights of death either, it just stops.
any ideas ?
I've published the code here..
http://mbed.org/users/DaveStyles/programs/16mhst
any help gratefully received as always.
PS. please don't laugh at the way I'm writing to the file, I'll tidy when I get a mo.. and at least that works as I want it to. (it writes time elapsed from booting mbed up)
I've cut my non working program down to a bare minimum.
I have a function that open a file on an SD Card, appends to it and closes it.
If I cut the code out of the function and put it in the main loop, it works,
If I make it a function and call that from the main loop, it works.
If I attach it to a ticker, and ask it to tick every 2 secs for instance.
It ticks once, then my mbed hangs.. (not even the LED1 in my main loop which should flash, flashes)
It doesn't do the strobing lights of death either, it just stops.
any ideas ?
I've published the code here..
http://mbed.org/users/DaveStyles/programs/16mhst
any help gratefully received as always.
PS. please don't laugh at the way I'm writing to the file, I'll tidy when I get a mo.. and at least that works as I want it to. (it writes time elapsed from booting mbed up)