-
-
Just tried "Latest build here",
- got a selectbox (first time, I saw this box)
- selected 1.3/1.4
- reset the board
- started flashing
- after some seconds got "Can't find STM32 Bootloader"
Checked flashing with a V1.80 and that runs fine.
Tried with your link again and got an error.
Do I have the wrong board for this build (it's from 1st kickstarter) ? - got a selectbox (first time, I saw this box)
-
nice article about Espruino (german language)
http://www.heise.de/developer/artikel/JavaScript-und-das-Internet-of-Things-Teil-1-Espruino-und-Tessel-2806613.html -
WOW,
thanks and gratulation to Blaz, Kolban and last not least to Gordon.
Sometimes I still cannot believe how Javascript can run on these chips.
Not only that, all of these magic words like I2C, SPI, ADC.... are supported.
Guys having more knowledge than I will ever have spend their time.
And at the end people like me will benefit from that, unbelievable.
Can't wait to get first binary, to replace my solution based on nodemcu. -
Based on my poor knowledge, I cannot help directly.
If you want somebody for testing, please let me know.
Right now, I'm working with nodemcu(lua) on ESP8266 with ESP01/07/devkit
Actual project is a data logger on Espruino, using ESP8266 with nodemcu as web server.
Switching to Javascript(Espruino) would make life much nicer.
BTW, is flashing done with this https://github.com/nodemcu/nodemcu-flasher ? -
-
I tried to get my hands on compile option. All tests up to now went fine, at least I did'nt get any message.
Interesting is, that compiled needs more memory compared to not compiled.
What happens, if compile fails, will I get any error message ?
Setting compile option on top of an object, will everything inside this object be compiled, or do I need to add compiled to all functions inside the object ?
Does compiled option take more memory compared to not compiled ? -
-
I need to read some data from a file (fs.read) and later on write a lot of data to uart.
This takes some time, and I don't want to block other code during this.
Is Espruino adding idles states internally, or do I need to add something like setTimeout(function(){...},1) inside the loops for reading from SD and writing to UART ? -
-
Just tried to reproduce syncStat problem in a different way. Typed commands in terminal window:
- reset()
- require("fs").readdir()
- require("fs").syncStat("Juergen1_data.bin")
There is no response from Espruino, so I - closed connection
- clicked connect button and got an empty list, no COM port available anymore
- wrote these lines and about a minute later, a Com port is available
- tried to connect and got Connection failed
- unplugged Espruino Board from USB
- plugged Espruino Board
- now connect worked fine
- syncStat worked fine
Hmmm, whats that ? So tried again: - reset()
- require("fs").readdir()
- require("fs").statSync("Juergen1_data.bin")
- Espruino hangs again
- reset()
-
running this prints "..." on screen, so variable startAt is corrupted
function rtc2Date(dt){ var t,d; d = dt.split(" ")[0]; t = dt.split(" ")[1]; d = d.split("/"); t = t.split(":"); return new Date(d[2] + 2000,d[1],d[0],t[0],t[1],t[2]); } var fs = require("fs"); var data = JSON.parse(fs.readFile("Juergen1_ctrl.json")); var startAt = rtc2Date(data.options.startAt); //console.log(startAt); var entrys = fs.statSync("Juergen1_data.bin").size / 20; console.log(startAt);
uncommented first console.log and it works fine:
function rtc2Date(dt){ var t,d; d = dt.split(" ")[0]; t = dt.split(" ")[1]; d = d.split("/"); t = t.split(":"); return new Date(d[2] + 2000,d[1],d[0],t[0],t[1],t[2]); } var fs = require("fs"); var data = JSON.parse(fs.readFile("Juergen1_ctrl.json")); var startAt = rtc2Date(data.options.startAt); console.log(startAt); var entrys = fs.statSync("Juergen1_data.bin").size / 20; console.log(startAt);
Also had problems sometimes by using fs.statSync from terminal window. Connection to com-port was lost, and I had to reset and restart everything.
IMHO, this could be a problem around memory management for fs.statSync.
Using 1v80 on Espruino Board
Data returned from readFile is this:{ "tags": { "MQ2": "Methane, Butane, LPG, smoke", "MQ4": "Methane, CNG Gas", "MQ7": "Carbone Monoxide", "temp": "Temp", "rh": "Humidity" }, "options": { "interval": 60000, "groupLength": 10, "startAt": "16/06/15 22:34:23" } }
-
-
-
-
-
-
Just checked with 1v79 and an external sdcard (catalex SPI MicroSD Card Adapter V1.0) on Espruino V1.3. Connected like this:
SPI1.setup({mosi:B5, miso:B4, sck:B3}); E.connectSDCard(SPI1, B6 /*CS*/); var fs = require("fs"); var i = 0; fs.appendFile("Juergen.json","hugo\n"); setInterval(function(){ digitalWrite(LED1,true); fs.appendFile("Juergen.json","emilio"); setTimeout(function(){digitalWrite(LED1,false);},200); i++; },2000);
Got same problems as mentioned above, lot of strange characters.
-
-
-
Sorry same problem, my testing is this:
- unmount
- setup SPI according to your code
- connectSDCard
- E.openFile(fileName,"w+")
- read directory (with or without sync) and mostly everything is fine
- write to file
- read Directory (with or without sync) and mostly get those strange characters
- read file and get strange characters too
- read Directory one more time and get nice list (mostly)
- read file and get strange characters
BTW, called E.unmountSD and readdir/readFile still returns data.
Unplugged from power and plugged to power, readFile still returns strange characters.I will go back to 1v72 to get my small project running. Promised to my friends, to get it running this week.
- unmount
-
Filesystem is fat32 on a normal Espruino board with micro SD slot.
Tested with 3 boards and 3 SDcards now, always the same.
Next went back some versions, problem started in 1V73.I'm working on a simple datalogger, reading values from several sensors over days and writing to file in JSON format. Will be used first to collect environmental data from mq-sensors, temperature, humidity, ....There is no big problem doing this with older version.
-
-
Writing to SD card creates strange results.
Sometimes file is created several times.
Sometimes file holds strange characters.
Sometimes readdir returns strange characters.
Please see attached screenshot.var fs = require("fs"); var i = 0; fs.appendFile("Juergen.json","hugo\n"); setInterval(function(){ digitalWrite(LED1,true); fs.appendFile("Juergen.json","emilio"); setTimeout(function(){digitalWrite(LED1,false);},200); i++; },2000);
First test, based on above example works fine.
Second test based on "some documentation here" also works.
Tested single stepping works fine inside function.
Calling foo(a,b) is treated as one step, is there a way to step into functions ?
What is difference between i l and i s ?
It's a big step forward, I love it and will do some more testing tomorrow.