Skip to content

RH library can not be compiled under PlatformIO #5

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

Open
sporubcan opened this issue Mar 20, 2025 · 0 comments
Open

RH library can not be compiled under PlatformIO #5

sporubcan opened this issue Mar 20, 2025 · 0 comments

Comments

@sporubcan
Copy link

platformio.ini
[env:esp32dev] platform = espressif32 board = esp32dev framework = arduino lib_deps = augmented-robotics/RoboHeart@^2.1.7

Output:
.pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp: In member function 'char* RoboHeart::handleMotorMessage(MotorMSGType)': .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:106:22: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] char* response = "None"; ^~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:112:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "forward"; ^~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:116:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "reverse"; ^~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:120:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "right"; ^~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:124:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "left"; ^~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:129:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "forward and right"; ^~~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:134:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "forward and left"; ^~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:139:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "reverse and right"; ^~~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:144:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "reverse and left"; ^~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:149:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "STOP"; ^~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeart.cpp:154:24: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] response = "ERROR"; ^~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartDRV8836.cpp: In member function 'void RoboHeartDRV8836::configPWM(int, int)': .pio/libdeps/esp32dev/RoboHeart/RoboHeartDRV8836.cpp:57:5: error: 'ledcAttachChannel' was not declared in this scope ledcAttachChannel(_in1Pin, _pwmFreq, _pwmResolution, _in1Channel); ^~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartDRV8836.cpp:57:5: note: suggested alternative: 'ledcAttachPin' ledcAttachChannel(_in1Pin, _pwmFreq, _pwmResolution, _in1Channel); ^~~~~~~~~~~~~~~~~ ledcAttachPin Archiving .pio/build/esp32dev/lib866/libBLE.a *** [.pio/build/esp32dev/lib1ff/RoboHeart/RoboHeartDRV8836.cpp.o] Error 1 Indexing .pio/build/esp32dev/lib866/libBLE.a .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp: In constructor 'PeriodicTimer::PeriodicTimer(void (*)(), uint64_t)': .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:16:31: warning: unsigned conversion from 'int' to 'uint8_t' {aka 'unsigned char'} changes value from '1000000' to '64' [-Woverflow] : timer(timerBegin(1000000)) { ^ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:16:31: error: too few arguments to function 'hw_timer_t* timerBegin(uint8_t, uint16_t, bool)' In file included from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:88, from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.h:11, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:8: /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-timer.h:33:14: note: declared here hw_timer_t * timerBegin(uint8_t timer, uint16_t divider, bool countUp); ^~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:17:41: error: too few arguments to function 'void timerAttachInterrupt(hw_timer_t*, void (*)(), bool)' timerAttachInterrupt(timer, callback); ^ In file included from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:88, from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.h:11, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:8: /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-timer.h:39:6: note: declared here void timerAttachInterrupt(hw_timer_t *timer, void (*fn)(void), bool edge); ^~~~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp: In constructor 'PeriodicTimer::PeriodicTimer(void (*)(), uint64_t, Stream&)': .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:24:31: warning: unsigned conversion from 'int' to 'uint8_t' {aka 'unsigned char'} changes value from '1000000' to '64' [-Woverflow] : timer(timerBegin(1000000)), _debug(&debug) { ^ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:24:31: error: too few arguments to function 'hw_timer_t* timerBegin(uint8_t, uint16_t, bool)' In file included from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:88, from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.h:11, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:8: /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-timer.h:33:14: note: declared here hw_timer_t * timerBegin(uint8_t timer, uint16_t divider, bool countUp); ^~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:25:41: error: too few arguments to function 'void timerAttachInterrupt(hw_timer_t*, void (*)(), bool)' timerAttachInterrupt(timer, callback); ^ In file included from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:88, from /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.h:11, from .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:8: /Users/sporubcan/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-timer.h:39:6: note: declared here void timerAttachInterrupt(hw_timer_t *timer, void (*fn)(void), bool edge); ^~~~~~~~~~~~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp: In member function 'void PeriodicTimer::setTimePeriod(uint64_t)': .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:33:5: error: 'timerAlarm' was not declared in this scope timerAlarm(timer, timerPeriodMicroSec, true, 0); ^~~~~~~~~~ .pio/libdeps/esp32dev/RoboHeart/RoboHeartTimer.cpp:33:5: note: suggested alternative: 'timerStart' timerAlarm(timer, timerPeriodMicroSec, true, 0); ^~~~~~~~~~ timerStart *** [.pio/build/esp32dev/lib1ff/RoboHeart/RoboHeartTimer.cpp.o] Error 1

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