top of page

Software

Public·131 members

Problem with Opencat.ino

Sorry again, just asking if someone can walk we through this error messages I got while verifying Opencat.ino



Arduino: 1.8.12 (Windows 10), Board: "Arduino Nano, ATmega328P (Old Bootloader)"


In file included from C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:27:0:


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-9.0e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


};


^


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-4.5e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-9.0e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-4.5e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '9.0e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-4.5e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '9.0e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


sketch\WriteInstinct/OpenCat.h:858:1: warning: narrowing conversion of '-4.5e+1' from 'double' to 'int8_t {aka signed char}' inside { } [-Wnarrowing]


In file included from C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:30:0:


sketch\src/mpu6050/MPU6050_6Axis_MotionApps20.h: In member function 'uint8_t MPU6050::dmpGetGravity(int16_t*, const uint8_t*)':


sketch\src/mpu6050/MPU6050_6Axis_MotionApps20.h:524:65: warning: integer overflow in expression [-Woverflow]


- (int32_t)qI[2] * qI[2] + (int32_t)qI[3] * qI[3]) / (2 * 16384);


~~^~~~~~~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino: At global scope:


OpenCat:86:15: error: 'IR_RECIEVER' was not declared in this scope


IRrecv irrecv(IR_RECIEVER); // create instance of 'irrecv'


^~~~~~~~~~~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:86:15: note: suggested alternative: 'IR_RECEIVER'


IRrecv irrecv(IR_RECIEVER); // create instance of 'irrecv'


^~~~~~~~~~~


IR_RECEIVER


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino: In function 'void getYPR()':


OpenCat:252:11: error: 'printGyro' was not declared in this scope


if (printGyro)


^~~~~~~~~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:252:11: note: suggested alternative: 'printList'


if (printGyro)


^~~~~~~~~


printList


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino: In function 'void loop()':


OpenCat:514:14: error: 'T_PRINT_GYRO' was not declared in this scope


case T_PRINT_GYRO: {


^~~~~~~~~~~~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:514:14: note: suggested alternative: 'T_GYRO'


case T_PRINT_GYRO: {


^~~~~~~~~~~~


T_GYRO


OpenCat:518:14: error: 'T_VERBOSELY_PRINT_GYRO' was not declared in this scope


case T_VERBOSELY_PRINT_GYRO: {


^~~~~~~~~~~~~~~~~~~~~~


OpenCat:519:13: error: 'printGyro' was not declared in this scope


printGyro = !printGyro;


^~~~~~~~~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:519:13: note: suggested alternative: 'printList'


printGyro = !printGyro;


^~~~~~~~~


printList


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino:556:40: warning: invalid conversion from 'const char*' to 'char*' [-fpermissive]


char* list = inBuffer.c_str();


~~~~~~~~~~~~~~^~


C:\Users\Ale\Documents\Arduino\OpenCat-main\OpenCat\OpenCat.ino: At global scope:


OpenCat:855:1: error: expected declaration before '}' token


}


^


exit status 1

'IR_RECIEVER' was not declared in this scope


This report would have more information with

"Show verbose output during compilation"

option enabled in File -> Preferences.


88 Views
Rongzhong Li
Rongzhong Li
Feb 26, 2022

After unzipping OpenCat-main, you need to delete the -main suffix in the folder's name. It's noted here: https://bittle.petoi.com/4-configuration#4.2.7.-download-the-opencat-package

bottom of page