Cruisers & Sailing Forums (http://www.cruisersforum.com/forums/)
-   OpenCPN (http://www.cruisersforum.com/forums/f134/)
-   -   New rtlsdr Plugin (http://www.cruisersforum.com/forums/f134/new-rtlsdr-plugin-102929.html)

boat_alexandra 01-05-2013 02:36

New rtlsdr Plugin
 
I went ahead and wrote a simple plugin for opencpn to handle ais from the dongle:

https://github.com/seandepagnier/rtlsdr_pi

Probably only works in linux, but with feedback and testing it can be adapted for all platforms.

This plugin is not required for ais of course, but it simplifies things so you automatically get ais when you launch opencpn without having to run other stuff (it does that)

Also planned are support for playing/scanning audio vhf channels and eventually receiving both satellite weather and hf weather fax images. Could also play/record nets (given a schedule database) Also, I plan on supporting integrated user calibration and possible autocalibration, as well as modes to reduce cpu usage (sdr is hard on my netbook) Once that is implemented, the need for the plugin will be more obvious.

I made this thread to discuss the plugin to avoid confusion, so it only for issues related to the plugin.

Alisdair 01-05-2013 03:33

Re: new rtlsdr plugin
 
I'm looking forward to this - I've been banging my head off a wall trying to get AIS to work with SDR on my Raspberry Pi.

What is the 'other stuff' that the plugin runs? ... I can manage ADS-B (AIS for aircraft) and broadcast FM, so the driver's OK, but I haven't found a solution for AIS.

Does anyone have any (inexpensive) suggestions for an upconverter to bring the HF frequencies into the dongle's range for wefax?

kubek 01-05-2013 04:01

Re: new rtlsdr plugin
 
Great news....

Could you tell me, do you have any preferences about hardware (chipset, vendor, etc...) to get best quality of signal if you know that. Should I have two dongles to monitor both AIS channels at the same time? I mainly use window$ staff, but I see that I should try linux one.

Kubek

boat_alexandra 01-05-2013 04:02

Re: new rtlsdr plugin
 
Quote:

Originally Posted by Alisdair (Post 1224437)
I'm looking forward to this - I've been banging my head off a wall trying to get AIS to work with SDR on my Raspberry Pi.

Does gr-ais not work? The raspberry pi will have very limited cpu so a lower sample rate (default is 256khz) may be needed to avoid overflows.
Quote:

What is the 'other stuff' that the plugin runs? ... I can manage ADS-B (AIS for aircraft) and broadcast FM, so the driver's OK, but I haven't found a solution for AIS.
Then you can maybe dodge airplanes that might be crashing into the sea.. although at 6knots its hard enough to dodge tankers only going 15.. It would be fun to do anyway, but requires additional rendering support as well.
Quote:

Does anyone have any (inexpensive) suggestions for an upconverter to bring the HF frequencies into the dongle's range for wefax?
Well there is the $50 one I'm sure you have seen, but considering it costs more than 6x the dongle, it is not inexpensive. You could build your own for under $10 in parts but it requires a lot of work. The other option is to do the hardware mod (bypass demodulator converter by soldering a jumper wire) to the pin and you can get 0-14mhz (or 14-28 but not very well I think) I believe in this mode you get all the data.. so you can get weather fax _and_ listen to a cruising net _and_ record any other frequency all at the same time.

Anyway most hf weather fax are under 14mhz so this should work. Then the dongle would not work for ais anymore without either a switch, or a second dongle. I have yet to try this.

Alisdair 01-05-2013 04:13

Re: new rtlsdr plugin
 
Quote:

Originally Posted by boat_alexandra (Post 1224448)
Does gr-ais not work?

No; build problems and work in progress .. but if your plugin assumes gr-ais I'll persevere, thanks.

Quote:

Originally Posted by boat_alexandra (Post 1224448)
Then you can maybe dodge airplanes that might be crashing into the sea.. although at 6knots its hard enough to dodge tankers only going 15.. It would be fun to do anyway, but requires additional rendering support as well.

As I live 100 miles from the boat, but have two international airports nearby, it was easier to verify rtlsdr using ADB .. I DO NOT want to overlay it on OpenCPN , it would only confirm how sedate my progress was :)

Alisdair 01-05-2013 04:37

Re: new rtlsdr plugin
 
Quote:

Originally Posted by kubek (Post 1224447)
Great news....

Could you tell me, do you have any preferences about hardware (chipset, vendor, etc...) to get best quality of signal if you know that. Should I have two dongles to monitor both AIS channels at the same time? I mainly use window$ staff, but I see that I should try linux one.

Kubek

One dongle will cover both AIS frequencies; just extend the bandwidth.

boat_alexandra 01-05-2013 04:42

Re: new rtlsdr plugin
 
You only need two dongles if you want to monitor frequencies more than 2.2mhz apart at the same time. AIS A and B are 50khz apart.. so you can get 10 other vhf channels as well.

Eventually I will have support for scanning and stuff.. so you can get ads-b and ais at the same time, but miss packets on each, but initially no. Also I am not planning to support multiple dongles for a while.. that could change if it is requested often.

boat_alexandra 01-05-2013 06:36

Re: New rtlsdr Plugin
 
Quote:

Originally Posted by Alisdair (Post 1224456)
No; build problems and work in progress .. but if your plugin assumes gr-ais I'll persevere, thanks.

For now gr-ais, but it uses a lot of cpu. Too much for raspberry pi. We need rtl_ais, maybe you can also pipe rtl_fm into gnuais to use less cpu.

boat_alexandra 01-05-2013 16:36

Re: New rtlsdr Plugin
 
I have enhanced to support ADSB fm radio and vhf audio channels.

ADSB is only raw now, doesn't plot. I don't have reliable enough data to work with since dump1090 never outputs anything.

cagney 14-05-2013 14:18

Re: New rtlsdr Plugin
 
I had an "EZCAP EzTV-668 with RTL2832U FC0013 SDR DVB-T Digital TV USB 2.0 Dongle!", arriving from Hong Kong today, with a bit of help from Ebay. Price $ 23!
So I started working through larsed's instruction for gr-ais on Suse.
I'm on Kubuntu so I had to adopt. A lot of the dependencies are available as packages. I only had to compile the git-hub downloads. No real problems. I only had to go back a few times to adjust, as I had skipped a few recommended settings along the way .
I was short on time when I reached the frequency correction instructions, so I took a chance and tested the rtlsdr plugin.
Encouraged by a clear FM reception on known frequencies, I took a punt and tried AIS.... and it just worked, with default settings. :thumb:
Just a bit of luck, I suppose....
I really had expected more fiddling!

Thomas

boat_alexandra 14-05-2013 16:45

Re: New rtlsdr Plugin
 
Yeah, well only the error term needs to be set right, and if you try values like -60, 30, 0, 30, 60, I believe it will work 95% of the time. For my dongle 30 or 60 works but not 0 (default)

Anyway, great to hear it works easily. The plugin is something like a manager, to automatically run and stop gr-ais when opencpn is opened or closes.

rgleason 19-05-2013 21:15

Re: New rtlsdr Plugin
 
Current rtlsdr.dll can be found at this post.
Plugin Threads (List)

boat_alexandra 20-05-2013 00:17

Re: New rtlsdr Plugin
 
Can this even work on windows? Please report results. So far I think its safe to say this plugin is linux only

rgleason 20-05-2013 05:01

Re: New rtlsdr Plugin
 
1 Attachment(s)
The software plugin does run in windows Opencpn 3.2 , I do not know if it works properly as I have not ordered a dongle yet. Why specifically, boat_alexandra do you think your plugin is linux only?

rgleason 20-05-2013 07:46

Re: New rtlsdr Plugin
 
Found these lines in opencpn.log

Quote:

9:43:34 AM: C:\Program Files (x86)\OpenCPN\plugins/rtlsdr_win32_pi18_v08_pi.dll Version detected: 108
9:43:34 AM: Error: Execution of command 'ais_rx.py -d -r 256000 -e 50 ' failed (error 2: the system cannot find the file specified.)


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

Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2018, vBulletin Solutions, Inc.


ShowCase vBulletin Plugins by Drive Thru Online, Inc.