Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Development
  3. Many compilation errors with mySensor 2.2

Many compilation errors with mySensor 2.2

Scheduled Pinned Locked Moved Development
5 Posts 2 Posters 2.5k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • djdehaanD Offline
    djdehaanD Offline
    djdehaan
    wrote on last edited by djdehaan
    #1

    Hi all,

    I must be crazy, but I have a strange but big problem with version 2.2 of mySensor. I use it on esp8266 (Wemos), and with a previous version my program compiled without a problem. I upgraded to mySensor 2.2 and 2 problem arised. First my compilation first resulted in:

    In file included from D:\users\DirkJan\Arduino\libraries\MySensors/MySensors.h:405:0,
    
                     from D:\users\DirkJan\Arduino\Projecten\Project_WCsniffer\IoT21_WCsniffer010\IoT21_WCsniffer010.ino:31:
    
    D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:57:53: error: declaration of C function 'void ets_update_cpu_frequency(int)' conflicts with
    
     extern "C" void ets_update_cpu_frequency(int freqmhz);
    
                                                         ^
    
    In file included from D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/pgmspace.h:10:0,
    
                     from D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/Arduino.h:255,
    
                     from sketch\IoT21_WCsniffer010.ino.cpp:1:
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266/tools/sdk/include/ets_sys.h:218:6: error: previous declaration 'void ets_update_cpu_frequency(uint32_t)' here
    
     void ets_update_cpu_frequency(uint32_t ticks_per_us);
    
          ^
    
    exit status 1
    Fout bij het compileren voor board WeMos D1 R2 & mini
    

    So I changed file MyMainESP8266.cpp and replace int for uint32_t. When I then compile the Sketch, it comes with the following load of errors:

    Archiving built core (caching) in: C:\Users\DirkJan\AppData\Local\Temp\arduino_cache_514641\core\core_espressif_esp8266_d1_mini_CpuFrequency_160,VTable_flash,FlashSize_4M1M,LwIPVariant_v2mss536,Debug_Disabled,DebugLevel_None____,FlashErase_none,UploadSpeed_256000_8c8da037c528d73cc750ee74e4676a97.a
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `esp_yield':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:87: multiple definition of `esp_yield'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:81: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `esp_schedule':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:94: multiple definition of `esp_schedule'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:89: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `init_done()':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:144: multiple definition of `init_done()'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:151: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `__yield':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:98: multiple definition of `__yield'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:94: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `optimistic_yield':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:109: multiple definition of `optimistic_yield'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:105: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o):(.bss.resetInfo+0x0): multiple definition of `resetInfo'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\Projecten\Project_WCsniffer\IoT21_WCsniffer010/DJ_Tools.ino:63: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o): In function `user_init':
    
    D:\users\DirkJan\Arduino\hardware\espressif\esp8266\cores\esp8266/core_esp8266_main.cpp:168: multiple definition of `user_init'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\libraries\MySensors/hal/architecture/ESP8266/MyMainESP8266.cpp:160: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o):(.bss.core_release+0x0): multiple definition of `core_release'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:D:\users\DirkJan\Arduino\Projecten\Project_WCsniffer\IoT21_WCsniffer010/DJ_Tools.ino:63: first defined here
    
    C:\Users\DirkJan\AppData\Local\Temp\arduino_build_931425/arduino.ar(core_esp8266_main.cpp.o):(.ver_number+0x0): multiple definition of `core_version'
    
    sketch\IoT21_WCsniffer010.ino.cpp.o:(.ver_number+0x0): first defined here
    

    What do i do wrong???

    Thanks for any help,
    Dirk Jan

    1 Reply Last reply
    0
    • electrikE Offline
      electrikE Offline
      electrik
      wrote on last edited by
      #2

      did you select the right board to compile for?

      1 Reply Last reply
      0
      • djdehaanD Offline
        djdehaanD Offline
        djdehaan
        wrote on last edited by
        #3

        I certainly did.
        When i compile the following Sketch, I do get the first compile error mentioned above:

        #define ESP8266
        
        #define MY_BAUD_RATE 9600
        #define MY_GATEWAY_ESP8266
        #define MY_ESP8266_SSID "xxx"
        #define MY_ESP8266_PASSWORD "xxx"
        #define MY_PORT 5003      
        #define MY_GATEWAY_MAX_CLIENTS 2
        
        #include <ESP8266WiFi.h>
        #include <ESP8266mDNS.h>
        #include <MySensors.h>
        
        void setup() {
          // put your setup code here, to run once:
        
        }
        
        void loop() {
          // put your main code here, to run repeatedly:
        
        }
        

        What is wrong with this sketch (besides that it does nothing)?

        1 Reply Last reply
        0
        • djdehaanD Offline
          djdehaanD Offline
          djdehaan
          wrote on last edited by djdehaan
          #4

          I found out that the same errors occur if i load mySensor library 2.1 or 2.0. It is not related to 2.2 version of mySensor.
          So what goes wrong? For this matter, I downloaded the ESP8266 hardware library again, and ran
          python get.py

          So the ESP8266 harware lib is the newest. And then still it generates all those error, again and again.

          1 Reply Last reply
          0
          • djdehaanD Offline
            djdehaanD Offline
            djdehaan
            wrote on last edited by
            #5

            Well, problem solved. I removed the ESP8266 harware libs and reinstalled them now using the Boards Manager. Then it works fine. But a manual download of the ESP8266 hardware lib causes all these comilation errors.

            Thanks.

            1 Reply Last reply
            1

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            20

            Online

            12.0k

            Users

            11.2k

            Topics

            113.4k

            Posts


            Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • MySensors
            • OpenHardware.io
            • Categories
            • Recent
            • Tags
            • Popular