Skip to content

won't compile for esp8266 board #75

@tavdog

Description

@tavdog

When trying to use this library with esp8266 I get some int conversion error. It compiles fine for esp32.

lib/note-arduino/src/Notecard.cpp: In member function 'void Notecard::begin(uint32_t, uint32_t, TwoWire&)':
lib/note-arduino/src/Notecard.cpp:194:36: error: invalid conversion from 'void (*)(long unsigned int)' to 'delayMsFn' {aka 'void (*)(unsigned int)'} [-fpermissive]
  194 |     NoteSetFnDefault(malloc, free, delay, millis);
      |                                    ^~~~~
      |                                    |
      |                                    void (*)(long unsigned int)
In file included from lib/note-arduino/src/Notecard.h:33,
                 from lib/note-arduino/src/Notecard.cpp:39:
lib/note-arduino/src/note-c/note.h:126:67: note:   initializing argument 3 of 'void NoteSetFnDefault(mallocFn, freeFn, delayMsFn, getMsFn)'
  126 | void NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn);
      |                                                         ~~~~~~~~~~^~~~~~~
lib/note-arduino/src/Notecard.cpp: In member function 'void Notecard::begin(HardwareSerial&, int)':
lib/note-arduino/src/Notecard.cpp:216:36: error: invalid conversion from 'void (*)(long unsigned int)' to 'delayMsFn' {aka 'void (*)(unsigned int)'} [-fpermissive]
  216 |     NoteSetFnDefault(malloc, free, delay, millis);
      |                                    ^~~~~
      |                                    |
      |                                    void (*)(long unsigned int)
In file included from lib/note-arduino/src/Notecard.h:33,
                 from lib/note-arduino/src/Notecard.cpp:39:
lib/note-arduino/src/note-c/note.h:126:67: note:   initializing argument 3 of 'void NoteSetFnDefault(mallocFn, freeFn, delayMsFn, getMsFn)'
  126 | void NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn);
      |                                                         ~~~~~~~~~~^~~~~~~
*** [.pio/build/huzzah_MAX/lib104/note-arduino/Notecard.cpp.o] Error 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions