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.
Dependencies: mbed mbed-rtos Linear_Stepper_Motor_Nema17
Fork of Sliding_Camera_Rail by
Diff: main.cpp
- Revision:
- 3:e1fd0b211fcd
- Parent:
- 2:7facfc9e53ff
--- a/main.cpp Wed Apr 29 03:04:02 2020 +0000 +++ b/main.cpp Wed Apr 29 04:04:00 2020 +0000 @@ -25,8 +25,8 @@ /*********** * Hardware * ***********/ -LinStepMtr mtr(p19, p20, p17, p18); // for linear motor, coresponds to A,A\,B,B\ -BusOut lights (LED4,LED3,LED2,LED1); +LinStepMtr mtr(p19, p20, p17, p18); // for linear motor, coresponds to A,A\,B,B\ on motor leads +BusOut lights(LED4,LED3,LED2,LED1); //Serial xbee(USBTX,USBRX); Serial xbee(p28,p27); DigitalOut xbee_rst(p26); //Digital reset for the XBee, 200ns for reset @@ -213,7 +213,6 @@ } } } - } // blinks leds a set number of times with a wait time of w @@ -227,6 +226,7 @@ } lights = OFF; Thread::wait(w); + } // reads flag variables to control LED status lights @@ -326,7 +326,7 @@ // Start Threads Thread input(read_input); - Thread lights(status_lights); + Thread stat_lights(status_lights); wait(.001);;