• Beyond what I posted earlier, here is a web IDE console output whenever I upload a code:

    My code:

    var wifi = require("Wifi");
    wifi.setHostname("Espruino");
    wifi.stopAP();
    wifi.setIP({ip:"192.168.1.20",gw:"192.16­8.0.1",netmask:"255.255.255.0"},function­(err){});
    wifi.connect("SSID",{password:"PASS"},fu­nction(err){
        console.log("connected? err=",err,"info=", wifi.getIP());
      
        wifi.save();
    });
    
    SPI1.setup({mosi:D7,miso:D6,sck:D5});
    E.connectSDCard(SPI1,D8);
    
    var files = require('fs').readdirSync();
    for (var i in files)
      console.log("Found File" + files[i]);
    

    Console Output:

    >
     ____                 _
    |  __|___ ___ ___ _ _|_|___ ___
    |  __|_ -| . |  _| | | |   | . |
    |____|___|  _|_| |___|_|_|_|___|
             |_| espruino.com
     1v96 (c) 2017 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 0x20 chip 0x4016
    >ASSERT(jsvGetLocks(var)>0) FAILED AT src/jsvar.c:674
      #1[r1,l2] Object {
        #2[r1,l2] Name String [1 blocks] "\xFF"      #3[r1,l2] Object {
            #6[r1,l2] Name String [2 blocks] "timers"          #8[r2,l1] Array(0) [ ]
            #9[r1,l2] Name String [2 blocks] "watches"          #11[r2,l1] Array(0) [ ]
            #13[r1,l2] Name String [1 blocks] "net"          #14[r1,l2] String [1 blocks] "\x04\x00\x00\x00\x00\xFF\xFF\xFF"
            #21[r1,l2] Name String [2 blocks] "modules"          #23[r1,l1] Object {
                #25[r1,l2] Name String [1 blocks] "Wifi"              #24[r5,l3] ...
     
              }
            #15[r1,l2] Name String [2 blocks] "history"          #26[r1,l1] Array(3) [
                #27[r1,l2] Name Integer 0              #17[r1,l1] String [3 blocks] "var wifi = require(\"Wifi\");"
                #29[r1,l2] Name Integer 1              #30[r1,l1] String [3 blocks] "wifi.setHostname(\"Espruino\");"
                #28[r1,l2] Name Integer 2              #34[r1,l1] String [2 blocks] "wifi.stopAP();"
              ]
          }
        #16[r1,l2] Name String [1 blocks] "wifi"      #24[r5,l3] NativeFunction 0x4021bc6c (0) { }
      }
    ---console end---
     ets Jan  8 2013,rst cause:2, boot mode:(3,6)
    load 0x40100000, len 2408, room 16
    tail 8
    chksum 0xe5
    load 0x3ffe8000, len 776, room 0
    tail 8
    chksum 0x84
    load 0x3ffe8310, len 632, room 0
    tail 8
    chksum 0xd8
    csum 0xd8
    2nd boot version : 1.6
      SPI Speed      : 80MHz
      SPI Mode       : QIO
      SPI Flash Size & Map: 32Mbit(512KB+512KB)
    jump to run user1 @ 1000
    sp 0x3ffffcb0
    epc1=0x40001800, epc2=0x00000000, epc3=0x00000000, excvaddr=0xffffffef, depc=0x00000000
    Fatal exception (28):
    epc1=0x40001800, epc2=0x00000000, epc3=0x00000000, excvaddr=0xffffffef, depc=0x00000000
    Fatal exception (28):
    epc1=0x40001800, epc2=0x00000000, epc3=0x00000000, excvaddr=0xffffffef, depc=0x00000000
    Fatal exception (28):
    ...
    

    this last 2 lines repeat indefinetly, no matter if I hard reset the device. The only way out of this loop is to erase the flash and reupload the firmware

About

Avatar for FStech @FStech started