Gosh, Sailquik, the entire LiPo and Li-ion charging industry uses voltages to determine percent of charge. There are lots of references out there that show a quite linear curve of voltage vs %. Millions of "smart" chargers for RC (planes, boats, cars, all of it) charge and discharge Li based batteries to keep them in top shape, all based on voltage to determine percent of charge. Since Li batteries degrade if stored fully charged, these chargers all allow you to discharge to something like 50% to 70% for storage. Heck, even "smart" batteries have onboard circuitry to achieve this as well. DJI drone batteries have this.
On the other hand, lead acid batteries do not display this. You have to use current and time to determine percent of charge. The battery monitor for the house batteries in my Sprinter RV uses current and time.
OK, I am not battery expert at all, but I have had this explained to me by an electric engineer, and found the same info online in battery forums:
Quotes from "experts":
"Due to the very flat charge/discharge curves for LiFePO4 batteries it is not practical to use voltage to accurately determine the SOC. On the other hand due to their very high coulomb/current efficiency of around 99.5% you can get very accurate SOC readings by keeping track of the current going into and out of the battery."
and then this:
"The only reasonable SOC you can get from voltage is at the extremes - say > 90% and < 10%. But best life is obtained when you avoid the extremes."
So it seems that for our use in these types of devices, it might not matter much? All we mostly want to know is if it is fully charged, or very flat. Assuming most people would fully charge their device after each session and not assume a percentage of, say, 50% before a session was really half state of charge.
But if fully charging all the time if not good for best life of the battery, where does that leave us?
Or is the chemistry and characteristics of these particular small batteries different from LiFePo4?
And in fact I have been advised that the exact opposite is the case with Lead Acid/AGM batteries, and there are numerous charts online that purport to give you % state of charge estimates directly related to battery voltage. But that is not relevant for this use. ![]()
Jan.
I loaded the 38400 firmware for the m10. The shutdownscreen show 9600b. I think the screen text is not changed to 38400..

I must have made a mistake with naming the bin files, I will check it. Does the chinese M10 gps works with this bdrate ?
A new update SW5.72 is on github with next changes :
.txt files configurable ON/OFF over webserver, if name_MAC_counter, .txt file is necessary for keeping track counter !!!
When Wifi, NTP time is set, if needed, directory "Archive" is created
Added link "Archive files" in header : to move files to the Archive dir when older then archive_days
Added link "Archive list" in header : to list all the files on the SD, dir "Archive" included
Delete file link : no call to confirmation page anymore.
Link to overview Board / Sail logo updated
STAT1 screen Sat -> last 2s, 3m/s for new value needed
STAT6 screen Mile -> NM
Sleep screen bat voltage -> bat percent, 4.2=100%, 3.4=0%
The Archive helps to minimize loading times of the file listing, as older files will not be listed anymore. However, they are still accessible with "Archive list".
If your voltages from the lipo are out of range, you can adjust the reading in the configuration with cal_bat. A full loaded Lipo should give 4.20 Volt. Adjust the default 1.75->1.65...1.85 until the reading is good.
If the voltage reading drops below 3.1V, the ESP will go to standby. If the voltage drops further to 2.4V, the internal protection of the Lipo will cut of and the ESP will switch off completely.
If the voltage exceeds +4.25 V (not the reading, just the measuring of the protection chip in the lipo), the protection chip will cut off, and the lipo will not charged higher.
I never tested this protection of the lipo, but I believe this is pretty robuust....
Freezer proposed some nice logos for the project :

Greetings, Jan.
I was not yet completely happy with the design. Wanted to blend a GPS icon with the Espressif fill. Did not like te rounded bottom. I ended up with the following: It also looks like a little fish or a transmitted signal. It might just do. When scaling down in pixels the text should be dropped. One could make a nice 3D printed tag to keep the magnet. Let me know what you think...

A new update SW5.72 is on github with next changes :
Greetings, Jan.
Thanks again Jan, I've been off line crossing the Nullabor, but I'll install this now
Hi All
Been building away now for a few days and have a few ideas that may or may not have been discovered before.
I have found you can slide a knife behind the e-paper and carefully lift it off. Handy for soldering as it gets it out the way but more importantly (for my OCD) you can centre it when putting it back on using double sided tape. This way when in the smallest case possible (70mm wide) the screen will be centred. Need a new centred cover piece @Flex for your boom mount......
Also rather than using the microSD card slot that sticks out the top it is possible to use the SPI pins to connect a miniSD adapter that holds the microSD. Can probably go direct to a microSD but I just wanted to try it and had the microSD adapter handy. Have tested and seems to work fine.
Doing these two things means you can get everything into a ~70mm x ~40mm x Xmm enclosure.
PS. Got an alpha PB today testing my unit around a round about in the car :) Cant wait to use it on the water.
E-paper usable screen now centred on the 70mm width.

mircoSD adapter wired dirctly to SPI.

Sailquik, if you google something like "B6 Li balance charger" you will see that there are dozens of manufacturers out there that supply millions of B6-design chargers to the universe of RC enthusiasts. They all use the same basic firmware and algorithms to calculate percentage based on voltage. They use this for balancing the multi-cell batteries as well as conditioning the batteries for the best voltage for storage. Most work with LiPo, Li-ion, and LiFePO4 batteries. Some even include NiCd, NiMH, and Pb. I have three of them from different manufacturers. I use them for model boats and drones.
For LiPo the voltages run from 3.0V per cell at fully discharged to 4.2V per cell at 100% charged. 3.85V per cell for storage. Analogous numbers for Li-ion and LiFePO4. Those slopes are steep enough to make good calculations of percentage and control. With these chargers you can charge, fast-charge, discharge, balance cells, and charge to storage. You have full menu-programmable control over current, voltage, and times.
The RC hobby would not exist without these smart chargers. It all started 40 years ago when all we had were NiCd batteries.
I need to add something. The B6 chargers do not display, or even use, percentage for their algorithms. They use voltage only. They have default voltages for the different battery types they support, but you can easily adjust them in the menus.
Since Li batteries should not be stored fully charged (they degrade at 4.2 V per cell), the B6 chargers have an excellent feature where you can charge, or discharge, them to 3.85 V per cell for storage. Also, they balance the voltage of multi-cell batteries. This is important.
hello all,
one of my new units seemed to freeze on boot, it's just locked on this screen.
I haven't seen this before, so wondering what the recommend process is?
Leave it as is for a week+ so it totally drains flat?
Then charge and see what happens?
Issue happened Sunday so I still have a few more days I think until properly flat as the device was apparently full charged.

Have you tried putting on and off the charger a couple of times?
oh no, I have not! Will try!
Have you tried putting on and off the charger a couple of times?
oh no, I have not! Will try!
no joy here... will let it sit for a few more days then pop on charger to see if it comes back
Great work Jan, and everyone else involved in developing this.
I've just assembled my first unit and seem to be having problems getting data from the GPS. The unit boots fine and gets to the Wifi off screen, but never moves to the Stat screen (which I understand it will do when it gets a fix). The Beitian 220 has red and blue flashing lights indicating it has a fix and is transmitting. I've checked my solders, reflashed firmware, tried different configs, left it outside with clear skies, driven around with it... any other suggestions?
Does it automatically connect to home wifi? I have to walk a block from home to get mine to boot into logging stats mode.
Hi All
Been building away now for a few days and have a few ideas that may or may not have been discovered before.
I have found you can slide a knife behind the e-paper and carefully lift it off. Handy for soldering as it gets it out the way but more importantly (for my OCD) you can centre it when putting it back on using double sided tape. This way when in the smallest case possible (70mm wide) the screen will be centred. Need a new centred cover piece @Flex for your boom mount......
Also rather than using the microSD card slot that sticks out the top it is possible to use the SPI pins to connect a miniSD adapter that holds the microSD. Can probably go direct to a microSD but I just wanted to try it and had the microSD adapter handy. Have tested and seems to work fine.
Doing these two things means you can get everything into a ~70mm x ~40mm x Xmm enclosure.
PS. Got an alpha PB today testing my unit around a round about in the car :) Cant wait to use it on the water.
E-paper usable screen now centred on the 70mm width.

