[clang] Relational comparison result unused

I have received the error “[clang] Relational comparison result unused” and I don’t know how to fix it. I am trying to set up a pre-auton code that will vibrate when the battery goes lower than 75%. Thank you in advance.

  • Hailey

Hi @hailey_harder, any chance you can post the code?

yos give me a moment

void pre_auton(void) {
 if (true){
   // Initializing Robot Configuration. DO NOT REMOVE!

i havent fully fineshed it but this i what i have so far. the part that is giving me the error is "brain.battery.compacity()<50;

also sorry for the bad spelling

Thanks, you want the brain.battery part to be inside an if statement.

If ( brain.battery < 75 ) vibrate


Thank you so much, I appreciate it!

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.