Skip to content
Snippets Groups Projects
Commit 0ddf452a authored by Jake Read's avatar Jake Read
Browse files

flash on halt

parent 607eff3a
No related branches found
No related tags found
No related merge requests found
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
#include "osape_arduino/vp_arduinoSerial.h" #include "osape_arduino/vp_arduinoSerial.h"
#include "osape_ucbus/vb_ucBusDrop.h" #include "osape_ucbus/vb_ucBusDrop.h"
OSAP osap("axl-stepper_y"); OSAP osap("axl-stepper_x");
VPort_ArduinoSerial vpUSBSerial(&osap, "arduinoUSBSerial", &Serial); VPort_ArduinoSerial vpUSBSerial(&osap, "arduinoUSBSerial", &Serial);
...@@ -83,8 +83,12 @@ void updateStatesEP(void){ ...@@ -83,8 +83,12 @@ void updateStatesEP(void){
// -------------------------------------------------------- 3: Halt // -------------------------------------------------------- 3: Halt
uint32_t haltLightOnTime = 0;
EP_ONDATA_RESPONSES onHaltData(uint8_t* data, uint16_t len){ EP_ONDATA_RESPONSES onHaltData(uint8_t* data, uint16_t len){
axl_halt(); axl_halt();
ERRLIGHT_ON;
haltLightOnTime = millis();
return EP_ONDATA_REJECT; return EP_ONDATA_REJECT;
} }
...@@ -222,6 +226,9 @@ void loop() { ...@@ -222,6 +226,9 @@ void loop() {
updateStatesEP(); updateStatesEP();
//axl_printHomeState(); //axl_printHomeState();
} }
if(haltLightOnTime + 250 < millis()){
ERRLIGHT_OFF;
}
} }
// -------------------------------------------------------- Small-Time Ops // -------------------------------------------------------- Small-Time Ops
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment