Rodemfr / MicronetToNMEA

A NMEA 0183 converter for Raymarine's wireless instruments ... and much more !
GNU General Public License v3.0
21 stars 8 forks source link

HDG info not sent to Micronet? #50

Closed frgaude closed 1 year ago

frgaude commented 1 year ago

Hi Rodem, there seems to be a regression with the lastest batch of commits: I used to get the heading info on my displays, it's no longer showing with current "master". the HDG info still shows in the NMEA feed.

same behavior with or without compass calibration.

GPS COG & SOG are displayed ok.

(not sure exactly which version I was using before: pre-databridge was working for sure but I think also after the first databridge commits)

NMEA.log

Tacktick displays
Rodemfr commented 1 year ago

I just made changes on this area in the latest commits, I will check it tonight. It should be easy to fix.

Rodemfr commented 1 year ago

Mag heading is working on my setup. When I look to the modifications I have done, I suspect a possible problem. First, I found a few problems but I made an error with my git and I pushed the fix directly in master... So you can test it directly in master branch. Secondly, If it does not work, you can also reset the heading offset and magnetic variation with your display or remote (in compass option page). Even if these two values are already set at zero, it is important to reset them again so that MicronetToNMEA can see them pass on the network and store it into EEPROM. Let me know the result.

dwarning commented 1 year ago

Only 1 cent from my side: Heading self is working with latest master, see the correct nmea sentences. But no display values. All calibration settings disappears and setted to 0. Also for different older version. Perhaps the EEPROM content/addresses changed.

frgaude commented 1 year ago

still no luck with the latest changes.

I'll revert to an older version to double check. I might be able to publish some micronet logs from a 2nd board (an esp32 with a cc1101 :-) )

And to clarify my situation with magnetic calibration: until this evening, it was set to 0 on the various elements I have at home (MTN board and the two displays are not yet in use on the boat).

I did a calibration after I experienced the issue. to be in a more "by-the-book" situation.

I'll also redo the calibration and check the parameters on the micronet display.

thanks for the great support!

frgaude commented 1 year ago

I went back to the merge of pull request #42 and ... the magnetic heading info is displayed.

one thing to note: in this version and versions prior to the rework on the RF driver, the calibration of my CC1101 board was really skewed to the low end of the spectrum:

.*******.............................................................................................. Frequency = 869701.94kHz Range = 17.94kHz Deviation to real frequency = -138.06kHz Do you want to save the new RF calibration values (y/n) ? Configuration saved

RF calibration is more "centered" with the latest code:

.......................************************....................................................... Frequency = 869793.19kHz Range = 68.79kHz Deviation to real frequency = -46.81kHz (-53 ppm) Do you want to save the new RF calibration values (y/n) ? Configuration saved

so maybe, somehow, my CC1101 is causing this...

frgaude commented 1 year ago

pinpointed to this commit (works before, stops working after):

MTN_commit_issue50

Using a teensy 3.5 + CC1101 + LSM303DLHC + GNSS M8N (+ Wifi bridge deactivated for these tests) with 4 Micronet devices (2 dual maxi display, 1 wind display, 1 remote) -> I will do one last test to shield 3 devices and keep only one

frgaude commented 1 year ago

still not working when only switching on the wind display (0x83037899). maybe the cause is the # of paired devices, as they are stored.

2022-11-15 00_58_12-COM4 - Tera Term VT

vs

2022-11-15 00_57_25-COM4 - Tera Term VT
dwarning commented 1 year ago

Code recover is not easy because @Rodemfr mixed code changes with commenting and formatting in same commits.

Similar setup: teensy 4.1 + CC1101 + LSM303DLHC + GNSS M8N (+ Wifi bridge not used) + 1x MN 100-2

Playback to commit 97819d was not sufficient to get headings on display. Can confirm that playback to commit 598f02 brings the hdg values back. Same as your results.

frgaude commented 1 year ago

found it :-) !

2022-11-15 06_41_44-Automatically handle multiple slaves · Rodemfr_MicronetToNMEA@b97ad09

I'm sincerly impressed by the work of Rodemfr, clean code, refactoring whenever he feels it's needed, deep diving into the intricacies of the radio datasheets to get everyting right, great documentation, etc...

So spotting the ittle copy paste errors here and there is the least I can do (and also the only thing I'm able to do :-) )

Rodemfr commented 1 year ago

Excellent work ! I will look at it calmly tonight and review a bit what I did...

Rodemfr commented 1 year ago

If you confirm me that it is now OK with this issue, I will close it.

frgaude commented 1 year ago

Yes working fine now!

On Tue, 15 Nov 2022, 20:46 Rodemfr @.***> wrote:

If you confirm me that it is now OK with this issue, I will close it.

— Reply to this email directly, view it on GitHub https://github.com/Rodemfr/MicronetToNMEA/issues/50#issuecomment-1315787093, or unsubscribe https://github.com/notifications/unsubscribe-auth/APUEFXYMMYVVZ62QN6G6TWTWIPSAXANCNFSM6AAAAAASACKYXE . You are receiving this because you authored the thread.Message ID: @.***>

Rodemfr commented 1 year ago

I went back to the merge of pull request #42 and ... the magnetic heading info is displayed.

one thing to note: in this version and versions prior to the rework on the RF driver, the calibration of my CC1101 board was really skewed to the low end of the spectrum:

.*******.............................................................................................. Frequency = 869701.94kHz Range = 17.94kHz Deviation to real frequency = -138.06kHz Do you want to save the new RF calibration values (y/n) ? Configuration saved

RF calibration is more "centered" with the latest code:

.......................************************....................................................... Frequency = 869793.19kHz Range = 68.79kHz Deviation to real frequency = -46.81kHz (-53 ppm) Do you want to save the new RF calibration values (y/n) ? Configuration saved

so maybe, somehow, my CC1101 is causing this...

This is normal, this is one of the issues fixed in the various pull requests. MicronetToNMEA was not setting the frequency correctly. The error was compensated by the frequency calibration but the rror in ppm was wrong. Now, your value of 53ppm is correct and really shows the error of your XTAL.