With the current Arduino 2.1.1 and Heltec CubeCell 1.5 the File/Examples/Basics/Factory_Test/Factory_Test_AB02S uses the User button to select testing LoRa, Sleep, GPS But how? I just get a blank screen:
void userKey(void)
{
delay(10);
if(digitalRead(P3_3)==0)
{
uint16_t keyDownTime = 0;
while(digitalRead(P3_3)==0)
{
delay(1);
keyDownTime++;
if(keyDownTime>=700)
break;
}
if(keyDownTime<700)
{
state = LOWPOWER;
sleepMode = true;
}
else
{
state = GPSTEST;
detachInterrupt(RADIO_DIO_1);
Radio.Sleep( );
turnOnRGB(0,0);
GPS.begin();
}
}
}
If the time the user key is pressed is greater then 700 break or less then 700 sleep then the GPS test is an ELSE? How does it get to the ELSE to do the GPS test?