mircoSD adapter wired dirctly to SPI.

Nice one Alhop. Very early on in this thread someone removed the SD card holder and directly soldered the micro SD card behind the board for low profile version. Seems that idea and your centred screen idea will make for a pretty slick looking unit. I tried removing one of my dead units screen like you said and managed to crack the display (to be fair the old solder was in the way which was probably the cause). Really need to take care if doing this. I don't think you need double sided tape as the goo seems to hold the display in place well enough (assuming you are going to epoxy the unit). The tape will also make for a very tight fit in the case. Based on your request I modified my print to include a centre trim version for those that are game. I also started a public collection of various prints which Jan may want to include on his wiki link so people can look at the various options of 3D prints. If there are any other variations of prints out there that people want to share (or I've missed) then please repost on this thread an I'll add to collection. www.printables.com/social/32187-flex/collections/474942?o=newest
Great work Jan, and everyone else involved in developing this.
I've just assembled my first unit and seem to be having problems getting data from the GPS. The unit boots fine and gets to the Wifi off screen, but never moves to the Stat screen (which I understand it will do when it gets a fix). The Beitian 220 has red and blue flashing lights indicating it has a fix and is transmitting. I've checked my solders, reflashed firmware, tried different configs, left it outside with clear skies, driven around with it... any other suggestions?
There's a min speed before display starts. You have to be moving
I'm running v5.72 of the software. It puts a line on the screen "Waiting for stats". Looking through the code this line will be updated to "Waiting for speed" once the number of satellites used in the GPS data is 5 or above, regardless of movement (but I have tried moving too).
I'm thinking - either I don't have enough satellites, or I'm not getting any data through
Great work Jan, and everyone else involved in developing this.
I've just assembled my first unit and seem to be having problems getting data from the GPS. The unit boots fine and gets to the Wifi off screen, but never moves to the Stat screen (which I understand it will do when it gets a fix). The Beitian 220 has red and blue flashing lights indicating it has a fix and is transmitting. I've checked my solders, reflashed firmware, tried different configs, left it outside with clear skies, driven around with it... any other suggestions?
There's a min speed before display starts. You have to be moving
He mentioned he's driven around Decrepit so that's probably not it. Microbe, do you have the Arduino IDE installed and have you checked the output on the serial monitor (in the Arduino IDE) on boot up (need to connect USB cable to computer to do this)? This will help with troubleshooting. Copy and paste the output you get here if it's not obvious. (possibly Tx and Rx wires are swapped??)
@Rolz : The e-paper is stuck in the refresh (BW inververted). This is rather strange, as it is not influenced by the ESP32. I guess there was / is a power interruption as the refresh was going on.
@Microbe : Does the blue LED flashes with the choosen GPS - rate ? Default this is 1 Hz, but if you set it to 10 Hz, it should flash @ 10 Hz. This is a sign that the communication from ESP -> Beitian is OK. The other direction is best to check with a "serial monitor". If you have the Arduino IDE installed, you can use the serial monitor from the Arduino IDE . Set the correct COM port, and set the baudrate to 115200 bd.
Another simple terminal program is HTerm : www.der-hammer.info/pages/terminal.html
When the ESP boots, you should see next information :
ets Jun 8 2016 00:22:57
rst:0x5 (DEEPSLEEP_RESET),boot:0x17 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:1216
ho 0 tail 12 room 4
load:0x40078000,len:10944
load:0x40080400,len:6388
entry 0x400806b4
setup Serial
Serial Txd is on pin: 1
Serial Rxd is on pin: 3
Wakeup caused by external signal using RTC_IO
Serial2 9600bd Txd is on pin: 33
Serial2 9600bd Rxd is on pin: 32
$GNTXT,01,01,02,u-blox AG - www.u-blox.com*4E
$GNTXT,01,01,02,HW UBX-M8030 00080000*60
$GNTXT,01,01,02,ROM CORE 3.01 (107888)*2B
$GNTXT,01,01,02,FWVER=SPG 3.01*46
$GNTXT,01,01,02,PROTVER=18.00*11
$GNTXT,01,01,02,GPS;GLO;GAL;BDS*77
$GNTXT,01,01,02,SBAS;IMES;QZSS*49
$GNTXT,01,0SDCard found!
SD Card Size: 15193MB
Loading configuration...
open the config.txt
Print config file...{
"cal_bat": 1.75,
"cal_speed": 3.60,
"sample_rate": 5,
"gnss": 3,
"speed_field": 1,
"speed_large_font": 1,
"bar_length": 1852,
"Stat_screens": 541,
"Stat_screens_time": 2,
"stat_speed": 1,
"GPIO12_screens": 54,
"Board_Logo": 10,
"Sail_Logo": 4,
"sleep_off_screen": 11,
"logSBP": 1,
"logUBX": 1,
"logUBX_nav_sat": 1,
"logGPY": 1,
"logGPX": 0,
"file_date_time": 1,
"dynamic_model": 0,
"timezone": 1,
"UBXfile": "M8_ROM3",
"Sleep_info": "Call +32 476 276 204",
"ssid": "TP-LINK_F150",
"password": "55692786"
}
Set ublox UBX_OUT
Set ublox UBX_GNSS3 : GPS, GLONAS & GALILEO
ACK 662
Check MON_GNSS settings
GNSS= :15311
Ask ublox Unique ID ID= :5095798765
Check UBX_MON_VER
SW Ublox=ROM CORE 3.01 (107888)
HW Ublox=00080000
Set ublox NAV_PVT_ON
ACK 61
Set ublox NAV_DOP_ON
ACK 61
Set ublox NAV_SAT_ON
ACK 61
Set ublox to 38400BD
ACK 60
SW Ublox=ROM CORE 3.01 (107888)
HW Ublox=00080000
Extensions Ublox= FWVER=SPG 3.01, PROTVER=18.00, GPS;GLO;GAL;BDS, SBAS;IMES;QZSS, A?, ,
3
11
Set rate Ublox ACK 68
ESP32 soft AP started
T5 MAC adress: ESP32 soft AP started
ESP32 Connected to SSID Station mode
ESP32 Soft AP switched off
ESP32 Connected to WiFi Network
ESP32 Connected to WiFi Network
.
Connected to TP-LINK_F150
IP address: 192.168.0.101
SD Card Type: SDHC
mDNS responder started
Ftp server waiting for connection on port 21
Thanks everyone
Step 1: Changing the GPS sample rate did change the flashing rate of the LED
step 2: here's the output from the serial monitor:
ho 0 tail 12 room 4
load:0x40078000,len:9720
ho 0 tail 12 room 4
load:0x40080400,len:6352
entry 0x400806b8
setup Serial
Serial Txd is on pin: 1
Serial Rxd is on pin: 3
Wakeup was not caused by deep sleep: 0
Serial2 9600bd Txd is on pin: 33
Serial2 9600bd Rxd is on pin: 32
?O???V?g?CBJKBJH??C?ac?C??cBKCb)g??
?SDCard found!
SD Card Size: 15193MB
Loading configuration...
open the config.txt
Print config file...
{
"cal_bat": 1.75,
"cal_speed":1.94384,
"sample_rate":1,
"gnss":2,
"speed_field":1,
"bar_length":1852,
"Stat_screens":321,
"GPIO12_screens":421,
"Logo_choice":42,
"sleep_off_screen":11,
"logOAO":1,
"logUBX":1,
"dynamic_model":0,
"timezone":8,
"UBXfile":"ESP_GPS",
"Sleep_info":"",
"ssid": "",
"password": ""
}
Set ublox UBX_OUT
Check MON_GNSS settings
Ask ublox Unique ID Check UBX_MON_VER
Set ublox NAV_PVT_ON
Set ublox NAV_DOP_ON
Set ublox to 38400BD
SW Ublox=
HW Ublox=
Extensions Ublox= , , , , , ,
0
0
Set rate Ublox ACK 68
T5 MAC adress: ESP32 soft AP started
ESP32 soft AP started
..........No Wifi connection !
There must be a connection problem between the Tx (transmit) from the GPS to the Rx (receive : GPIO32) from the ESP32, as there is no ACK61 or other messages from the gps. The other connection seems to be OK, as the blue LED flashes @gps rate.
Check the soldering on the GPIO32, and on the side of the Beitian. Push the reset button for at least 1 s (to depower and reset the Beitian, all LEDs should go out then), and check the serial monitor again.
If you have a multimeter, measure the resistance between the GPIO32 and the Beitian Tx, this should be < 1 ohm. Check the resistance between GPIO32 / 33, should be higher then 10 kohm (unintended solderbridge ???).
Nice trouble shooting guys, I'm sure you'll solve this.
But on a different note, I just discovered you can't update firmware in AP mode unless the device has an internet connection. Luckily Peter told me what was going on and we have WiFi here, so I have updated without using AP mode. With any luck we'll get a sail today and I can try it out.
hello all,
one of my new units seemed to freeze on boot, it's just locked on this screen.
I haven't seen this before, so wondering what the recommend process is?
Leave it as is for a week+ so it totally drains flat?
Then charge and see what happens?
Issue happened Sunday so I still have a few more days I think until properly flat as the device was apparently full charged.

