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

Not compiling with Arduino Nano BLE 33 #146

Open
ghost opened this issue Mar 28, 2020 · 2 comments
Open

Not compiling with Arduino Nano BLE 33 #146

ghost opened this issue Mar 28, 2020 · 2 comments

Comments

@ghost
Copy link

ghost commented Mar 28, 2020

Description

Hello,
The time library does not work on the new Arduino Nano BLE 33 board.

Steps To Reproduce Problem

When I just upload an empty code with only:
#include <TimeLib.h> I get an errors (see below)

Hardware & Software

Board: Arduino Nano 33 BLE
Arduino IDE version: 1.8.12
Version info: Time library v 1.6.8
Operating system & version: Mac OS X

Arduino Sketch

#include <TimeLib.h>

void setup() {
}

void loop() {
}

Errors or Incorrect Output

Arduino: 1.8.12 (Mac OS X), Board: "Arduino Nano 33 BLE"

In file included from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/String.h:33:0,
from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/Print.h:24,
from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/Stream.h:25,
from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/Client.h:22,
from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/ArduinoAPI.h:29,
from /Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/Arduino.h:42,
from /Users/user/Documents/Arduino/libraries/Time-master/DateStrings.cpp:12:
/Users/user/Documents/Arduino/libraries/Time-master/DateStrings.cpp: In function 'char* monthStr(uint8_t)':
/Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated-avr-comp/avr/pgmspace.h:106:49: error: 'const void*' is not a pointer-to-object type
#define pgm_read_ptr(addr) ((const void )(addr))
^
/Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated-avr-comp/avr/pgmspace.h:63:45: note: in definition of macro 'strcpy_P'
#define strcpy_P(dest, src) strcpy((dest), (src))
^~~
/Users/user/Documents/Arduino/libraries/Time-master/DateStrings.cpp:72:29: note: in expansion of macro 'pgm_read_ptr'
strcpy_P(buffer, (PGM_P)pgm_read_ptr(&(monthNames_P[month])));
^~~~~~~~~~~~
/Users/user/Documents/Arduino/libraries/Time-master/DateStrings.cpp: In function 'char
dayStr(uint8_t)':
/Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated-avr-comp/avr/pgmspace.h:106:49: error: 'const void
' is not a pointer-to-object type
#define pgm_read_ptr(addr) (*(const void *)(addr))
^
/Users/user/Library/Arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated-avr-comp/avr/pgmspace.h:63:45: note: in definition of macro 'strcpy_P'
#define strcpy_P(dest, src) strcpy((dest), (src))
^~~
/Users/user/Documents/Arduino/libraries/Time-master/DateStrings.cpp:86:28: note: in expansion of macro 'pgm_read_ptr'
strcpy_P(buffer, (PGM_P)pgm_read_ptr(&(dayNames_P[day])));
^~~~~~~~~~~~
exit status 1
Error compiling for board Arduino Nano 33 BLE.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

@Blubberblub
Copy link

I have the same problem and the same error. Any idea what a solution could be?

@manchoz
Copy link

manchoz commented Oct 9, 2020

The upcoming version of the Arduino Cor for MbedOS-based boards will fix the issue (see. arduino/ArduinoCore-API@cd4ba4c#diff-7cf2fd59cb024f927f2c406eea1d7cc7).

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