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

Problem compiling with arduino IDE 1.8.6+ and hardware serial #23

Closed
v-a-d-e-r opened this issue Jul 30, 2018 · 6 comments
Closed

Problem compiling with arduino IDE 1.8.6+ and hardware serial #23

v-a-d-e-r opened this issue Jul 30, 2018 · 6 comments

Comments

@v-a-d-e-r
Copy link

v-a-d-e-r commented Jul 30, 2018

Hello all. I'm running mad now. With software serial everything works fine, with hardware serial I can't even compile and get this error:

Code:
#define USE_HARDWARESERIAL
#include <SDM.h>
SDM Plugin_150_SDM(Serial, 9600, NOT_A_PIN, SERIAL_8N1, false);

Error:
undefined reference to SDM::SDM(HardwareSerial&, long, int, int, bool)' sketch/ESPEasy.ino.cpp.o: In function Plugin_150(unsigned char, EventStruct*, String&)':
undefined reference to SDM::SDM(HardwareSerial&, long, int, int, bool)' undefined reference to SDM::SDM(HardwareSerial&, long, int, int, bool)'
collect2: error: ld returned 1 exit status

Any idea what's going wrong here?

@v-a-d-e-r v-a-d-e-r changed the title Problem compiling with arduino IDE 1.8.6 and hardware serial Problem compiling with arduino IDE 1.8.6+ and hardware serial Jul 30, 2018
@salberin
Copy link

Came here to write a bug report, as I am experiencing the exact same error....

@v-a-d-e-r
Copy link
Author

v-a-d-e-r commented Jul 30, 2018

Good to know I'm not the only one on the earth with that issue. I hope that Reaper7 knows a fix for it...

@v-a-d-e-r v-a-d-e-r reopened this Jul 30, 2018
@salberin
Copy link

I'm experiencing this using a Wemos D1 Mini. Are you using the same hardware?

@v-a-d-e-r
Copy link
Author

No. I have a Lolin NodeMCU. But I think it does not depend on the hardware. More on the communication between the SDM software and the hardware serial library.

@reaper7
Copy link
Owner

reaper7 commented Jul 31, 2018

Uncomment
#define USE_HARDWARESERIAL
in sdm_user_config.h file

@v-a-d-e-r
Copy link
Author

Hi. Many thanks, it works! Can't believe it..... I thought when I define it in the .ino it is global? And #define USE_HARDWARESERIAL is before include <SDM.h>!?

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

3 participants