lots of stuff

This commit is contained in:
2025-08-26 16:10:47 -05:00
parent 372e4941a2
commit bbc9d6ae91
27 changed files with 1193 additions and 147 deletions

View File

@@ -78,10 +78,7 @@ ClampData_t clampData;
bool isUsbConnected(void)
{
return GPIO_READ(PIN_VBUS);
}
static char tmpString[32];
static bool _firstInit = true;
@@ -142,7 +139,7 @@ static void init(void)
//Safety_Check(); // Check all voltages are safe to continue in DC.
Check_Bat_Id(); // Check for Alkaline or Lithium and battery insertion error.
battery_checkId(); // Check for Alkaline or Lithium and battery insertion error.
@@ -173,6 +170,7 @@ int main(void)
static uint32_t tickCount = 0;
sys.usbConnected = isUsbConnected();
sys.status[USB_CONNECTED] = isUsbConnected();
USB_Update(); //Update USB here so we're outside the ISR
@@ -186,7 +184,6 @@ int main(void)
//setSafeMode(true);
}
Display_USB();
}
else
{
@@ -233,6 +230,7 @@ int main(void)
// check for accessories
ACCY_service();
driver_service();
uint32_t pressed = 0;
@@ -277,11 +275,9 @@ int main(void)
case MODE_KEY:
{
//mode_menu();
// test accessory state machine
ACCY_next();
//ACCY_setActive(&sys.ports[ACCY_PORT_INDUCTION], CHANNEL_A);
//io_setOutputPort(ACCY_PORT_2, CHANNEL_B);
break;
}
@@ -297,20 +293,7 @@ int main(void)
break;
}
#if 0
case PWR_DN_KEY:
{
if(Key_Lock_Out_tmr == 0)
{
Vchktmr = LOCK_OUT_DELAY;
dec_pwr();// decrement the power output
Key_Lock_Out_tmr = KEY_LOCK_TIME;
Suspend_Step_Chk = false;
step_count = 0;
}
break;
}
#endif
}
Display_Update();