hey all, just an update on this one, decided drill a hole so I could get to on-off switch, this did nothing so had to crack open.
Whilst unit was still dry inside, the esp32 was not responding at all.
Possibly another fault as this was the one that had the doa sd card in it.
whilst disappointing, I was happy it wasn't water related and can build another one the same way (for now).
I tested the connection with a multimeter and everything is good.
This line in the log seems very interesting:
Serial2 9600bd Rxd is on pin: 3
?O???V?g?CBJKBJH??C?ac?C??cBKCb)g??
The weird characters make me think that there is an attempt at comms, but something is off.
I've just noticed that the GPS I'm using is a BN220ZF. Which seems to be different from a BN220 in some way. Perhaps a different comm method?
The bn220zf has another gps chip (atxxx), this is the problem. You need a ublox M8 chip (m8030). These AT chips do not speak ubx. Very strange that they react on the gps rate setting, as this is sended in ubx format. Beitains which are tested and have the M8030 chip : Beitian BN180, BN220, BN280. Watch out for the unbranded BN220, they seem to have the correct chip, but the performance is not so good as the Beitian branded.
Recent, we tested a new brand with a ublox M10 chip. First results are promising, but they need another bin file, as the ubx M10 configuration is completely different from the ublox M8 configuration. These bin files are on github.
M10 : nl.aliexpress.com/item/1005004745320234.html?spm=a2g0o.order_list.order_list_main.34.21ef79d22uRgCQ&gatewayAdapt=glo2nld
M8 : nl.aliexpress.com/item/1005004405692761.html?spm=a2g0o.productlist.main.115.495052f04cdZBv&algo_pvid=b5dc53c3-0f22-44e0-89b5-dbfb179e22e3&algo_exp_id=b5dc53c3-0f22-44e0-89b5-dbfb179e22e3-57&pdp_ext_f=%7B%22sku_id%22%3A%2212000029066488485%22%7D&pdp_npi=2%40dis%21EUR%2113.64%2111.59%21%21%21%21%21%40211be59e16753425775728548d070e%2112000029066488485%21sea&curPageLogUid=Bvl5CC9OUupz
tried the new firmware yesterday,and love it, the last run speed is very helpful and battery percentage is a big improvement.
Sailquik, if you google something like "B6 Li balance charger" you will see that there are dozens of manufacturers out there that supply millions of B6-design chargers to the universe of RC enthusiasts. They all use the same basic firmware and algorithms to calculate percentage based on voltage. They use this for balancing the multi-cell batteries as well as conditioning the batteries for the best voltage for storage. Most work with LiPo, Li-ion, and LiFePO4 batteries. Some even include NiCd, NiMH, and Pb. I have three of them from different manufacturers. I use them for model boats and drones.
For LiPo the voltages run from 3.0V per cell at fully discharged to 4.2V per cell at 100% charged. 3.85V per cell for storage. Analogous numbers for Li-ion and LiFePO4. Those slopes are steep enough to make good calculations of percentage and control. With these chargers you can charge, fast-charge, discharge, balance cells, and charge to storage. You have full menu-programmable control over current, voltage, and times.
The RC hobby would not exist without these smart chargers. It all started 40 years ago when all we had were NiCd batteries.
Thanks Seglar. That is excellent knowledge. Great to know. ![]()
Hi All
Been building away now for a few days and have a few ideas that may or may not have been discovered before.
I have found you can slide a knife behind the e-paper and carefully lift it off. Handy for soldering as it gets it out the way but more importantly (for my OCD) you can centre it when putting it back on using double sided tape. This way when in the smallest case possible (70mm wide) the screen will be centred. Need a new centred cover piece @Flex for your boom mount......
Also rather than using the microSD card slot that sticks out the top it is possible to use the SPI pins to connect a miniSD adapter that holds the microSD. Can probably go direct to a microSD but I just wanted to try it and had the microSD adapter handy. Have tested and seems to work fine.
Doing these two things means you can get everything into a ~70mm x ~40mm x Xmm enclosure.
PS. Got an alpha PB today testing my unit around a round about in the car :) Cant wait to use it on the water.
E-paper usable screen now centred on the 70mm width.

mircoSD adapter wired dirctly to SPI.

Nice one Alhop. Very early on in this thread someone removed the SD card holder and directly soldered the micro SD card behind the board for low profile version. Seems that idea and your centred screen idea will make for a pretty slick looking unit. I tried removing one of my dead units screen like you said and managed to crack the display (to be fair the old solder was in the way which was probably the cause). Really need to take care if doing this. I don't think you need double sided tape as the goo seems to hold the display in place well enough (assuming you are going to epoxy the unit). The tape will also make for a very tight fit in the case. Based on your request I modified my print to include a centre trim version for those that are game. I also started a public collection of various prints which Jan may want to include on his wiki link so people can look at the various options of 3D prints. If there are any other variations of prints out there that people want to share (or I've missed) then please repost on this thread an I'll add to collection. www.printables.com/social/32187-flex/collections/474942?o=newest
Got one broken screen myself flex - should have mentioned that !. A sharp knife slowing sliding under seems to be the go and don't try and lift. Just let the knife slide in to cut the goo,
Got a few proto mounts being printed so will put them forward once tried and tested,
Have been working this weekend together with Bart to get the new smaller housing designed and printed. This one should be poored with epoxy. It becomes a lot smaller, also helped by the M10 in combination with the 802540 lipo (1200mah). But it is a really tight fit. Everything is inside including the wireless charger. Needed to cut off the switches to make it fit. Strap is mounted.
Now it's time for some dry runs and see how long it takes to drain the tiny battery.
Now I have to order some UV resistant, very clear slow hardening pooring epoxy.



