Recording datas into internal memory

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Recording datas into internal memory

#1 Post by Sylv_01 » 04 Aug 2022, 16:33

Hello, I have a project with a Wemos D1 Mini and EspEasy : I want to use this like a data logger for noise measurement.
Do you know how it's possible to record datas in Wemos memory, into a text file for example ?
And how can I read this file after recording ?
Many thanks for your help !

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#2 Post by Ath » 04 Aug 2022, 16:59

You can use the Cache controller, that is included in the Custom builds available from the regular Github downloads page.

Description is a bit compact, but it is complete, and should get you going.

What type of sensor do you intend to use to collect the noise measurements?
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#3 Post by Sylv_01 » 05 Aug 2022, 07:42

Hello, and thanks for your quick reply !
I will take a look about that...
My sensor is a GY-MAX4466, like this :
https://www.adafruit.com/product/1063

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#4 Post by Ath » 05 Aug 2022, 08:58

AFAICS, that device needs to be connected to an analog input, as there is no specific plugin available in ESPEasy, but analog should work OK for your use.
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#5 Post by Sylv_01 » 05 Aug 2022, 09:03

Ath wrote: 05 Aug 2022, 08:58 AFAICS, that device needs to be connected to an analog input, as there is no specific plugin available in ESPEasy, but analog should work OK for your use.
Yes, I will see how I can read value from analog input (connected to my device) and record it into RTC memory with Cache controller

TD-er
Core team member
Posts: 6354
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: Recording datas into internal memory

#6 Post by TD-er » 05 Aug 2022, 09:28

It will first record it into RTC to make sure there is a large enough chunk of data to write to flash.
The reason it is put in RTC first is to make sure no data gets lost in cache of a crash or warm reboot.

There is a .htm file in the source tree (dump6.htm I think it is named) which you need to upload to the filesystem too.
When opening this file (loaded from the ESPs filesystem in a new tab for example), it will fetch the .bin files and decode them in JavaScript and then generate a .CSV file from it to analyze in just any spreadsheet program.

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#7 Post by Sylv_01 » 05 Aug 2022, 11:38

TD-er wrote: 05 Aug 2022, 09:28 It will first record it into RTC to make sure there is a large enough chunk of data to write to flash.
The reason it is put in RTC first is to make sure no data gets lost in cache of a crash or warm reboot.

There is a .htm file in the source tree (dump6.htm I think it is named) which you need to upload to the filesystem too.
When opening this file (loaded from the ESPs filesystem in a new tab for example), it will fetch the .bin files and decode them in JavaScript and then generate a .CSV file from it to analyze in just any spreadsheet program.
Thanks for your help ! :D
It seem be exactly what I want...

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#8 Post by Sylv_01 » 09 Aug 2022, 13:49

Hello guys,
I've just downloaded the latest build :
https://github.com/letscontrolit/ESPEas ... a-20220809
and unzipped it...
We are ok, that I should use this binary file, for my Wemos D1 Mini (ESP8266) ?
Screen Shot 08-09-22 at 01.43 PM.PNG
Screen Shot 08-09-22 at 01.43 PM.PNG (25.45 KiB) Viewed 305 times

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#9 Post by Ath » 09 Aug 2022, 13:59

You should install the same name of the .bin file you used before, except of course with the new date ;)
So for a Wemos D1 mini that should be the correct one.
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#10 Post by Sylv_01 » 09 Aug 2022, 14:06

Thanks for you quick reply !
I'm not sure to remember witch I'm using actually, I think it's "ESP_Easy_mega_20210802_normal_ESP8266_4M1M.bin"...
But you told me, that Cache Controler is only on the custom build, so I believe I have to use the binary with "xxx_custom_xxx" on the name ???

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#11 Post by Ath » 09 Aug 2022, 14:30

That's correct.

You can see the currently installed .bin file in the Info page (available from 'Main/More info' or 'Tools/Info') in the Firmware section.
'Custom' is currently the only ESP8266 build that has the Cache controller included.

