Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of test_shutter by
Revision 3:e00270ed0259, committed 2013-06-25
- Comitter:
- sam_grove
- Date:
- Tue Jun 25 05:09:09 2013 +0000
- Parent:
- 2:ec6da58dab61
- Commit message:
- change interval time to a define
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Mon Apr 29 04:05:47 2013 +0000 +++ b/main.cpp Tue Jun 25 05:09:09 2013 +0000 @@ -26,8 +26,9 @@ #define US_INTERVAL 500 //set the resolution of the timing information -#define MS_INTERVAL 1 //interval used to change the counter display -#define WAIT_KNOWN_MS 125 // known delay between trigger and shutter time (allows to better use 4 leds) +#define MS_INTERVAL 1 //interval used to change the counter display +#define WAIT_KNOWN_MS 145 // known delay between trigger and shutter time (allows to better use 4 leds) +#define TRIGGER_INTERVAL 7.5f // amount of time between triggers void resetLed() { @@ -75,7 +76,7 @@ resetLed(); //trig is a ticker used to repeatedly fire a trigger at the interval (e.g., 7.5 secs) - trig.attach(&setTrig, 7.5f); //set ticker interval to 7.5secs + trig.attach(&setTrig, TRIGGER_INTERVAL); //set ticker interval to 7.5secs // start the program while(1)