2025-11-28 18:26:32 -06:00
|
|
|
#ifndef DEFINES_H
|
|
|
|
|
#define DEFINES_H
|
|
|
|
|
|
|
|
|
|
#define ccwSpeed 6500
|
|
|
|
|
#define cwSpeed 3300
|
|
|
|
|
#define offSpeed 4900
|
|
|
|
|
|
|
|
|
|
#define ccwMax 10
|
|
|
|
|
#define cwMax 0
|
2025-12-18 15:01:25 -06:00
|
|
|
#define nvsWiFi "WiFiCreds"
|
|
|
|
|
#define ssidTag "SSID"
|
|
|
|
|
#define passTag "PW"
|
|
|
|
|
#define authTag "AuthMode"
|
|
|
|
|
#define unameTag "UNAME"
|
2025-12-18 22:08:07 -06:00
|
|
|
#define nvsAuth "AUTH"
|
|
|
|
|
#define tokenTag "TOKEN"
|
2025-11-28 18:26:32 -06:00
|
|
|
|
|
|
|
|
#define getMovingCW(port) ((movingCW & (1 << port)) >> port)
|
|
|
|
|
#define setMovingCW(port) (movingCW |= (1 << port))
|
|
|
|
|
#define clearMovingCW(port) (movingCW &= ~(1 << port))
|
|
|
|
|
#define getMovingCCW(port) ((movingCCW & (1 << port)) >> port)
|
|
|
|
|
#define setMovingCCW(port) (movingCCW |= (1 << port))
|
|
|
|
|
#define clearMovingCCW(port) (movingCCW &= ~(1 << port))
|
|
|
|
|
#define getCalibCW(port) ((calibCW & (1 << port)) >> port)
|
|
|
|
|
#define setCalibCW(port) (calibCW |= (1 << port))
|
|
|
|
|
#define clearCalibCW(port) (calibCW &= ~(1 << port))
|
|
|
|
|
#define getCalibCCW(port) ((calibCCW & (1 << port)) >> port)
|
|
|
|
|
#define setCalibCCW(port) (calibCCW |= (1 << port))
|
|
|
|
|
#define clearCalibCCW(port) (calibCCW &= ~(1 << port))
|
|
|
|
|
#define getCalibDone(port) ((calibDone & (1 << port)) >> port)
|
|
|
|
|
#define setCalibDone(port) (calibDone |= (1 << port))
|
|
|
|
|
#define clearCalibDone(port) (calibDone &= ~(1 << port))
|
|
|
|
|
#define getBlocked(port) ((blocked & (1 << port)) >> port)
|
|
|
|
|
#define setBlocked(port) (blocked |= (1 << port))
|
|
|
|
|
#define clearBlocked(port) (blocked &= ~(1 << port))
|
|
|
|
|
#define getPos10(port) ((movingCCW & (1 << (port + 4))) >> (port + 4))
|
|
|
|
|
#define setPos10(port) (movingCCW |= (1 << (port + 4)))
|
|
|
|
|
#define clearPos10(port) (movingCCW &= ~(1 << (port + 4)))
|
|
|
|
|
#define getPos0(port) ((movingCW & (1 << (port + 4))) >> (port + 4))
|
|
|
|
|
#define setPos0(port) (movingCW |= (1 << (port + 4)))
|
|
|
|
|
#define clearPos0(port) (movingCW &= ~(1 << (port + 4)))
|
|
|
|
|
|
|
|
|
|
#define prefNameCalibs "periph_info_"
|
|
|
|
|
|
|
|
|
|
#endif
|