• Hello everyone.
    I have ESP-12E devboard.
    I need FS and Graphics libs for my project but this libs are removed from firmware by default.
    How can i compile firmware with this libs for my board with 4mb flash size?
    Thanks for reply.

  • Hi @MaBe I read this file and got stuck in make.
    I downloaded all the necessary files, create compile.sh file with some vars exports and make. First libs colpiles correctly but make stuck in neopixel lib.

    #! /bin/bash
    export FAMILY=ESP8266
    export BOARD=ESP8266_BOARD
    export FLASH_4MB=1
    export USE_NET=1
    export USE_CRYPTO=1
    export USE_TELNET=1
    export USE_FILESYSTEM=1
    export USE_GRAPHICS=1
    export ESP8266_SDK_ROOT=/github/espressif
    export PATH=$PATH:/github/espopensdk/esp-open-sdk/xtensa-lx106-elf/bin
    export COMPORT=/dev/ttyUSB0
    make clean && make $*
    

    This is terminal output.

    In file included from /home/noface/source/repos/github/espopensdk/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.5/include/stdint.h:9:0,
                     from /home/noface/source/repos/github/espruino/Espruino/src/jsutils.h:23,
                     from /home/noface/source/repos/github/espruino/Espruino/src/jspin.h:18,
                     from /home/noface/source/repos/github/espruino/Espruino/libs/neopixel/jswrap_neopixel.h:15,
                     from libs/neopixel/jswrap_neopixel.c:28:
    /home/noface/source/repos/github/espopensdk/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/stdint.h:80:20: error: conflicting types for 'int32_t'
     typedef signed int int32_t;
                        ^
    In file included from libs/neopixel/jswrap_neopixel.c:21:0:
    /home/noface/source/repos/github/espressif/include/c_types.h:17:29: note: previous declaration of 'int32_t' was here
     typedef signed long         int32_t;
                                 ^
    In file included from /home/noface/source/repos/github/espopensdk/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.5/include/stdint.h:9:0,
                     from /home/noface/source/repos/github/espruino/Espruino/src/jsutils.h:23,
                     from /home/noface/source/repos/github/espruino/Espruino/src/jspin.h:18,
                     from /home/noface/source/repos/github/espruino/Espruino/libs/neopixel/jswrap_neopixel.h:15,
                     from libs/neopixel/jswrap_neopixel.c:28:
    /home/noface/source/repos/github/espopensdk/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/stdint.h:81:22: error: conflicting types for 'uint32_t'
     typedef unsigned int uint32_t;
                          ^
    In file included from libs/neopixel/jswrap_neopixel.c:21:0:
    /home/noface/source/repos/github/espressif/include/c_types.h:15:29: note: previous declaration of 'uint32_t' was here
     typedef unsigned long       uint32_t;
                                 ^
    cc1: warning: unrecognized command line option "-Wno-float-conversion" [enabled by default]
    cc1: warning: unrecognized command line option "-Wno-discarded-qualifiers" [enabled by default]
    Makefile:744: error«libs/neopixel/jswrap_neopixel.o»
    
    
  • Make of the firmware was successed (without errors and with few warnings) but after flash firmware on my esp8266 devboard i can't connect by WebIDE to this board (Wemos D1 mini board and LoLin v3 board). At this time i can connect to original Espruino board and it's weird. I don't know why but it's happened. I'll try to fix it but i don't know what i need to do :(

    When i try to connect to this boards WebIDE write to console

    Connected
    >
    Disconnected
    
  • After flashing the USB/serial device gets left in an odd state.

    I have found if you connect with a serial programme ( screen on linux, putty ) on windows with a baud of 115200 after flashing, you get a command prompt. Then quit this, and try the connection from the web ide with baud rate 115200.

    The other related factor is the ESP8266 outputs on the UART and boot at 76800 baud and spits out:

     ets Jan  8 2013,rst cause:1, boot mode:(3,7)
    
    load 0x40100000, len 25336, room 16 
    tail 8
    chksum 0x1f
    load 0x3ffe8000, len 2544, room 0 
    tail 0
    chksum 0xb8
    load 0x3ffe89f0, len 1044, room 8 
    tail 12
    chksum 0x7f
    csum 0x7f 
    

    I think this output confuses the web ide, an if you look in the console you see 'overrun' or something similar, and the nodejs serialport connection is disconnected. Perhaps this could be commented out and see if this works a work around?

  • What were the warnings? I never get any warnings anymore when compiling my firmware (and yes I do use the FS + FLASH options), since @Wilberforce fixed all the type casting.

  • @PressAnyKey, please share the used flash command

  • @hungryforcodes there is few not critical (i think so) warnings about declaration variables.

    libs/network/esp8266/network_esp8266.c: In function 'esp8266_dumpSocketData':
    libs/network/esp8266/network_esp8266.c:198:9: warning: variable 'stateMsg' set but not used [-Wunused-but-set-variable]
       char *stateMsg;
             ^
    libs/network/esp8266/network_esp8266.c:182:9: warning: variable 'creationTypeMsg' set but not used [-Wunused-but-set-variable]
       char *creationTypeMsg;
             ^
    

    and this

    libs/network/esp8266/network_esp8266.c: At top level:
    cc1: warning: unrecognized command line option "-Wno-float-conversion" [enabled by default]
    cc1: warning: unrecognized command line option "-Wno-discarded-qualifiers" [enabled by default]
    
    
  • @MaBe, i used this flash commands.

    python ../esptool.py --port /dev/ttyUSB0 --baud 115200 erase_flash
    python ../esptool.py --port /dev/ttyUSB0 --baud 115200 write_flash --flash_freq 80m --flash_mode qio --flash_size 32m 0x0000 boot_v1.6.bin 0x1000 espruino_esp8266_user1.bin 0x3FC000 esp_init_data_default.bin 0x3FE000 blank.bin
    
  • @Wilberforce, yep at first connect i have message like

    Connected
    >load 0x40100000, len 25336, room
    Disconnected
    

    I connect to board by minicom and get it as output when reset the board


    1 Attachment

    • Снимок экрана от 2017-05-19 15-53-41.png
  • @PressAnyKey - great, so it works.

    if you like do

    export BOARD=ESP8266_4MB
    
    make clean
    make 
    make flash_erase
    make flash
    

    and you will get a Flash map 4MB:1024/1024 with lots off free flash areas

  • @MaBe, yes, firmware is working fine but the first line on output is weird and WebIDE won't connect to the board.
    Thank you for tips about flash areas. Compiles correctly. Now espruino output

     _____                 _ 
    |   __|___ ___ ___ _ _|_|___ ___ 
    |   __|_ -| . |  _| | | |   | . |
    |_____|___|  _|_| |___|_|_|_|___|
              |_| http://espruino.com
     1v92.62 Copyright 2016 G.Williams
    
    Espruino is Open Source. Our work is supported
    only by sales of official boards and donations:
    http://espruino.com/Donate
    Flash map 4MB:1024/1024, manuf 0xe0 chip 0x4016
    

    Maybe you know how can i fix the first weird line of output? It's totaly not comfortable without WebIDE :( Thank you again.

    p.s. Now i use minicom and web ide at the same time. If i connected to port with minicom, WebIDE connected fine but can't use the terminal side, but WebIDE can upload code from the right side.

  • @Wilberforce, where i can comment it out?

  • please share the CONSOLE output of the WEB IDE

  • I was flash some code to the board and it start connect to the WebIDE. I don't know why but it work for me.

  • glad to hear that it now works for you.

  • I have new problem.
    When i try to connect SD card console outputs to me this errors

    Running onInit()...
    Uncaught Error: Unimplemented on Linux
     at line 10 col 25
      E.connectSDCard(spi,D2);
                            ^
    

    but when i try to start SD card at original espruino i have this in output

    Running onInit()...
    ERROR: Unable to mount SD card : NOT_READY
    

    What i'm doing wrong?

  • @PressAnyKey, how did you solve the "error: conflicting types for 'int32_t'" ?
    I had the same, I changed the int32_t and uint32_t from long to int in c_types.h ( I used esp_iot_sdk_v1.5.0), I am not sure I did right, but it compiled, and surprise, the binary is working fine with today espruino code v1.93.162. here's the result :

     _____                 _
    |   __|___ ___ ___ _ _|_|___ ___
    |   __|_ -| . |  _| | | |   | . |
    |_____|___|  _|_| |___|_|_|_|___|
              |_| http://espruino.com
     1v93.162 Copyright 2016 G.Williams
    Espruino is Open Source. Our work is supported
    only by sales of official boards and donations:
    http://espruino.com/Donate
    Flash map 4MB:512/512, manuf 0xef chip 0x4016
    
  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

ESP8266 how compile firmware with FS and Graphics libs?

Posted by Avatar for PressAnyKey @PressAnyKey

Actions