Forums > Windsurfing   Gps and Speed talk

Another DIY GPS logger approach

Reply
Created by rp6conrad > 9 months ago, 2 May 2021
rp6conrad
364 posts
20 Feb 2023 4:03PM
Thumbs Up

Finding out the GPS chip and baudrate is indeed straightforward, as the M8 and M10 respond to the "ubx MON_VER message" with the type of chip : HW Ublox=00080000 for the M8, and HW Ublox=000A0000 for the M10. I first start with 9600bd, wait for a respond, if not readable, I try with 38400 bd. This seems to work fine with the 3 different chips I can test (M8@9600bd, M10@9600bd, M10@38400bd).
Did not find a way to check for the type of e-paper.
Greetings, Jan.

Rolz
QLD, 169 posts
21 Feb 2023 12:31PM
Thumbs Up

Select to expand quote
segler said..
Wow. You all are figuring this out. I think you guys should all form a co-op, or a corp, and go into business making and selling these things. This is excellent R&D.


my 2c on this is only when turning off the device is as easy as turning on is it would have a future, at the moment it's still too hit and miss and needs multiple goes to turn the unit off.

rp6conrad
364 posts
23 Feb 2023 10:21PM
Thumbs Up

A new SW 5.73 update is on github : github.com/RP6conrad/ESP-GPS-Logger. Next changes :
Added auto detection ublox type M8 / M10 and 9600bd/38400 bd
When downloading files, no underscore is added to the filename (bugfix)
In config, timezone changed to dropdown menu choice. Partial timezones added(UTC+ 9:30h, UTC +10:30h).
Speed screen 5 -> distance always km/h, run -> bat symbol
The Beitian BE-180 arrived today. They have a M10 chip with 38400 bd. Current consumption 25 mA. Connector identical to the BN series. Seems to perform wel.


Another issue : The cheap ALI micro SD-cards from 16GB do not work properly in SPI-mode. On a PC / Phone / Camera, they seem to work well, but in the ESP-logger, they are total unreliable. So, stay with the well known brands as Sandisk / Kingston...

Greetings, Jan.

Rolz
QLD, 169 posts
24 Feb 2023 8:16AM
Thumbs Up

great work as always Jan!

Rolz
QLD, 169 posts
26 Feb 2023 5:12PM
Thumbs Up

Hello All,

Since I'm building a few for my GPSTC team I thought maybe an end user manual might be worthwhile...

If you could provide some suggestions/updates/critique to it I'd really appreciate it!

ESP32 GPS - User Manual v 0.1.docx
1drv.ms/w/s!AmQrWIeMRVVGisgpkWqKhfOC0m5Gzw?e=pdSrgC

rp6conrad
364 posts
26 Feb 2023 4:50PM
Thumbs Up

Select to expand quote
Rolz said..
Hello All,

Since I'm building a few for my GPSTC team I thought maybe an end user manual might be worthwhile...

If you could provide some suggestions/updates/critique to it I'd really appreciate it!

ESP32 GPS - User Manual v 0.1.docx
1drv.ms/w/s!AmQrWIeMRVVGisgpkWqKhfOC0m5Gzw?e=pdSrgC


Very usefull indeed ! More info on reed switch actuation : standexelectronics.com/wp-content/uploads/Reed-Switch-And-Magnet-Interaction.pdf
Yes, the orientation of the magnet is quite important when switching off !




decrepit
WA, 12767 posts
27 Feb 2023 5:58AM
Thumbs Up

So we should have the button magnets on their side to turn off??? Is that what that diagram is saying?

Rolz
QLD, 169 posts
27 Feb 2023 10:58AM
Thumbs Up

Select to expand quote
rp6conrad said..

Rolz said..
Hello All,

Since I'm building a few for my GPSTC team I thought maybe an end user manual might be worthwhile...

If you could provide some suggestions/updates/critique to it I'd really appreciate it!

ESP32 GPS - User Manual v 0.1.docx
1drv.ms/w/s!AmQrWIeMRVVGisgpkWqKhfOC0m5Gzw?e=pdSrgC



Very usefull indeed ! More info on reed switch actuation : standexelectronics.com/wp-content/uploads/Reed-Switch-And-Magnet-Interaction.pdf
Yes, the orientation of the magnet is quite important when switching off !





Hi Jan, thanks for the link!

I don't think the reed connection with the magnet is the issue.
I can wake the unit up, change to internal WiFi AP, change to different speed field screens with ease.

Prior to sealing the unit up I even tested distance of magnet to the installed reed switch via a multimeter continuity check and it beeps easily within 2cm of unit. don't even have to rest magnet on screen face to set it off.
Also explains why unit has turned on when my mobile was close to it on the passenger seat on the way to the beach one time

I can't see in the source code (but I'm not a coder), where it specifies a +2sec hold of the switch to turn the unit off?
The most success I seem to have is holding magnet on screen and counting to 4 and removing magnet.
This though still gives me I'd say 50% success rate at best.
Is it possible to increase time to 5secs? Or is code just set for if reed closed for over 2 secs and then opened means save&sleep device?

rp6conrad
364 posts
27 Feb 2023 5:01PM
Thumbs Up

Select to expand quote
Rolz said..
I can't see in the source code (but I'm not a coder), where it specifies a +2sec hold of the switch to turn the unit off?
The most success I seem to have is holding magnet on screen and counting to 4 and removing magnet.
This though still gives me I'd say 50% success rate at best.
Is it possible to increase time to 5secs? Or is code just set for if reed closed for over 2 secs and then opened means save&sleep device?




In the source code, it is located in the Rtos5.ino :
Button_push Long_push39 (WAKE_UP_GPIO,1500,10,8);//set voor 1500 ms
if(Long_push39.Button_pushed()) Shut_down();
So the reed switch has to be closed for at least 1500 ms, without any interruption ! But because there is no visible feedback, this is not fool-proof. Maybe we should add a LED for indication if the reed switch is actuated.



Select to expand quote
Decrepit said..
So we should have the button magnets on their side to turn off??? Is that what that diagram is saying?


Yes indeed, the button magnets have normal their N/S on the top and the bottom, so best to hold them on their side in the middle of the reed switch.

Greetings, Jan.

Rolz
QLD, 169 posts
27 Feb 2023 8:53PM
Thumbs Up

Select to expand quote
rp6conrad said..

Rolz said..
I can't see in the source code (but I'm not a coder), where it specifies a +2sec hold of the switch to turn the unit off?
The most success I seem to have is holding magnet on screen and counting to 4 and removing magnet.
This though still gives me I'd say 50% success rate at best.
Is it possible to increase time to 5secs? Or is code just set for if reed closed for over 2 secs and then opened means save&sleep device?





In the source code, it is located in the Rtos5.ino :
Button_push Long_push39 (WAKE_UP_GPIO,1500,10,8);//set voor 1500 ms
if(Long_push39.Button_pushed()) Shut_down();
So the reed switch has to be closed for at least 1500 ms, without any interruption ! But because there is no visible feedback, this is not fool-proof. Maybe we should add a LED for indication if the reed switch is actuated.




Decrepit said..
So we should have the button magnets on their side to turn off??? Is that what that diagram is saying?



Yes indeed, the button magnets have normal their N/S on the top and the bottom, so best to hold them on their side in the middle of the reed switch.

Greetings, Jan.


Oh I think LED indicator would be awesome!
I'm using Freezer's v1 arm design case, there is space to put in a hole in the top cover where I could flush mount an LED.
Totally happy to test this out!

Freezer
111 posts
27 Feb 2023 6:55PM
Thumbs Up

Select to expand quote
rp6conrad said..

Rolz said..
I can't see in the source code (but I'm not a coder), where it specifies a +2sec hold of the switch to turn the unit off?
The most success I seem to have is holding magnet on screen and counting to 4 and removing magnet.
This though still gives me I'd say 50% success rate at best.
Is it possible to increase time to 5secs? Or is code just set for if reed closed for over 2 secs and then opened means save&sleep device?





In the source code, it is located in the Rtos5.ino :
Button_push Long_push39 (WAKE_UP_GPIO,1500,10,8);//set voor 1500 ms
if(Long_push39.Button_pushed()) Shut_down();
So the reed switch has to be closed for at least 1500 ms, without any interruption ! But because there is no visible feedback, this is not fool-proof. Maybe we should add a LED for indication if the reed switch is actuated.




Decrepit said..
So we should have the button magnets on their side to turn off??? Is that what that diagram is saying?



Yes indeed, the button magnets have normal their N/S on the top and the bottom, so best to hold them on their side in the middle of the reed switch.

Greetings, Jan.


Hi Jan, could we create an icon that pops-up as soon as "button-pushed" is activated and is gone as soon as it stops? If it reaches 1500ms it will switch off... In this way there is feedback if the reed-switch is activated. A led is more complicated for the 3D printed housing, it better be on the e-paper screen.

rp6conrad
364 posts
27 Feb 2023 8:18PM
Thumbs Up

Problem is the slow response time (1000 ms) of the e-paper. A LED between gpio39 and 3.3 V should work (serial resistor, or LED with buildin resistor).

Rolz
QLD, 169 posts
28 Feb 2023 6:46PM
Thumbs Up

Hello brains trust!

I had a session today where my GPS seems to start way off where I should have started... can anyone see what maybe happened?1drv.ms/u/s!AmQrWIeMRVVGishz1a6reXwoCTWd1g?e=MTOCad

Also question, had someone use one of my GPS devices but it seemed there was a spike in the 2sec data, can anyone check that one out?1drv.ms/u/s!AmQrWIeMRVVGish2IuzvXUrTLSzKSA?e=22h3eQ

rp6conrad
364 posts
28 Feb 2023 9:58PM
Thumbs Up

When the log started, there were only 4 sats received, and the sACC was very high. This is exceptional, as the minimal nr of sats is 5 before the log should start. I can imagine that there were 5 sats visible for a short time, and then the reception get bad. These points will be filtered out due to low sats and high sACC. After 5 sec, 6 sats are received, and sACC is within limits. Then you have the jump to the correct position.
In the rest of the log, there are several spikes on the sACC, I guess boom mount and submersion from the logger.
In the Mickey log, there is one extreme spike of 33 knots, but this is in a region with very high sACC. Again, I guess a crash and submersion. This spike would be filtered out due the high sACC.

The analysis of this data is very easy with gps-speedreader : ecwindfest.org/GPS/GPSSpeedreader.html

Rolz
QLD, 169 posts
1 Mar 2023 9:01AM
Thumbs Up

Select to expand quote
rp6conrad said..
When the log started, there were only 4 sats received, and the sACC was very high. This is exceptional, as the minimal nr of sats is 5 before the log should start. I can imagine that there were 5 sats visible for a short time, and then the reception get bad. These points will be filtered out due to low sats and high sACC. After 5 sec, 6 sats are received, and sACC is within limits. Then you have the jump to the correct position.
In the rest of the log, there are several spikes on the sACC, I guess boom mount and submersion from the logger.
In the Mickey log, there is one extreme spike of 33 knots, but this is in a region with very high sACC. Again, I guess a crash and submersion. This spike would be filtered out due the high sACC.

The analysis of this data is very easy with gps-speedreader : ecwindfest.org/GPS/GPSSpeedreader.html


Thank you Jan! Another thing now I'm more knowledgeable about! :)

Just one additional question, when you say "These points will be filtered out due to low sats and high sACC"
Where is it filtered out?

I only picked up on my issue when I uploaded ubx file to ka72 site and it said my start location was no where near my normal spot and then opened on google earth to see the strange line.

For Mikey, it was picked up as the 2 sec on the gps screen that he'd done over 17knots 2sec on a wingfoil.

Should I now be using the gpy files instead?

shannon19
QLD, 104 posts
1 Mar 2023 9:22AM
Thumbs Up

I think jan is saying to run the data through gpsspeed reader first? I am not sure how to upload the filtered data to ka72 from there but you can trim files in speed reader. It will also only use data points with low errors and it will combine 2 tracks from 2 different units so using 2 units on either side of the boom works really well.

decrepit
WA, 12767 posts
1 Mar 2023 4:18PM
Thumbs Up

The filtering is done in the analytic software. It's much better to post from gpsspeadreader. It's just as easy as KA72, and the filters are more realistic. KA72's filters are a bit soft. And you have complete control of gpsspeadreader, it can give you all sorts of analysis of your sessions.

Rolz
QLD, 169 posts
1 Mar 2023 9:23PM
Thumbs Up

ah ok... yeah I'm pretty used to (and lazy) now to just upload my raw sessions to KA72 before sending to GPSTC... I use KA72 to compare to other local groups hence using that as a first data store before uploading to GPSTC. Also I like it so that if anyone has an issue with my track data they are freely able to download them and check them out.

Before my session today I made sure that I didn't move anywhere until I saw at least "S10" on the screen, and verified it all on gpsspeadreader before uploading to KA72.

I have reached out to Dylan about starting the process to formally accept gpy files onto KA72, but I noticed the timezone is still out compared to the ubx. Is this still being developed or on hold atm?

remery
WA, 3709 posts
1 Mar 2023 8:19PM
Thumbs Up

KA72 posts are available for all to see.

rp6conrad
364 posts
2 Mar 2023 4:15PM
Thumbs Up

Select to expand quote
Rolz said..
ah ok... yeah I'm pretty used to (and lazy) now to just upload my raw sessions to KA72 before sending to GPSTC... I use KA72 to compare to other local groups hence using that as a first data store before uploading to GPSTC. Also I like it so that if anyone has an issue with my track data they are freely able to download them and check them out.

Before my session today I made sure that I didn't move anywhere until I saw at least "S10" on the screen, and verified it all on gpsspeadreader before uploading to KA72.

I have reached out to Dylan about starting the process to formally accept gpy files onto KA72, but I noticed the timezone is still out compared to the ubx. Is this still being developed or on hold atm?


The time offset bug in the gpy format is fixed from SW 5.71 and higher. But also in GPS-speedreader, there was a issue with timezones for the gpy format. This is fixed with the latest update : version 2.1.4 from 25 feb 2023 (ecwindfest.org/GPS/GPSSpeedreader.html)
Can you check your SW version on the logger, and on GPS-Speedreader ?

Greetings, Jan.

Rolz
QLD, 169 posts
2 Mar 2023 7:10PM
Thumbs Up

Select to expand quote
rp6conrad said..

Rolz said..
ah ok... yeah I'm pretty used to (and lazy) now to just upload my raw sessions to KA72 before sending to GPSTC... I use KA72 to compare to other local groups hence using that as a first data store before uploading to GPSTC. Also I like it so that if anyone has an issue with my track data they are freely able to download them and check them out.

Before my session today I made sure that I didn't move anywhere until I saw at least "S10" on the screen, and verified it all on gpsspeadreader before uploading to KA72.

I have reached out to Dylan about starting the process to formally accept gpy files onto KA72, but I noticed the timezone is still out compared to the ubx. Is this still being developed or on hold atm?



The time offset bug in the gpy format is fixed from SW 5.71 and higher. But also in GPS-speedreader, there was a issue with timezones for the gpy format. This is fixed with the latest update : version 2.1.4 from 25 feb 2023 (ecwindfest.org/GPS/GPSSpeedreader.html)
Can you check your SW version on the logger, and on GPS-Speedreader ?

Greetings, Jan.


Thanks Jan! I can confirm after updating GPSSpeedreader all is good again!

Rolz
QLD, 169 posts
13 Mar 2023 2:16PM
Thumbs Up

Select to expand quote
Rolz said..

rp6conrad said..


Rolz said..
I can't see in the source code (but I'm not a coder), where it specifies a +2sec hold of the switch to turn the unit off?
The most success I seem to have is holding magnet on screen and counting to 4 and removing magnet.
This though still gives me I'd say 50% success rate at best.
Is it possible to increase time to 5secs? Or is code just set for if reed closed for over 2 secs and then opened means save&sleep device?






In the source code, it is located in the Rtos5.ino :
Button_push Long_push39 (WAKE_UP_GPIO,1500,10,8);//set voor 1500 ms
if(Long_push39.Button_pushed()) Shut_down();
So the reed switch has to be closed for at least 1500 ms, without any interruption ! But because there is no visible feedback, this is not fool-proof. Maybe we should add a LED for indication if the reed switch is actuated.





Decrepit said..
So we should have the button magnets on their side to turn off??? Is that what that diagram is saying?




Yes indeed, the button magnets have normal their N/S on the top and the bottom, so best to hold them on their side in the middle of the reed switch.

Greetings, Jan.



Oh I think LED indicator would be awesome!
I'm using Freezer's v1 arm design case, there is space to put in a hole in the top cover where I could flush mount an LED.
Totally happy to test this out!


Hi Jan, just going back to the LED for the reed switch activation, would it be just a matter of putting in a LED (with resistor in built) after the switch and before the ground connection?Would something like this suffice?www.digikey.com.au/en/products/detail/kingbright/WP710A10SURDK5V/16602157

Waiting for some more bits to arrive for my next build so thought I'd give it a go whilst building this one.

elmo
WA, 8868 posts
13 Mar 2023 12:57PM
Thumbs Up

Don't you get the LED's coming on with the antenna? not as bright as a stand alone LED butr still does the job.

rp6conrad
364 posts
13 Mar 2023 3:35PM
Thumbs Up

Select to expand quote
Rolz said
Hi Jan, just going back to the LED for the reed switch activation, would it be just a matter of putting in a LED (with resistor in built) after the switch and before the ground connection?Would something like this suffice?www.digikey.com.au/en/products/detail/kingbright/WP710A10SURDK5V/16602157
Waiting for some more bits to arrive for my next build so thought I'd give it a go whilst building this one.


No, this LED has a forward voltage of 5V (build in resistor I guess). What you want is a LED with a forward voltage of 3.3 V. A standard LED without resistor can be used, but you have to use a resistor (200 ohm +/-) in series.
The LED comes between GPIO39 and 3.3V. Normal state of GPIO39 = high (3.3V). If the reed switch is actuated, the state will be low (GND).
On the site of digikey, you have a search field Voltage - Forward (Vf) (Typ), there you can choose the 3.3V

Greetings, Jan.

Rolz
QLD, 169 posts
14 Mar 2023 11:09AM
Thumbs Up

Select to expand quote
elmo said..
Don't you get the LED's coming on with the antenna? not as bright as a stand alone LED butr still does the job.


my case is 3d printed and I can only just see the gps lights if I have the unit on in the dark... but this is more for if the reed switch has been activated, so I or other ppl can see that part.


Select to expand quote
rp6conrad said..

Rolz said
Hi Jan, just going back to the LED for the reed switch activation, would it be just a matter of putting in a LED (with resistor in built) after the switch and before the ground connection?Would something like this suffice?www.digikey.com.au/en/products/detail/kingbright/WP710A10SURDK5V/16602157
Waiting for some more bits to arrive for my next build so thought I'd give it a go whilst building this one.



No, this LED has a forward voltage of 5V (build in resistor I guess). What you want is a LED with a forward voltage of 3.3 V. A standard LED without resistor can be used, but you have to use a resistor (200 ohm +/-) in series.
The LED comes between GPIO39 and 3.3V. Normal state of GPIO39 = high (3.3V). If the reed switch is actuated, the state will be low (GND).
On the site of digikey, you have a search field Voltage - Forward (Vf) (Typ), there you can choose the 3.3V

Greetings, Jan.


cool, will give this a go :)

Windxtasy
WA, 4017 posts
22 Mar 2023 8:01PM
Thumbs Up

Select to expand quote
rp6conrad said..
A new SW 5.73 update is on github : github.com/RP6conrad/ESP-GPS-Logger. Next changes :
Added auto detection ublox type M8 / M10 and 9600bd/38400 bd
When downloading files, no underscore is added to the filename (bugfix)
In config, timezone changed to dropdown menu choice. Partial timezones added(UTC+ 9:30h, UTC +10:30h).
Speed screen 5 -> distance always km/h, run -> bat symbol
The Beitian BE-180 arrived today. They have a M10 chip with 38400 bd. Current consumption 25 mA. Connector identical to the BN series. Seems to perform wel.


Another issue : The cheap ALI micro SD-cards from 16GB do not work properly in SPI-mode. On a PC / Phone / Camera, they seem to work well, but in the ESP-logger, they are total unreliable. So, stay with the well known brands as Sandisk / Kingston...

Greetings, Jan.



I assume this means the new version of the software will work with either M8 or M10 chips?
No need to specify which one in the BIN file?

rp6conrad
364 posts
23 Mar 2023 3:28AM
Thumbs Up

Correct, the latest SW will check which Ublox is connected, so you only have to worry about the e-paper (BN / B37 / B74) that you are using. !
Greetings, Jan.

Windxtasy
WA, 4017 posts
24 Mar 2023 10:35PM
Thumbs Up

How do I copy the config file from github and get it onto the SD card?
I can copy the one from my computer that has my details on it, but I want the raw file without the modifications for someone else to use

also
can someone tell me what all the different formats are good for ? ubx etc?

rp6conrad
364 posts
25 Mar 2023 3:01AM
Thumbs Up

The easiest way to "clean" a config file is on the logger : On the configuration screen, delete your SSID and password, and save it. Then, when reboot, the logger will not connect to your SSID, but instead it will act as a "Acces Point" with the name "ESP32AP". Standard, this AP will only last for 10 s, but when you activate the reed switch, this time is prolonged with 100s.
Now you log in to this AP, password = password.
Now, when the connection is established, you can go to IP 192.168.4.1 (is on the screen), and download the "clean" config file. This config file will have al other setttings that were on your logger, except the SSID and password.
After downloading the config file, set your SSID and password back, and your done.
The file formats of the log files :
.txt = A readable text file with session information
.ubx = log file in Ublox format. The ubx nav pvt message is stored for every datapoint. Rather big files, but a lot of sites accept this format (GP3S, KA72....)
.sbp = A more condensed format, that is developed by Locosys (GT31 / GW60). Most sites accept this format.
.gpy = Extrem condensed format, but with all information in it. GPS Speedreader can read these files, and other sites are working on this.
.gpx = Not usable for uploading, as it only stores @ 1Hz, and some information is not in the data. Can be used for video overlay, Google Earth....

Greetings, Jan.

Windxtasy
WA, 4017 posts
25 Mar 2023 7:42AM
Thumbs Up

Thank you Jan, but what I need to know is how to download the config file from Github to the SD card.



Subscribe
Reply

Forums > Windsurfing   Gps and Speed talk


"Another DIY GPS logger approach" started by rp6conrad