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

error: reference to 'Print' is ambiguous #144

Open
humanusdeus opened this issue Aug 30, 2020 · 2 comments
Open

error: reference to 'Print' is ambiguous #144

humanusdeus opened this issue Aug 30, 2020 · 2 comments

Comments

@humanusdeus
Copy link

Can't compile the code examples, it always outputs the error:

In file included from /home/warp/Arduino/libraries/NeoGPS/src/GPSfix.h:25:0, from /home/warp/Arduino/libraries/NeoGPS/src/NMEAGPS.h:28, from /home/warp/desktop/NeoGPS/examples/NMEAsimple/NMEAsimple.ino:1: /home/warp/Arduino/libraries/NeoGPS/src/NeoTime.h:303:1: error: reference to 'Print' is ambiguous Print & operator <<( Print & outs, const NeoGPS::time_t &t ); ^~~~~ /home/warp/Arduino/libraries/NeoGPS/src/NeoTime.h:295:7: note: candidates are: class Print class Print; ^~~~~ In file included from /home/warp/.arduino15/packages/arduino/hardware/megaavr/1.8.6/cores/arduino/api/Stream.h:25:0, from /home/warp/.arduino15/packages/arduino/hardware/megaavr/1.8.6/cores/arduino/api/Client.h:22, from /home/warp/.arduino15/packages/arduino/hardware/megaavr/1.8.6/cores/arduino/api/ArduinoAPI.h:29, from /home/warp/.arduino15/packages/arduino/hardware/megaavr/1.8.6/cores/arduino/Arduino.h:23, from /tmp/arduino-sketch-732DF1CC8158C71CF32499A187EEBBAB/sketch/NMEAsimple.ino.cpp:1: /home/warp/.arduino15/packages/arduino/hardware/megaavr/1.8.6/cores/arduino/api/Print.h:34:7: note: class arduino::Print class Print ^~~~~

@daifukusensei
Copy link

Hi there,

Looking at the last line of your output, I'm experiencing the identical error.

I'm attempting to compile against a Nano Every.

My sketch runs fine on a Pro Micro and Mega.

Cheers.

@daifukusensei
Copy link

I had to remove the 'class Print' forward declarations from the following files:
DMS.h
NeoTime.h

Also had to set SPI_DRIVER_SELECT to 1 per greiman/SdFat-beta#42

Additionally, changed '#define F(str) (str)' in Arduino.h to '#define F(str) (const __FlashStringHelper*)(str)'

It at least now compiles, though I don't have my Every available until end of the week to test uploading and execution.

-Chris

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

2 participants