Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Rate Thread Display Modes
Old 02-04-2012, 16:26   #61
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 4,877
Re: OpenCPN Fails to Receive Bluetooth Data Feed

mariette99....

You should not need gpsd for Bluetooth input on /dev/rfcomm0.

Please try without gpsd, and manually type in /dev/rfcomm0 in the toolbox->gps edit field.

Please attach the relevent logfile output for our analysis.

Thanks
Dave
__________________

__________________
bdbcat is offline   Reply With Quote
Old 03-04-2012, 02:41   #62
Registered User

Join Date: Oct 2010
Location: Southern Sweden
Posts: 21
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Well I don't have a Windows machine. I have used Linux since time begune.
And it has worked perfectly but my old machine gave up on mer and I don't remember how I did the install last time.

It should be quite straight forward. Get a signal in NMEA format running on /dev/rfcomm0 and either pich it up directly in OpenCpn or link the sentences to another port which is communicating better with the system.

I have the NMEA sentences runnim and I can see then in cat /dev/rfcomm0
but no way I can pick them up i OpenCpn.

So I know how to run OpenCPN under Windows but I refuse to fiddle with installing win under VirtualBox or such like.
__________________

__________________
mariette99 is offline   Reply With Quote
Old 03-04-2012, 13:35   #63
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 4,877
Re: OpenCPN Fails to Receive Bluetooth Data Feed

mariette99....

Lets see your logfile for setup with /dev/rfcomm0....

Thanks
Dave
__________________
bdbcat is offline   Reply With Quote
Old 03-04-2012, 14:18   #64
mrm
Registered User

Join Date: Feb 2011
Location: Poland, EU
Boat: crew on Bavaria 38 Cruiser
Posts: 651
Re: OpenCPN Fails to Receive Bluetooth Data Feed

I confirm /dev/rfcomm0 as working with the current Beta.

Mariette99, verify the following:
Code:
$ rfcomm show /dev/rfcomm0
rfcomm0: xx:xx:xx:xx:xx:xx channel x closed

$ opencpn &

$ rfcomm show /dev/rfcomm0
rfcomm0: xx:xx:xx:xx:xx:xx channel x connected [tty-attached]
You may also need to set up a file /etc/bluetooth/rfcomm.conf and IIRC I also had to add 'rfcomm bind all' and 'rfcomm release all' to /etc/init.d/bluetooth start and stop entries respectively.
__________________
mrm is offline   Reply With Quote
Old 04-04-2012, 11:27   #65
Registered User

Join Date: Oct 2010
Location: Southern Sweden
Posts: 21
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Dave
How do I get the logfile for setup with /dev/rfcomm0...??

MRM
Verifying:
[root@svarten sarah]# hcitool scan
Scanning ...
00:1B:C1:05:F3:F8 HOLUX_M-1200E
30:17:C8:AD:BA:AA J10i2
[root@svarten sarah]#

[root@svarten sarah]# rfcomm bind /dev/rfcomm0 00:1B:C1:05:F3:F8
[root@svarten sarah]# rfcomm show /dev/rfcomm0
rfcomm0: 00:1B:C1:05:F3:F8 channel 1 clean
[root@svarten sarah]# rfcomm show /dev/rfcomm0
rfcomm0: 00:1B:C1:05:F3:F8 channel 1 clean

[root@svarten sarah]# starting OpenCPN from meny

[root@svarten sarah]# rfcomm show /dev/rfcomm0
rfcomm0: 00:1B:C1:05:F3:F8 channel 1 clean

[root@svarten sarah]# cat /dev/rfcomm0
$GPGGA,165433.000,5555.6609,N,01256.8033,E,1,6,1.1 3,81.5,M,40.4,M,,*62
$GPRMC,165433.000,A,5555.6609,N,01256.8033,E,0.30, 15.13,040412,,,A*5F
$GPVTG,15.13,T,,M,0.30,N,0.56,K,A*0B
$GPGGA,165434.000,5555.6610,N,01256.8033,E,1,6,1.1 3,81.5,M,40.4,M,,*6D
$GPGSA,A,3,28,26,17,12,11,22,,,,,,,3.28,1.13,3.08* 08
$GPGSV,3,1,12,27,83,277,,15,59,210,,09,58,281,,17, 41,095,34*78
$GPGSV,3,2,12,28,34,060,17,26,26,158,27,39,25,165, ,18,24,274,*7E
$GPGSV,3,3,12,12,23,225,18,22,18,318,21,01,09,037, ,11,06,020,22*7C
$GPRMC,165434.000,A,5555.6610,N,01256.8033,E,0.39, 15.13,040412,,,A*59
$GPVTG,15.13,T,,M,0.39,N,0.73,K,A*05
^C

---------------------------------------------------------------------------------------------
Has this given you any ideas?
__________________
mariette99 is offline   Reply With Quote
Old 04-04-2012, 13:18   #66
mrm
Registered User

Join Date: Feb 2011
Location: Poland, EU
Boat: crew on Bavaria 38 Cruiser
Posts: 651
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Quote:
Originally Posted by mariette99 View Post
MRM
Verifying:
[...]
Has this given you any ideas?
Nope, that is, unless you have a typo in a device name entered in opencpn? Maybe big letter 'O' instead of digit '0'? maybe a space somewhere? Obviously opencpn does not open /dev/rfcomm0, but surely it is trying to open something? What is in your config file? Anything relevant in the log?
__________________
mrm is offline   Reply With Quote
Old 04-04-2012, 13:50   #67
Registered User

Join Date: Dec 2005
Location: WNA
Boat: Dufour 35
Posts: 3,247
Re: OpenCPN Fails to Receive Bluetooth Data Feed

mariette99

Dave wants to see your OpenCPN logfile "opencpn.log" located in your home directory. Make sure to include a session where you try to connect your Bluetooth GPS.

Thomas
__________________
cagney is offline   Reply With Quote
Old 04-04-2012, 14:02   #68
Registered User

Join Date: Oct 2010
Location: Southern Sweden
Posts: 21
Re: OpenCPN Fails to Receive Bluetooth Data Feed

First my configfile and then the log file

# RFCOMM configuration file.
#
# $Id: rfcomm.conf,v 1.1 2002/10/07 05:58:18 maxk Exp $
#

rfcomm0 {
# Automatically bind the device at startup
bind yes;

# Bluetooth address of the device
device 00:1B:C1:05:F3:F8;

# RFCOMM channel for the connection
channel 1;

# Description of the connection
comment "Your GPS Device Here";
}
-------------------------------
21:55:43 CEST: 2012-04-04
21:55:43 CEST: -------Starting opencpn-------
21:55:43 CEST: Version 2.5.0 Build 2011-07-26
21:55:43 CEST: MemoryStatus: mem_total: 1499 mb, mem_initial: 32 mb
21:55:43 CEST: SData_Locn is /usr/share/opencpn/
21:55:43 CEST: Using existing Config_File: /home/sarah/.opencpn/opencpn.conf
21:55:44 CEST: Setting Viewpoint Lat/Lon 55.9479, 12.704
21:55:44 CEST: Setting Ownship Lat/Lon 55.9479, 12.704
21:55:44 CEST: System default Language: sv_SE
21:55:44 CEST: Opencpn language set to: en_US
21:55:44 CEST: Using s57data in /usr/share/opencpn/s57data
21:55:44 CEST: Using Tide/Current data from: /usr/share/opencpn/tcdata/
21:55:44 CEST: Setting Viewpoint Lat/Lon 55.9479, 12.704
21:55:44 CEST: Setting Ownship Lat/Lon 55.9479, 12.704
21:55:44 CEST: NMEA Data Source is....Serial:/dev/ttyUSB0
21:55:44 CEST: AIS Data Source is....Serial:/dev/ttyS0
21:55:44 CEST: AIS input device open failed: /dev/ttyS0
21:55:44 CEST: Using WVSChart datafile: /usr/share/opencpn/wvsdata/wvs43.dat
21:55:44 CEST: NMEA AutoPilot Port is....None
21:55:44 CEST: PlugInManager searching for PlugIns in location /usr/lib/opencpn
21:55:44 CEST: PlugInManager: Loading PlugIn: /usr/lib/opencpn/libdashboard_pi.so
21:55:44 CEST: PlugInManager: Loading PlugIn: /usr/lib/opencpn/libgrib_pi.so
21:55:44 CEST: ChartDB Cache policy: Max open chart limit is 20.
21:55:44 CEST: Loading chart db version: V016
21:55:44 CEST: Chartdb: Chart directory list follows
21:55:44 CEST: Chart directory #0: /home/sarah/charts
21:55:44 CEST: GPS Watchdog Timeout is: 6 sec.
21:55:44 CEST: Initializing Chart /home/sarah/charts/922 Íresund norra delen (1999).kap
21:55:45 CEST: NMEA input device open failed: /dev/ttyUSB0
21:56:37 CEST: NMEA Data Source is....Serial:/dev/rfcomm0
21:56:38 CEST: NMEA input device open failed: /dev/rfcomm0
21:56:44 CEST: LOGBOOK: 2012-04-04 19:56:44 UTC DR Lat 55.94790 Lon 12.70400
-------------------------------------------------------
__________________
mariette99 is offline   Reply With Quote
Old 04-04-2012, 14:12   #69
Registered User

Join Date: Dec 2005
Location: WNA
Boat: Dufour 35
Posts: 3,247
Re: OpenCPN Fails to Receive Bluetooth Data Feed

mariette99
Your
Quote:
NMEA Data Source is....Serial:/dev/ttyUSB0
in the published session.

Dave needs a log excerpt from when you are trying to connect your Bluetooth GPS and the NMEA data source is "/dev/rfcomm0".
Make sure gpsd isn't running.

Thomas
__________________
cagney is offline   Reply With Quote
Old 04-04-2012, 14:20   #70
mrm
Registered User

Join Date: Feb 2011
Location: Poland, EU
Boat: crew on Bavaria 38 Cruiser
Posts: 651
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Quote:
Originally Posted by mariette99 View Post
21:55:44 CEST: NMEA Data Source is....Serial:/dev/ttyUSB0
21:55:44 CEST: AIS Data Source is....Serial:/dev/ttyS0
21:55:44 CEST: AIS input device open failed: /dev/ttyS0
21:55:45 CEST: NMEA input device open failed: /dev/ttyUSB0
21:56:37 CEST: NMEA Data Source is....Serial:/dev/rfcomm0
21:56:38 CEST: NMEA input device open failed: /dev/rfcomm0
hmm?

I have only one line re NMEA Data Source in my log file. And no 'open failed' messages.

In ~/.opencpn/opencpn.conf I have:

Code:
...
[Settings/NMEADataSource]
Source=Serial:/dev/rfcomm0
BaudRate=4800
...
__________________
mrm is offline   Reply With Quote
Old 04-04-2012, 14:57   #71
Registered User

Join Date: Dec 2005
Location: WNA
Boat: Dufour 35
Posts: 3,247
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Hmmm...
I missed that second NMEA line. Thanks mrm.
mariette99 - did you have two instances of OpenCPN running at the same time?
Thomas
__________________
cagney is offline   Reply With Quote
Old 05-04-2012, 15:18   #72
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 4,877
Re: OpenCPN Fails to Receive Bluetooth Data Feed

mariette99...

Check the permissions on /dev/rfcomm0

It may be in an unexpected group.
As a quick check,

$sudo chmod 0777 /dev/rfcomm0

and then try OpenCPN. If it works, you will need to modify the script that creates /dev/rfcomm0 on device activation.

Dave
__________________
bdbcat is offline   Reply With Quote
Old 06-04-2012, 13:08   #73
Registered User

Join Date: Oct 2010
Location: Southern Sweden
Posts: 21
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Thanks guys

Yes I had two instances of gpsd running. Yes permissions belonged to unexpected group ("dailout").
And now everything is working! Thanks a lot all of you who have helped.

So a summary:

Run
hcitool scan to get the ID of your bluetooth gps device


Make a file "rfcomm.config" and put it in /etc/bluetooth.
# RFCOMM configuration file.
#
# $Id: rfcomm.conf,v 1.1 2002/10/07 05:58:18 maxk Exp $
#

rfcomm0 {
# Automatically bind the device at startup
bind yes;

# Bluetooth address of the device
device XX:XX:XX:XX:XX:XX;

# RFCOMM channel for the connection
channel 1;

# Description of the connection
comment "Your GPS Device Here";
}

Change XX:XX:XX.... to your device ID

Open Opencpn and write /dev/rfcomm0 as GPS NMEA device. Note that you can add it yourself by writing directly into the roll down box.

Permissions for /dev/rfcomm0 are for group "dialout". Make sure you belong to that group.

Never start up "gpsd". It had to be turned off.

This has worked for me on Fedora 14 and 16.
__________________
mariette99 is offline   Reply With Quote
Old 14-04-2012, 08:56   #74
Registered User

Join Date: Oct 2010
Location: Southern Sweden
Posts: 21
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Forgot that you have to enter as root at startup:

rfcomm bind /dev/rfcomm0 00:1B:C1:05:F3:F8
__________________
mariette99 is offline   Reply With Quote
Old 14-04-2012, 09:06   #75
mrm
Registered User

Join Date: Feb 2011
Location: Poland, EU
Boat: crew on Bavaria 38 Cruiser
Posts: 651
Re: OpenCPN Fails to Receive Bluetooth Data Feed

Quote:
Originally Posted by mariette99 View Post
Forgot that you have to enter as root at startup:

rfcomm bind /dev/rfcomm0 00:1B:C1:05:F3:F8
either that, or modify /etc/init.d/bluetooth
Code:
[...]
case "$1" in
  start)
    if [ ! -f /sbin/udevadm.upgrade ]; then
      udevadm trigger --subsystem-match=bluetooth
    fi
    rfcomm bind all
    ;;
  stop)
    rfcomm release all
    pkill -TERM bluetoothd || true
    ;;
[...]
__________________

__________________
mrm is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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 - NMEA Data from TCP Input framen OpenCPN 11 12-10-2012 13:19
OpenCPN Fails to Start Samarang OpenCPN 22 30-04-2011 01:51
Data Upload from OpenCPN to Garmin GPS152 syyabyum Navigation 1 06-11-2010 14:03
OpenCPN Won't Listen to My GPS Data Ima Winner OpenCPN 5 09-09-2010 16:23
OpenCPN Data Very Small and Difficult to View - Help, Please Algarve OpenCPN 30 14-03-2010 13:20



Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -7. The time now is 12:07.


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

ShowCase vBulletin Plugins by Drive Thru Online, Inc.