Edit:
And as long as you keep the Flash/Filesystem config (4M1M) the same, you can install any build for the same processor (ESP8266, ESP32 or ESP32s2) and keep your current configuration. Though some builds might have a few more/different plugins or less features available.

When doing the upgrade via 'Tools/Update Firmware', usually from the computer, you can also select the .bin.gz file; the OTA feature knows how to handle this compressed file, and as it is smaller, it's a little quicker to upload 8-)
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#12 Post by Sylv_01 » 09 Aug 2022, 14:43

Ok, many thanks for your help !
I will let you know if everything is working properly when I receive my sensor.

TD-er
Core team member
Posts: 6354
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: Recording datas into internal memory

#13 Post by TD-er » 09 Aug 2022, 16:53

You can already start testing by using something like the system info plugin.
This generates samples like free memory, system load, etc. (whatever you select)
Then you can send the data from a task running the sysinfo plugin to send it to the "Cache Controller" and you can see how the data is being saved, how to process it, etc.

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#14 Post by Sylv_01 » 11 Aug 2022, 09:27

Hello,
Previously, my Wemos was configured with my home's wifi...
I have flashed it with custom firmware (I've flashed it with blank_4MB firmware before), and I'm trying to connect here at job, but I don"t see wifi SSID "espeasy_0", like original config...
How can I reset the Wemos to see ad-hoc access point ?
Thanks in advance !

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#15 Post by Ath » 11 Aug 2022, 10:28

The default AP should be ESP_Easy (unless you have made your own Custom build), but please keep in mind that after 5 minutes of inactivity, the AP is stopped. A reset/power cycle of the device should get it active again.
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#16 Post by Sylv_01 » 11 Aug 2022, 10:40

Yes thanks, I manage to see ESP_easy wifi, but I can't connect my phone...
I'm trying with "espconfig" password, but no way !
I think I will try this evening at home with an another tablet... :evil: :evil: :evil:

User avatar
Ath
Normal user
Posts: 1815
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Recording datas into internal memory

#17 Post by Ath » 11 Aug 2022, 11:16

I think you switched the words in that password...
/Ton

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#18 Post by Sylv_01 » 11 Aug 2022, 11:58

you mean that the password is "configesp" ??? :shock: :shock:

TD-er
Core team member
Posts: 6354
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: Recording datas into internal memory

#19 Post by TD-er » 11 Aug 2022, 13:07

Sylv_01 wrote: 11 Aug 2022, 11:58 you mean that the password is "configesp" ??? :shock: :shock:
Yep, as it has been for ages ;)

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#20 Post by Sylv_01 » 11 Aug 2022, 13:22

TD-er wrote: 11 Aug 2022, 13:07
Sylv_01 wrote: 11 Aug 2022, 11:58 you mean that the password is "configesp" ??? :shock: :shock:
Yep, as it has been for ages ;)
You read both in internet, when you're cherching "password ESP_Easy" !! :twisted: :twisted:

TD-er
Core team member
Posts: 6354
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: Recording datas into internal memory

#21 Post by TD-er » 11 Aug 2022, 13:36

Where did you read this?

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#22 Post by Sylv_01 » 11 Aug 2022, 14:17

I don't remember exactly where, I read a lot of page about the wifi connection !

TD-er
Core team member
Posts: 6354
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: Recording datas into internal memory

#23 Post by TD-er » 11 Aug 2022, 15:00

If it is anywhere on pages we manage, I will for sure remove this info.

Sylv_01
Normal user
Posts: 13
Joined: 25 Aug 2021, 15:58

Re: Recording datas into internal memory

#24 Post by Sylv_01 » 11 Aug 2022, 15:04

TD-er wrote: 11 Aug 2022, 15:00 If it is anywhere on pages we manage, I will for sure remove this info.
No, it's not into this forum, I think it was on a tuto somewhere....

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests