Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: insn does not satisfy its constraints: 555 | } #34

Open
charansaitiru opened this issue Aug 16, 2024 · 0 comments
Open

error: insn does not satisfy its constraints: 555 | } #34

charansaitiru opened this issue Aug 16, 2024 · 0 comments

Comments

@charansaitiru
Copy link

I am only getting error for this part of SETTING MENU ITEM CHARGING CURRENT code rest part of the code is fine...

`///// SETTINGS MENU ITEM: CHARGING CURRENT /////
else if(subMenuPage==4)
{
lcd.setCursor(0,0);lcd.print("CHARGING CURRENT");
if(setMenuPage==1){lcd.setCursor(0,1);lcd.print(" >");}
else{lcd.setCursor(0,1);lcd.print("= ");
}
lcd.setCursor(2,1);lcd.print(currentCharging,2);lcd.print("A");
lcd.print(" ");

  //SET MENU - FLOATTYPE
  if(setMenuPage==0){floatTemp = currentCharging;}
  else
  {
    if(digitalRead(buttonBack)==1){while(digitalRead(buttonBack)==1){}currentCharging = floatTemp;cancelledMessageLCD();setMenuPage=0;} 
    if(digitalRead(buttonSelect)==1){while(digitalRead(buttonSelect)==1){}saveSettings();setMenuPage=0;savedMessageLCD();}     
    currentMenuSetMillis = millis();
    if(digitalRead(buttonRight)==1)
    {                                                  //Right button press (increments setting values)
      while(digitalRead(buttonRight)==1)
      {
        if(millis()-currentMenuSetMillis>longPressTime)
        {                              //Long Press     
          currentCharging += 1.00;                                                    //Increment by 1
          currentCharging = constrain(currentCharging,0.0,cOutSystemMax);             //Limit settings values to a range
          lcd.setCursor(2,1);lcd.print(currentCharging,2);delay(longPressInterval);   //Display settings data                               
        }
        else
        {                                                                         //Short Press  
          currentCharging += 0.01;                                                    //Increment by 0.01
          currentCharging = constrain(currentCharging,0.0,cOutSystemMax);             //Limit settings values to a range
          lcd.setCursor(2,1);lcd.print(currentCharging,2);delay(shortPressInterval);  //Display settings data                            
        }  
        lcd.print("A   ");                                                            //Display unit
      } 
    }
    else if(digitalRead(buttonLeft)==1)
    {                                              //Left button press (decrements setting values)
      while(digitalRead(buttonLeft)==1)
      {
        if(millis()-currentMenuSetMillis>longPressTime)
        {                              //Long Press     
          currentCharging -= 1.00;                                                    //Increment by 1
          currentCharging = constrain(currentCharging,0.0,cOutSystemMax);             //Limit settings values to a range
          lcd.setCursor(2,1);lcd.print(currentCharging,2);delay(longPressInterval);   //Display settings data                               
        }
        else
        {                                                                         //Short Press  
          currentCharging -= 0.01;                                                    //Increment by 0.01
          currentCharging =  constrain(currentCharging,0.0,cOutSystemMax);            //Limit settings values to a range
          lcd.setCursor(2,1);lcd.print(currentCharging,2);delay(shortPressInterval);  //Display settings data                                      
        } 
        lcd.print("A   ");                                                            //Display unit
      } 
    }
  } 
}`

ERROR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant