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-01-2015, 20:02   #271
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Plugin: DashBoard

Hakan...
The depth history graph works just fine for me on Linux.

Pavel
nohal is online now   Reply With Quote
Old 04-01-2015, 02:19   #272
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Quote:
Originally Posted by nohal View Post
Hakan...
The depth history graph works just fine for me on Linux.

Pavel
Pavel....
OK, Thanks. So I've to find out:
> Possible difference between my Win and Linux dashboard sources. (Checked >> none)
> Why Linux "DashboardInstrument_Single" is working while "DashboardInstrument_Depth" is not. (Both are using "OCPN_DBP_STC_DPT") >> I can't, so far, find any reason.
> Or further advices from you?

Håkan
Hakan is offline   Reply With Quote
Old 04-01-2015, 06:30   #273
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Plugin: DashBoard

Hakan...
Set some breakpoints in the code and check what's happening.
Or post a VDR recording to reproduce the problem and I will do it. With the datafeeds I have available the problem does not exist.

Pavel
nohal is online now   Reply With Quote
Old 04-01-2015, 07:24   #274
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Pavel..
I do appreciate if you would like to test. I'm used to VC++ on Win and installed CB yesterday but haven't yet set it up for debug on my Linux.
I'm using this VDR: https://dl.dropboxusercontent.com/u/...st_VDR_rec.txt
But, since I've some dated Simrad IS15 the code has to be adjusted:
Code:
diff --git a/plugins/dashboard_pi/src/nmea0183/dpt.cpp b/plugins/dashboard_pi/src/nmea0183/dpt.cpp
index 380518d..8966f4b 100644
--- a/plugins/dashboard_pi/src/nmea0183/dpt.cpp
+++ b/plugins/dashboard_pi/src/nmea0183/dpt.cpp
@@ -86,8 +86,11 @@ bool DPT::Parse( const SENTENCE& sentence )
 
    if ( sentence.IsChecksumBad( 3 ) == TRUE )
    {
-      SetErrorMessage( _T("Invalid Checksum") );
+      if ( sentence.IsChecksumBad( 4 ) == TRUE ) //Simrad IS15 can send a 4th field!!!; "Range" Typical: 100.0 //Hakan
+      {
+       SetErrorMessage( _T("Invalid Checksum") );
       return( FALSE );
+      }
    } 
 
    DepthMeters                = sentence.Double( 1 );
You'll will also not get a HDT without changes since my navigator sends an unexpected variation value, 0.0, but that's not a problem for this test?
Hakan is offline   Reply With Quote
Old 04-01-2015, 07:45   #275
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Plugin: DashBoard

Hakan...
The stock dashboard we distribute shows the depth info (both value and graph) out of the box with this file for me.
I don't see any HDT sentences in it though.
Is your complete fork on github?

Pavel
Attached Thumbnails
Click image for larger version

Name:	Screenshot from 2015-01-04 09:44:25.png
Views:	136
Size:	195.5 KB
ID:	94889  
nohal is online now   Reply With Quote
Old 04-01-2015, 09:28   #276
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Pavel...
Thanks for your test.
My github is not up to date, sorry.

HDT, eh....typo; I should have said true HDM with the help of WMM. It's not working out of the box since my "var" is not Null but 0.0 and I can't tell my navigator to send anything but 0.0 instead of its outdated variation table. So I take care of that in my code instead.

I have now tested the master source, out of the box, and it's no difference, no depth graph in Ubuntu. Could it be any lacks in my Ubuntu 12.04?
In case you've Ubuntu I attach my _pi.so (Skip .pdf)

Håkan
Attached Files
File Type: pdf libdashboard_pi.so.pdf (478.4 KB, 56 views)
Hakan is offline   Reply With Quote
Old 04-01-2015, 10:28   #277
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Plugin: DashBoard

Hakan...
Your library is 32bit and can't work on my 64bit system.
When you are playing the file, do you see the DPT sentences fine in the NMEA debug window?

Pavel
nohal is online now   Reply With Quote
Old 04-01-2015, 12:26   #278
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Pavel..
Yes, of cource. I see it as well as windows depth graph and Linux depth and sea temperature instruments do. See my post http://www.cruisersforum.com/forums/...ml#post1711620 where the two dashboard panels shows the DPT value but no graph in Ubuntu.

Håkan
Hakan is offline   Reply With Quote
Old 04-01-2015, 12:33   #279
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Plugin: DashBoard

Hakan...
Well, I'm out of ideas. I can't see any reason why playing the same file with VDR should work exactly as expected for me and not for you. Just as a last try - backup your ~/.opencpn/opencpn.conf and try with a "clean table" to make sure there is no problem with your config.

Pavel
nohal is online now   Reply With Quote
Old 04-01-2015, 13:00   #280
Registered User

Join Date: Dec 2005
Location: Helsingborg
Boat: Dufour 35
Posts: 3,891
Re: Plugin: DashBoard

Quote:
Originally Posted by Hakan View Post
Pavel..
Yes, of cource. I see it as well as windows depth graph and Linux depth and sea temperature instruments do. See my post http://www.cruisersforum.com/forums/...ml#post1711620 where the two dashboard panels shows the DPT value but no graph in Ubuntu.

Håkan
Håkan

Testing your file on an Kubutu 14.04 64 bits.
Same result as Pavel, I get a depth graph.
Something with your system.....??

Thomas
cagney is offline   Reply With Quote
Old 04-01-2015, 14:44   #281
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Pavel..
I've tested with a "clean config and the result is the same.
Thomas.. Thanks for testing and system.....Yes that must be next step;

I've two machines where I run OpenCPN: Both Lenovo R61 where I've Win and Ubuntu 12.04 as dual boot. Both are equal with regards to the depth graph failure. It works fine in Win but not in Linux.
Ubuntu reports graphic card: unknown. Windows says: Mobile Intel(R) 965 Express

Then I've one very dated Tochiba with a bad NVidia graphical card where I only build the source and have never run OCPN on. Now, for a test I installed on that machine as well and there is the depth graph actually working!

Conclusions???
> The built was trying to adapt to NVidia and something make it not working on the Lenovo machines?? Shall I test to buld on a Lenovo instead?
> wxWidgets needs something more for Ubuntu on the Lenovo machines?? Clues?
> More ??

Any advices appreciated

Thanks
Håkan
Hakan is offline   Reply With Quote
Old 05-01-2015, 04:37   #282
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Quote:
Originally Posted by Hakan View Post
...........
> The built was trying to adapt to NVidia and something make it not working on the Lenovo machines?? Shall I test to buld on a Lenovo instead?
> wxWidgets needs something more for Ubuntu on the Lenovo machines?? Clues?
> More ??......Håkan
First possible(?) issue tested. >> I've build on a Lenovo instead...No success, The same result. Depth text instrument is functional but not the graph. There's still only two lines indicating where the instrument should have been visualized. No data, no label, no scale and no graph.

depth.cpp is drawing this instrument. I assume some graphic tools are not compatible with my hardware and Ubuntu?? (In Windows it's OK on the same machine) How would I trace this? (Ubuntu says "unknown" graphic card --- a trace?)

Håkan
Edit: After installing "mesa - utils" Ubuntu knows more:
Intel® 965GM x86/MMX/SSE2
Hakan is offline   Reply With Quote
Old 06-01-2015, 03:11   #283
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Pavel.. all...
I think I've found why the depth graph is not working!
The following did the thing:
Code:
In plugins/dashboard_pi/depth.cpp
@@ -110,7 +110,8 @@ void DashboardInstrument_Depth::DrawBackground(wxGCDC* dc)
       dc->DrawLine(3, 40, size.x-3, 40);
       dc->DrawLine(3, 140, size.x-3, 140);
 
-      pen.SetStyle(wxSHORT_DASH);
+      pen.SetStyle(wxDOT);
+      pen.SetWidth(1);
       dc->SetPen(pen);
I assume that for my system the combination Ubuntu 12.04 and Intel® 965GM x86/MMX/SSE2 can't handle the SetStyle(wx------_DASH). I've tested all available _DASH and none is working. Styles, without _DASH, are working.

Could it be connected to all OpenGL troubles with Intel graphics? (I've tested with and without OpenGL, no difference)

So now in my code I use a dotted line and decreased pen width instead.

Next step?
I see two possibilities:
Change to dots for all OR change to dots when Intel graphics card is involved and in Linux. (See my picture with dots.)
And:
> You change the core source now?
> I create a Flyspray request?
> I keep the change in my personal source only?
> Else?

Please comment and advice

Thanks
Håkan
Attached Thumbnails
Click image for larger version

Name:	Depth_dots.png
Views:	174
Size:	30.7 KB
ID:	95050  
Hakan is offline   Reply With Quote
Old 06-01-2015, 06:30   #284
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,401
Re: Plugin: DashBoard

Håkan...

Good catch.
If you look around the source, you will see all sorts of strange conditions regarding wxSHORT_DASH in the Dashboard. Wind history has the same trouble, I suspect. We don't use it under GL mode in the OCPN core. It's just broken.

So, I will make the change in the Dashboard source today, and it will be in O4.

Thanks again

Dave
bdbcat is online now   Reply With Quote
Old 06-01-2015, 12:16   #285
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,146
Re: Plugin: DashBoard

Dave..
Very good, thank you.
Håkan
Hakan is offline   Reply With Quote
Reply


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
OpenCPN PlugIn Development bdbcat OpenCPN 161 04-09-2019 12:50

Advertise Here


All times are GMT -7. The time now is 11:16.


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.