I am having issues setting bool variables. It seems they randomly don't set correctly. If I change the variable name to something completely different, they start to work. If I change it back to the name that wasn't working, they stop working again. I have checked that I am not using any reserved names.
For example the below code prints that flashFlood is false:
Any thoughts? I have a similar problem with other variable names. It seems that there is about a 50% chance a certain name won't work with booleans? I am using an Arduino MKR NB1500 in the Arduino IDE. I have tried on 2 different MKRs with the same result.
C:\Users\sterretje\Documents\Arduino\rc9\test_changeBoard\test_changeBoard.ino:5:16: error: no matching function for call to 'Serial_::begin()'
Serial.begin();
^
To ask, as @twist27896 did, if (1 <= 2) is "technically correct" (whatever that may mean), although the answer is of course always going to be false oops true. They were obviously using that as a way to force the program flow into one specific half of the if structure, in much the same was as one might force a stop in a program with a while(1) which is always true.
I tried compiling and uploading on a different laptop and it fixed the issue. I reinstalled the Arduino IDE and it works on the original laptop now as well. This fix doesn't really make sense but I guess it works...