Cruisers Forum
 


Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 03-10-2017, 17:33   #511
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

Stelian, Saw this

printf("Corrupt record in file %s on line %d.\n", mdfile, fileline);
I guess this would be the file error message.

Thanks
rgleason is offline   Reply With Quote
Old 03-10-2017, 18:04   #512
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,422
Re: Celestial Navigation Plugin Redux

Quote:
Originally Posted by stelian View Post
It wasn't easy, and I don't have a full explanation.

However, after starting to add traces, I quickly found out that adding one trace (or even just a function call), at specific places, made the program work.

It turned out that those specific places where between the ListItem creation and their display in the List.

This smelled like stack corruption.

When I modified the ListItem allocation (allocate it in the heap and no longer on the stack), it didn't crash anymore. I was on the right track.

I looked for some time in the wxWidgets source code, and I saw that when the listitems are converted into native Windows list items, the attributes (TEXT, DATA, etc) are treated in different ways. And maybe (I didn't push the analysis too far), at this point they reference some value on the stack which in no longer there.

Next, I was grepping for wxLIST_MASK in the other OpenCPN plugins and the comment in WeatherRouting_pi put me on the right track...

Note: When I compiled with wxWidgets 3.1, the bug didn't seem to be there. Or maybe it was, but more difficult to trigger...
This was never the fault of the plugin but in wxwidgets.

Perhaps wxwidgets should be fixed? Is it fixed in 3.1?
seandepagnier is offline   Reply With Quote
Old 03-10-2017, 18:08   #513
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

Investigating further, I arrived with a rather large difference of 9.6miles with 2 stars sights as compare with thee position calculated by hand. This could be not acceptable by many people.
Ship's position:- 12-26.6 S, 125-30.6 W
O plugin :- 12-27.2 S, 125-40.4 W
The stars used:- Fomalhaut and Altair
26 June 1958
What do you thing of that.

I shall investigated more tomorrow in case of errors.
bye
P_Dub is offline   Reply With Quote
Old 03-10-2017, 18:29   #514
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

I have written NAV to see if he can check the plugin too.
rgleason is offline   Reply With Quote
Old 03-10-2017, 22:19   #515
Registered User

Join Date: Jul 2010
Location: Hannover - Germany
Boat: Amel Sharki
Posts: 2,546
Re: Celestial Navigation Plugin Redux

Quote:
Originally Posted by boat_alexandra View Post
This was never the fault of the plugin but in wxwidgets.

Perhaps wxwidgets should be fixed? Is it fixed in 3.1?
It is well known that wxWidgets is extremely buggy. Therefore the lead developer has made several attemps to circumvent them. After many years he finally switched to a newer wxWidgets version when OCPN does not compile for macOS. But sadly not to the latest version.
That means using other wxWidgets functions not have been already used and tested in main OCPN sources is a high risk.

Gerhard
CarCode is offline   Reply With Quote
Old 03-10-2017, 23:55   #516
Registered User

Join Date: Mar 2017
Location: Brittany, France
Boat: First 18
Posts: 323
Re: Celestial Navigation Plugin Redux

Quote:
Originally Posted by rgleason View Post
Stelian, Saw this

printf("Corrupt record in file %s on line %d.\n", mdfile, fileline);
I guess this would be the file error message.

Thanks
Done, and pushed.
stelian is offline   Reply With Quote
Old 04-10-2017, 06:11   #517
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

Well, I apologised, I had forgotten the height of eye and the result are perfect.
The position calculated was by the book.
Lat 12˚26.8`S
Long 125˚30.8`W
So, the plugin work correctly in Windows and should in others.
Good job and thank you from a navigator retired.
P_Dub is offline   Reply With Quote
Old 04-10-2017, 08:19   #518
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

Thanks P_Dub. You can't retire yet!
rgleason is offline   Reply With Quote
Old 04-10-2017, 09:55   #519
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

I suppose I still have some to offer.
Bye.
P_Dub is offline   Reply With Quote
Old 04-10-2017, 10:07   #520
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

Quote:
Originally Posted by rgleason View Post
Thanks P_Dub. You can't retire yet!
I suppose I still have some to offer.
Bye.
P_Dub is offline   Reply With Quote
Old 04-10-2017, 12:51   #521
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

rgleason
After 4 more sights calculation (double sights) I can confirm the accuracy of the plugin, either in the Northern or Southern Hemisphere. Their maybe a difference of 0.1 mile but nothing to be concern about. So nobody should be unhappy of it. Although it would be nice to have a more elaborated interface, as one may want, but it is not difficult to use for experience men. all you need is a little practice with it.
Best Regards
P_Dub is offline   Reply With Quote
Old 05-10-2017, 21:05   #522
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

Thanks p_dub
rgleason is offline   Reply With Quote
Old 07-10-2017, 16:00   #523
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

Remembered some test sightings in the manual which might have been useful.
https://opencpn.org/wiki/dokuwiki/do...l_navigation&s[]=celestial#examples_of_test_data
rgleason is offline   Reply With Quote
Old 09-10-2017, 06:45   #524
Registered User

Join Date: Feb 2011
Posts: 1,116
Re: Celestial Navigation Plugin Redux

One thing I would suggest for the celestial navigation plugin, have a space on the interface for entering the DR position prior to entries. Otherwise you may have a result in the Northern hemisphere instead of the Southern and vice-versa. This is undesirable and definitely inappropriate.
Thank you.
P_Dub is offline   Reply With Quote
Old 09-10-2017, 15:57   #525
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,711
Images: 2
Re: Celestial Navigation Plugin Redux

P_Dub,
Stelian has made a new version 4 days ago and I am not getting it to work very well.

I've compiled and uploaded it to Opencpn Beta File thingie rguser rgpass
Find it under 4.8.0 Test Directory.

I was trying entering the Examples at the bottom of the Cel_Nav manual

Celestial Examples_of_test_data

I kept getting "Warning: Measurement certainly set too small, sight may not appear."

Also it bombed several times on me, rather than prompting "Values are wrong" or something. It should not bomb.

Perhaps I am doing something wrong?
rgleason is offline   Reply With Quote
Reply

Tags
celestial navigation, navigation


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Logbook Konni for OpenCPN konni OpenCPN 1128 15-05-2022 11:25
Google Earth Plugin r.fairman OpenCPN 445 29-04-2020 10:11
GRIB Weather Mark Ward OpenCPN 26 12-02-2012 21:33
Route Properties, Missing Functions James Baines OpenCPN 13 13-07-2011 04:31

Advertise Here


All times are GMT -7. The time now is 10:47.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.