Shop OBEX P1 Docs P2 Docs Learn Events
Parallax-ESP Module Latest Hack - Page 3 — Parallax Forums

Parallax-ESP Module Latest Hack

1356711

Comments

  • I guess the next question is whether the firmware still works with this modified code. One thing that I saw in the changes from iseries was an increase in a buffer size. I recall that there were RAM constraints when we first wrote this code which is one reason we didn't just use the Arduino ESP libraries. I assume this buffer size change has not broken wifi downloads?
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-04 18:30
    By wifi downloads, do you mean to the prop chip? Or uploading a html file? Or uploading a new OTA file?

    I have done them all and they all work, but I HAVE NOT bulk filled a .spin file yet so it uses all the RAM space of a propeller chip and tested that, I will do that asap.

  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-04 18:24
    I found a problem with the /release/ folder.

    It also needs the flash-all.sh file to be fixed for the new files.

    And the same is probably true for all the other .sh files.
    Apparently I fixed my copy and forgot I did this when I fixed the Makefile...
  • BTW, the C version of the esptool that Parallax was using is here: https://github.com/igrr/esptool-ck
  • Clock Loop wrote: »
    I found a problem with the /release/ folder.

    It also needs the flash-all.sh file to be fixed for the new files.

    And the same is probably true for all the other .sh files.
    Apparently I fixed my copy and forgot I did this when I fixed the Makefile...
    Are you talking about the reference to the boot file boot_v1.6.bin or also the esp_init_data_default.bin file?
  • David Betz wrote: »
    Are you talking about the reference to the boot file boot_v1.6.bin or also the esp_init_data_default.bin file?

    I think so, I am re-running git for the repo and see what you changed now.
    You are fast.
  • I didn't change the flash script yet.
  • Does esptool.py work with the flash-all.sh script?
  • David Betz wrote: »
    I didn't change the flash script yet.

    Ok, the Makefile looks great!
  • David Betz wrote: »
    Does esptool.py work with the flash-all.sh script?

    No, apparently I changed it a lot to make it all work.
  • Here is the git diff for flash-all.sh to use it with esptool.py

    Sorry all this re- downloading of the repo wiped out my git diff of the flash-all.sh when I ran it for the Makefile.
    /Parallax-ESP/release$ git diff
    diff --git a/release/flash-all.sh b/release/flash-all.sh
    index a92c8cd..5cba045 100755
    --- a/release/flash-all.sh
    +++ b/release/flash-all.sh
    @@ -9,11 +9,10 @@ fi
     echo Using port $PORT
     
     BAUD=115200
    -BOARD=none # none, ck, nodemcu, wifio
    -FLASH_SIZE=2M
    +FLASH_SIZE=4MB          # 16MB, detect, 256KB, 2MB-c1, 8MB, 2MB, 4MB, 512KB, 1MB, 4MB-c1
     FLASH_BLOCK_SIZE=1024
    -FLASH_SPEED=80
    -FLASH_INTERFACE=qio
    +FLASH_SPEED=80m         # keep,40m,26m,20m,80m
    +FLASH_INTERFACE=qio     # keep,qio,qout,dio,dout
     
     BOOT_LOADER=0x000000
     USER1_IMAGE=0x001000
    @@ -21,15 +20,15 @@ USER1_IMAGE=0x001000
     USER_SETTINGS1=0x07E000
     USER_SETTINGS2=0x07F000
     
    -if [ $FLASH_SIZE = 1M ]; then
    +if [ $FLASH_SIZE = 1MB ]; then
     WIFI_SETTINGS1=0x0FC000
     WIFI_SETTINGS2=0x0FE000
     WIFI_SETTINGS3=0x0FA000
    -elif [ $FLASH_SIZE = 2M ]; then
    +elif [ $FLASH_SIZE = 2MB ]; then
     WIFI_SETTINGS1=0x1FC000
     WIFI_SETTINGS2=0x1FE000
     WIFI_SETTINGS3=0x1FA000
    -elif [ $FLASH_SIZE = 4M ]; then
    +elif [ $FLASH_SIZE = 4MB ]; then
     WIFI_SETTINGS1=0x3FC000
     WIFI_SETTINGS2=0x3FE000
     WIFI_SETTINGS3=0x3FA000
    @@ -41,18 +40,20 @@ fi
     #flash filesystem base
     FFS_BASE=0x100000
     
    -esptool \
    --cp $PORT \
    --cd $BOARD \
    --cb $BAUD \
    --bz $FLASH_SIZE \
    --bf $FLASH_SPEED \
    --bm $FLASH_INTERFACE \
    --ca $BOOT_LOADER -cf boot_v1.6.bin \
    --ca $USER1_IMAGE -cf httpd.user1.bin \
    --ca $USER_SETTINGS1 -cf blank.bin \
    --ca $USER_SETTINGS2 -cf blank.bin \
    --ca $WIFI_SETTINGS1 -cf esp_init_data_default.bin \
    --ca $WIFI_SETTINGS2 -cf blank.bin \
    --ca $WIFI_SETTINGS3 -cf blank.bin \
    --ca $FFS_BASE -cf blank.bin
    +./esptool.py \
    +--port $PORT \
    +--baud $BAUD \
    +write_flash \
    +--flash_freq $FLASH_SPEED \
    +--flash_mode $FLASH_INTERFACE \
    +--flash_size $FLASH_SIZE \
    +--verify \
    +--compress \esptool.py flash-all.sh
    +$BOOT_LOADER boot_v1.7.bin \
    +$USER1_IMAGE httpd.user1.bin \
    +$USER_SETTINGS1 blank.bin \
    +$USER_SETTINGS2 blank.bin \
    +$WIFI_SETTINGS1 esp_init_data_default_v08.bin \
    +$WIFI_SETTINGS2 blank.bin \
    +$WIFI_SETTINGS3 blank.bin \
    +$FFS_BASE blank.bin
    

  • If you want to use the c version of esptool, i can test it and see if anything needs to be changed (other than the filename) with the original flash-all.sh
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-04 19:01
    The c version of esptool seems to work ok with your original flash-all.sh file (with the new file name change)
    I am testing the module now.
    /Parallax-ESP/release/release$ ./flash-all.sh
    Using port /dev/ttyUSB0
    Uploading 4080 bytes from boot_v1.7.bin to flash at 0x00000000
    ....                                                                             [ 100% ]
    Uploading 324164 bytes from httpd.user1.bin to flash at 0x00001000
    ................................................................................ [ 25% ]
    ................................................................................ [ 50% ]
    ................................................................................ [ 75% ]
    .............................................................................    [ 100% ]
    Uploading 4096 bytes from blank.bin to flash at 0x0007E000
    ....                                                                             [ 100% ]
    Uploading 4096 bytes from blank.bin to flash at 0x0007F000
    ....                                                                             [ 100% ]
    Uploading 128 bytes from esp_init_data_default_v08.bin to flash at 0x001FC000
    .                                                                                [ 100% ]
    Uploading 4096 bytes from blank.bin to flash at 0x001FE000
    ....                                                                             [ 100% ]
    Uploading 4096 bytes from blank.bin to flash at 0x001FA000
    ....                                                                             [ 100% ]
    Uploading 4096 bytes from blank.bin to flash at 0x00100000
    ....                                                                             [ 100% ]
    
    
  • Do you expect users to copy esptool to the release folder?

    Or should esptool get installed into their executable folder?

    Or you can refer to it if they GIT it in the same folder as Parallax-Esp.

    Heres the git diff of flash-all.sh when I used esptool c version and kept it in its git folder beside Parallax-esp
    /Parallax-ESP/release$ git diff
    diff --git a/release/flash-all.sh b/release/flash-all.sh
    index a92c8cd..9795226 100755
    --- a/release/flash-all.sh
    +++ b/release/flash-all.sh
    @@ -41,18 +41,18 @@ fi
     #flash filesystem base
     FFS_BASE=0x100000
     
    -esptool \
    +../../../esptool-ck/esptool \
     -cp $PORT \
     -cd $BOARD \
     -cb $BAUD \
     -bz $FLASH_SIZE \
     -bf $FLASH_SPEED \
     -bm $FLASH_INTERFACE \
    --ca $BOOT_LOADER -cf boot_v1.6.bin \
    +-ca $BOOT_LOADER -cf boot_v1.7.bin \
     -ca $USER1_IMAGE -cf httpd.user1.bin \
     -ca $USER_SETTINGS1 -cf blank.bin \
     -ca $USER_SETTINGS2 -cf blank.bin \
    --ca $WIFI_SETTINGS1 -cf esp_init_data_default.bin \
    +-ca $WIFI_SETTINGS1 -cf esp_init_data_default_v08.bin \
     -ca $WIFI_SETTINGS2 -cf blank.bin \
     -ca $WIFI_SETTINGS3 -cf blank.bin \
     -ca $FFS_BASE -cf blank.bin
    
  • Maybe I should add esptool-ck as a submodule under Parallax-ESP.
  • I tested the module with the c version of esptool and the new filenames in your original flash-all.sh , it works properly so far.
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-04 19:24
    David Betz wrote: »
    Maybe I should add esptool-ck as a submodule under Parallax-ESP.

    Not a bad idea, I had a hard time figuring this out at first because I couldn't find the c version.
    I could only find the python version of esptool. Thats why I re-did all the flash-all.sh code.

    The c version doesn't show up in google searches easily.

    The python version just has more utilities, like to find the flash chip size.
    ./esptool.py flash_id
    I suppose the only benefit to that is you can auto get the flash size on the esp.
    But they should be using the Parallax module with 4mb :)
  • I pushed the flash script changes. I'll look into adding esptool-ck next. It is unfortunate that they chose the same name as the Python tool since the command line arguments are completely different.
  • Then adding the flash-all.sh and other .sh files to the README might be a good idea also.
  • I added esptool-ck as a submodule under Parallax-ESP but I still haven't incorporated it into the build process. At present, the user will have to build it separately and put it in his/her executable path before running the flash scripts.
  • I think I should figure out how to get esptool.py working on my Ubuntu system and use that instead of esptool-ck. It sounds like Parallax uses the Python version for factory programming the WX modules.
  • @"Clock Loop" I got esptool.py working on my Ubuntu 20 system. Could you please post your modified versions of the flash scripts?
  • I got my USB2serial ports working with Ubuntu running under VirtualBox on my Mac. Now I just need to get a working flash script...
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-05 05:13
    David Betz wrote: »
    I got my USB2serial ports working with Ubuntu running under VirtualBox on my Mac. Now I just need to get a working flash script...


    Sorry, i was doing some garden work, laying new bricks in the greenhouse. Gotta get away from the screen once in a while.

    Heres the esptool.py working script. It DOES NOT check the file system size, it just requires the user to do it.
    I do not know how to query for the size and store it in a variable to check it in a bash script, i am not that smart.
    I could try to do it by searching the nets. The flash size is 4MB, I think your old c version used 2mb (the python version is case sensitive)
    # File name: /Parallax-Esp/release/release/flash-all.sh
    # This uses esptool.py
    # flash the firmware
    # and clear out all settings and the user flash filesystem
    
    PORT=/dev/ttyUSB0
    if [ ! -z $1 ]
    then
      PORT=$1
    fi
    echo Using port $PORT
    
    BAUD=115200
    FLASH_SIZE=4MB          # 16MB, detect, 256KB, 2MB-c1, 8MB, 2MB, 4MB, 512KB, 1MB, 4MB-c1
    FLASH_BLOCK_SIZE=1024
    FLASH_SPEED=80m         # keep,40m,26m,20m,80m
    FLASH_INTERFACE=qio     # keep,qio,qout,dio,dout
    
    BOOT_LOADER=0x000000
    USER1_IMAGE=0x001000
    
    USER_SETTINGS1=0x07E000
    USER_SETTINGS2=0x07F000
    
    if [ $FLASH_SIZE = 1MB ]; then
    WIFI_SETTINGS1=0x0FC000
    WIFI_SETTINGS2=0x0FE000
    WIFI_SETTINGS3=0x0FA000
    elif [ $FLASH_SIZE = 2MB ]; then
    WIFI_SETTINGS1=0x1FC000
    WIFI_SETTINGS2=0x1FE000
    WIFI_SETTINGS3=0x1FA000
    elif [ $FLASH_SIZE = 4MB ]; then
    WIFI_SETTINGS1=0x3FC000
    WIFI_SETTINGS2=0x3FE000
    WIFI_SETTINGS3=0x3FA000
    else
    echo Unsupported flash size $FLASH_SIZE
    exit 1
    fi
    
    #flash filesystem base
    FFS_BASE=0x100000
    
    ./esptool.py \
    --port $PORT \
    --baud $BAUD \
    write_flash \
    --flash_freq $FLASH_SPEED \
    --flash_mode $FLASH_INTERFACE \
    --flash_size $FLASH_SIZE \
    --verify \
    --compress \
    $BOOT_LOADER boot_v1.7.bin \
    $USER1_IMAGE httpd.user1.bin \
    $USER_SETTINGS1 blank.bin \
    $USER_SETTINGS2 blank.bin \
    $WIFI_SETTINGS1 esp_init_data_default_v08.bin \
    $WIFI_SETTINGS2 blank.bin \
    $WIFI_SETTINGS3 blank.bin \
    $FFS_BASE blank.bin
    
    
    

  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-05 05:11
    The C version is good for windows users? then all they would need is the RELEASE folder? I might be wrong, i think.
    (i guess? can win users run .sh scripts?)

    Actually i guess windows users would need a .BAT version of the script.
    I could write that also.

    I suppose im presenting too many options, go which ever way to feel is best, I will support what you choose.

    Scripts for all versions of esptool and esptool-ck can be made also, we already have the .sh version for both in this thread.
    A .BAT file version for the esptool-ck.exe (win32) (in their releases folder) would be simple to make.
    I grew up on DOS.



    I guess multiple versions could be made and put the entire /Parallax-Esp/release/release folder on github under https://github.com/parallaxinc/Parallax-ESP/releases/
    Then they could still flash a bricked/any esp module without needing linux/raspberrypi/mac.[/b]

    Do what you feel is best!
  • Windows can run .sh scripts if a unix-like shell is used (Git for Windows always comes with bash)
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-05 09:08
    Attached, are all the WINDOWS files needed to flash any ESP8266 (with at least 1MB flash on it) to the ParallaxWX code, the latest compile as of SEPT-05-2020
    The .OTA file is included also for updating the firmware over the AIR. (OTA updating, this requires at least a 2MB flash)



    Here is the windows Flash-all.bat script.
    @echo off
    ECHO    Filename: Flash-all.bat
    ECHO    THIS WILL Flash the firmware and clear out all settings and the user flash filesystem.
    ECHO    IT LOOKS ON COM1 FOR THE ESP. YOU MUST SET YOUR COM PORT FOR THE PROPPLUG IN THE DEVICE MANAGER, OR IN THIS FILE TO MATCH.
    ECHO    THIS BATCH WILL ATTEMPT TO SET THE PORT SPEED.  YOU MAY NEED TO SET THE COM PORT SPEED SETTING IN THE DEVICE MANAGER TO THE SAME IN THIS FILE 115200.
    ECHO    SET YOUR FLASH SIZE TO EITHER 1M, 2M or 4M, IT IS CURRENTLY SET AS 2M.
    ECHO    TO STOP Press CTRL-C, Then Answer with a CAPITAL Y, Otherwise press any key to continue.
    
    PAUSE
    
    set PORT=COM1
    
    set BAUD=115200
    
    REM Currently supported methods are: none, ck, nodemcu, wifio.
    set BOARD=none 
    
    REM <512K|256K|1M|2M|4M|8M|16M|32M>
    set FLASH_SIZE=2M
    
    REM <40|26|20|80>
    set FLASH_SPEED=80
    
    REM <qio|qout|dio|dout>
    set FLASH_INTERFACE=qio
    
    set FLASH_BLOCK_SIZE=1024
    
    set BOOT_LOADER=0x000000
    
    set USER1_IMAGE=0x001000
    
    set USER_SETTINGS1=0x07E000
    
    set USER_SETTINGS2=0x07F000
    
    REM Flash filesystem base
    
    set FFS_BASE=0x100000
    
    if %FLASH_SIZE%==1M goto :Flash1M
    if %FLASH_SIZE%==2M goto :Flash2M
    if %FLASH_SIZE%==4M goto :Flash4M
    if %FLASH_SIZE%==8M goto :Flash8M
    if %FLASH_SIZE%==16M goto :Flash16M
    if %FLASH_SIZE%==32M goto :Flash32M
    
    :Flash1M
    set WIFI_SETTINGS1=0x0FC000
    set WIFI_SETTINGS2=0x0FE000
    set WIFI_SETTINGS3=0x0FA000
    goto Go
    
    :Flash2M
    set WIFI_SETTINGS1=0x1FC000
    set WIFI_SETTINGS2=0x1FE000
    set WIFI_SETTINGS3=0x1FA000
    goto Go
    
    :Flash4M
    set WIFI_SETTINGS1=0x3FC000
    set WIFI_SETTINGS2=0x3FE000
    set WIFI_SETTINGS3=0x3FA000
    goto Go
    
    :Flash8M
    
    echo Unsupported flash size! %FLASH_SIZE% exit 1
    
    :Flash16M
    
    echo Unsupported flash size! %FLASH_SIZE% exit 1
    
    :Flash32M
    
    echo Unsupported flash size! %FLASH_SIZE% exit 1
    
    :Go
    
    set tt0=-v
    set tt1=-cp %PORT%
    set tt2=-cd %BOARD%
    set tt3=-cb %BAUD%
    set tt4=-bz %FLASH_SIZE%
    set tt5=-bf %FLASH_SPEED%
    set tt6=-bm %FLASH_INTERFACE%
    
    set tt7=-ca %BOOT_LOADER%
    set tt8=-cf boot_v1.7.bin
    
    set tt9=-ca %USER1_IMAGE%
    set tt10=-cf httpd.user1.bin
    
    set tt11=-ca %USER_SETTINGS1%
    set tt12=-cf blank.bin
    
    set tt13=-ca %USER_SETTINGS2%
    set tt14=-cf blank.bin
    
    set tt15=-ca %WIFI_SETTINGS1%
    set tt16=-cf esp_init_data_default_v08.bin
    
    set tt17=-ca %WIFI_SETTINGS2%
    set tt18=-cf blank.bin
    
    set tt19=-ca %WIFI_SETTINGS3%
    set tt20=-cf blank.bin
    
    set tt21=-ca %FFS_BASE%
    set tt22=-cf blank.bin
    
    Mode Com1: Baud=%BAUD% Parity=N Data=8 Stop=1
    
    call esptool.exe %tt0% %tt1% %tt2% %tt3% %tt4% %tt5% %tt6% %tt7% %tt8% %tt9% %tt10% %tt11% %tt12% %tt13% %tt14% %tt15% %tt16% %tt17% %tt18% %tt19% %tt20% %tt21% %tt22%
    
    PAUSE
    


    How to connect a PROPPLUG to the ESP. Purchase a PropPlug to flash an ESP8266 --> https://www.parallax.com/product/32201
    And purchase a Parallax WX ESP8266 WiFi Module - SIP --> https://www.parallax.com/product/32420s
    SUPPORT PARALLAX, DON'T BE A LEECH! (lol)

    PGM (IO0) must be tied to GROUND BEFORE POWER ON.
    ParallaxWxEsp8266.jpeg

    :D
  • Clock LoopClock Loop Posts: 2,069
    edited 2020-09-05 10:08
    I must say, this new firmware seems like the WX config pages load MUCH faster.

    I haven't found ANY bugs YET.
    The test I have done so far:
    I do telnet to putty connections.
    I do uploads of html pages.
    I do uploads of spin prop programs.
    I do uploads of .OTA files.
    I do uploads of C prop programs that talk to the esp using the SSCP command parsing. (webpage test)
    https://learn.parallax.com/tutorials/language/propeller-c/parallax-wx-wi-fi-module-prop-c/page-requests-info-propeller
    I did these tests while a PropPlug was connected to the DBG (debug) port of the WX module to see any errors, none so far.

    I have NOT tried to fill the FLASH SPACE (file system) of the ESP using the upload webpage. (someone should do that)


    I have tested the new firmware for the WX module with a program that fills 7,905 longs.

    When I compiled it in PROPTOOL, it said I can fit 7,909 longs.
    But with my TELNET demo program, anything more than 7,905 and the prop won't run.

    I don't know if this means the firmware is bugged, but 4 longs short of what the proptool says I can upload.
    Is that just because of my program, you'd think proptool would see that...

    I don't think being 4 longs short is a big deal, is this a bug in the WX firmware?
    I haven't tried to download this program with the PropPlug to test if it does the same, I supposed I could.
    I did this ram space fill (7,905) on the prop while a PropPlug was connected to the DBG (debug) port of the WX module to see any errors, none so far.
    ''*******************************************
    ''*  Telnet Wireless WX Ansi Command Demo and RAM space filler *
    ''*  Author: Clock Loop @ parallax forums   *           
    ''*******************************************
    
    CON  
    
      _clkmode = xtal1 + pll16x
      _xinfreq = 5_000_000
      
              
    CON
    
      Tx             = 30   'serial out to wx device
      Rx             = 31   'serial in from wx device
    
    OBJ
    
      Term          : "FullDuplexSerial" 
    
    VAR
    
    long   FillIt[7905]  
      
    Pub Port23Display | Years, Dayz, Hour, Mnit
    
    
        Years := 13
        Dayz  := 6
        Hour  := 3
        Mnit  := 45
    
    
      
      term.start(Rx, Tx, 0, 115_200)                                    '1cog start telnet terminal
    
        waitcnt(80_000_000 + cnt)  
     
        
        term.str(string(27))    'Set command mode                                                     
        term.str(string("[2J"))    'Clear telnet screen
    
    
        term.str(string(27))    'Set command mode 
        term.str(string("[1;1f"))  'Set Position
          
        term.str(string(27))    'Set command mode
        term.str(string("[0m")) 'Turn off character attributes
    
                                 
        '--------------SOME ANSI COMMAND CODE INFO---------
            'term.str(string(27))  'Set command mode          
            'term.str(string("[2J")) 'clear screen
                      
            'term.str(string(27))    'Set command mode
            'term.str(string("[0m")) 'Turn off character attributes
            'term.str(string("[1m")) 'Turn bold mode on
            'term.str(string("[2m")) 'Turn low intensity mode on
            'term.str(string("[4m")) 'Turn underline mode on
            'term.str(string("[5m")) 'Turn blinking mode on
            'term.str(string("[7m")) 'Turn reverse video on    
            'term.str(string("[8m")) 'Turn invisible text mode on
         
            'term.str(string("#3"))  'Double-height letters, top half 
            { 
            Esc#3   Double-height letters, top half         DECDHL
            Esc#4   Double-height letters, bottom half      DECDHL
            Esc#5   Single width, single height letters     DECSWL
            Esc#6   Double width, single height letters     DECDWL
            }
            
                  
      
    Repeat
    
            
            term.str(string(27))    'Set command mode 
            term.str(string("[1;1f"))  'Set Position
    
            waitcnt(80_000_000 + cnt) 
            
            term.str(string(27))    'Set command mode 
            term.str(string("[5;5f"))  'Set Position 
    
            term.str(string(27))  'Set command mode 
            term.str(string("[31m")) 'Red color text  
            
            term.str(string("UpTime   : "))
    
            term.dec(Years)       
            term.str(string(":Years  "))
            term.dec(Dayz)       
            term.str(string(":Days   "))
            term.dec(Hour)       
            term.str(string(":Hours   "))
                    
            term.dec(Mnit)       
            term.str(string(":Min   "))
    
    
    
    
    Dat
    {{
    
      Terms of Use: MIT License
    
      Permission is hereby granted, free of charge, to any person obtaining a copy of this
      software and associated documentation files (the "Software"), to deal in the Software
      without restriction, including without limitation the rights to use, copy, modify,
      merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
      permit persons to whom the Software is furnished to do so, subject to the following
      conditions:
    
      The above copyright notice and this permission notice shall be included in all copies
      or substantial portions of the Software.
    
      THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
      INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
      PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
      HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
      CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
      OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 
    
    }}
    
  • Clock Loop wrote: »
    David Betz wrote: »
    I got my USB2serial ports working with Ubuntu running under VirtualBox on my Mac. Now I just need to get a working flash script...


    Sorry, i was doing some garden work, laying new bricks in the greenhouse. Gotta get away from the screen once in a while.

    Heres the esptool.py working script. It DOES NOT check the file system size, it just requires the user to do it.
    Thanks!
    I do not know how to query for the size and store it in a variable to check it in a bash script, i am not that smart.
    I could try to do it by searching the nets. The flash size is 4MB, I think your old c version used 2mb (the python version is case sensitive)
    The reason we used 2MB is that the original Parallax WX modules had only 2MB of flash and using 2MB allowed the firmware to work on all modules. I'm not sure if any 2MB modules were ever sold though. They might have just been the prototypes we were using while developing the product.

  • @"Clock Loop" I tried your new flash script with mixed results. First, I had to change "./esptool.py" to "esptool" because Ubuntu installed the python script in /usr/local/bin with the name "esptool" without the ".py". Second, I had to remove the --compress option because my ESP8266 board doesn't support that apparently. I have to admit that the board I'm using at the moment is not the Parallax WX module so maybe --compress isn't a problem with that module. I'm wondering if we should include esptool.py with the WX firmware release or if we should just assume that the user has it already installed?
Sign In or Register to comment.