Cruisers Forum
 


Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 16-07-2019, 03:36   #61
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI - sound problems OpenCPN v5

Dear all,

another attempt, hopefully this is the correct thread to add this problem to...

Currently I am experiencing severe problems with OpenCPN 5.0 on Raspberry pi. The problem is, there is no sound or only once and very distorted.

I am not sure, whether this is a Raspbian problem or an OpenCPN problem. It could well be, that this was introduced via some latest updates to the Raspberry OS (I try to keep my system fairly current)


Everything was working fine on OpenCPN 4.8.8 and some level of Raspbian back to February/March 2019. Here is the setup:

I have put all the .wav files I want to use into the "sounds" directory (/usr/share/opencpn/sounds)

In the "Options" Menu selecting "User Interface" - in the "old" (working) system I could select a Sound Device -1, 0, 1, 2 ...

Now in OpenCPN 5 I find an empty field next to the "Sound Device" label and clicking on the pull-down arrow I can no longer select a numerical value but find either :

bcm2835 ALSA:IEC958/HDMI (hw:0,1) or
dmix

neither of the selection works, except the first one (bcm2835 ...) when selecting in the "Ships" menu "AIS Targets" under the "CPA/TCPA Alerts", "Select Alert Sound" - "2bells.wav" and then "Test Alert Sound" you hear a very distorted "2bells" but only once - after having playd the sound, there is no further sound, you have to restart OpenCPN.

I copied my "old" "alsa.conf" file to the new system, no change.

All other programs (playing music via youtube of VLC etc.) work fine.

aplay -l states (sorry it's all German):

Karte 0: ALSA [bcm2835 ALSA], Gerät 0: bcm2835 ALSA [bcm2835 ALSA]
Sub-Geräte 7/7
Sub-Gerät #0: subdevice #0
Sub-Gerät #1: subdevice #1
Sub-Gerät #2: subdevice #2
Sub-Gerät #3: subdevice #3
Sub-Gerät #4: subdevice #4
Sub-Gerät #5: subdevice #5
Sub-Gerät #6: subdevice #6
Karte 0: ALSA [bcm2835 ALSA], Gerät 1: bcm2835 IEC958/HDMI [bcm2835 IEC958/HDMI]
Sub-Geräte 1/1
Sub-Gerät #0: subdevice #0

does this tell anybody something, is there any help possible, any clue?

Yes, I am a Raspberry-novice, however, I read the FAQs and tried to handle whatever was described there, but no success so far.

Any help would be most appreciated,

best regards,

Uwe
HUR450502 is offline   Reply With Quote
Old 16-07-2019, 03:50   #62
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

.... sorry, one more point: I used the "analog" output, however, switching to HDMI output rendered the same results.



Best regards, Uwe
HUR450502 is offline   Reply With Quote
Old 19-07-2019, 06:25   #63
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,414
Re: OS Raspberry specific RPI

try running pavucontrol during audio playback
seandepagnier is offline   Reply With Quote
Old 19-07-2019, 10:41   #64
Registered User
 
pinguino's Avatar

Join Date: May 2009
Location: SE Spain
Boat: Jeanneau SO 32I
Posts: 125
Re: OS Raspberry specific RPI

Since there were changes in the sound management in the last beta of opencpn this problem is dragged into the official build for Rpi.

You have to build opencpn with other parameters. Right now I don't remember them but you can try the build I made for myself. Perhaps they work for you.

Maybe one of these two can help you. They are for Raspbian stretch -xenial builds- if I'm not mistaken.

https://mega.nz/#!cdYTQYwT!UDX-QZeWI...VoZeROdCeMzwHk

https://mega.nz/#!JJwX3ISA!uzvZAVWXY...rccGYTZUwWUbP0

When i bought my new rpi 4 i had to build again opencpn for the same problem. The build i had of stretch didn't work and i had to build them for buster. The official -bionic- gave the same problem with the sound.
pinguino is offline   Reply With Quote
Old 19-07-2019, 22:53   #65
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

Dear Sean, as always, it just worked..... Thank you very much. I will have to experiment a bit, as the sound sometimes gets distorted, however, at least there is a sound now - and - I got it undistorted at times. So, this still may be a user problem now. Again, thanks a lot and



best regards,



Uwe
HUR450502 is offline   Reply With Quote
Old 19-07-2019, 22:56   #66
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

... short message to pinguino - thanks a lot for your info, I will have to dig into this. However, I read you are situated in SE Spain, where about? I am in Torrevieja, maybe we can meet some time? Just drop me a message, ok??

Many thanks,



Uwe
HUR450502 is offline   Reply With Quote
Old 21-07-2019, 02:52   #67
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI - Sound problems

Dear all,

first - again, let me thank you for your help, especially Sean, who directed me to using "pavucontrol".

Meantime I have tested this - as far, as I could. The result is - yes, there is now a sound, the selected sound(s) are played and they are clear and undistorted. So, the setup is a. start "pavucontrol", b. start OpenCPN.

However, I found out, that the playback of the sound(s) is VERY limited.

Let me explain - and please bear with me, I do not have any "real knowledge" about Raspberr pi and Raspbian, etc. - it looks to me, that OpenCPN "opens" the "sound output", sends the sound to the device but does not "close" the sound output after playback of the sound. Therefore at the next attempt of sending a sound to the device, another "sound output" channel is opened and the playback is done via that channel, etc.

This works exactly six times, then "pavucontrol" gives up accepting more input channels.

The attached screenshots should show how this looks like.

So, in my opinion, there is a bug in OpenCPN, handling sounds.


As the alert sounds - in my opinion - are essential: AIS of course, but also anchor-watch, pypilot alerts, etc. are necessary in my opinion and helpful. Therefore I think this needs to be addressed with some urgency, ok??

If I can be of any help here - of course - just please tell me, what I could/should do, o.k.??

Anyway many thanks for all the work and support you provied to the ww sailor community.

Best regards,

Uwe
Attached Thumbnails
Click image for larger version

Name:	2019-07-21-112739_504x929_scrot.png
Views:	104
Size:	37.6 KB
ID:	196319   Click image for larger version

Name:	2019-07-21-112941_1819x934_scrot.jpg
Views:	119
Size:	292.1 KB
ID:	196320  

Click image for larger version

Name:	2019-07-21-113012_1824x984_scrot.jpg
Views:	110
Size:	324.9 KB
ID:	196321   Click image for larger version

Name:	2019-07-21-113025_1824x984_scrot.jpg
Views:	111
Size:	335.6 KB
ID:	196322  

HUR450502 is offline   Reply With Quote
Old 21-07-2019, 05:39   #68
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

..... o.k., I have got to come back here.... A little further testing showed, that the effect described above seems ONLY to apply to the "Test Alarm" button for TCP/CPA AIS alarms. The "Watchdog Alarms" did not show this effect, not with a "real" alarm and also not with the "Test Alarm" button.

I have no chance currently to test, what happens, when a "real" TCP/CPA alarm goes off, or if this is solely the Test button.

If it is only the test button, I think there is no urgency to fix this, as everything gets reset when you close OpenCPN. ...

Best regards,



Uwe
HUR450502 is offline   Reply With Quote
Old 21-07-2019, 17:38   #69
Registered User
 
transmitterdan's Avatar

Join Date: Oct 2011
Boat: Valiant 42
Posts: 6,008
Re: OS Raspberry specific RPI

Quote:
Originally Posted by HUR450502 View Post
..... o.k., I have got to come back here.... A little further testing showed, that the effect described above seems ONLY to apply to the "Test Alarm" button for TCP/CPA AIS alarms. The "Watchdog Alarms" did not show this effect, not with a "real" alarm and also not with the "Test Alarm" button.

I have no chance currently to test, what happens, when a "real" TCP/CPA alarm goes off, or if this is solely the Test button.

If it is only the test button, I think there is no urgency to fix this, as everything gets reset when you close OpenCPN. ...

Best regards,



Uwe
Uwe,

This is a bug that only affects the test button. It is not an issue for other sounds played in the normal course of OpenCPN operation.
transmitterdan is offline   Reply With Quote
Old 22-07-2019, 02:02   #70
Registered User

Join Date: Jul 2019
Posts: 115
Re: OS Raspberry specific RPI

Hi,

I wanted to try opencpn on raspbian.
At the moment I installed a raspbian Stretch for PC host in a WIN10 virtualbox, it works fine. I installed it in 32 bits as for a raspberry.
When it comes to install opencpn, I followed the instruction in manual (OpenCPN instalation / Raspberry Pi 2/3/4) for stretch.
I have the following messages :
Code:
pi@raspberry:~ $ sudo apt install opencpn
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 opencpn : Depends: opencpn-tcdata but it is not installable
           Recommends: xcalib but it is not going to be installed
           Recommends: opencpn-doc but it is not going to be installed
           Recommends: opencpn-gshhs-intermediate but it is not going to be installed
           Recommends: opencpn-gshhs-high but it is not going to be installed
           Recommends: opencpn-gshhs-full but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Do you think it could be because raspbian for PC is not a "real" raspbian ? it is a 32 bits ?
It is based on Debian GNU/Linux 9.9 (stretch) ?
Any idea ?

Cheers.
J.
juancho38 is offline   Reply With Quote
Old 22-07-2019, 03:51   #71
bcn
Registered User

Join Date: May 2011
Location: underway whenever possible
Boat: Rangeboat 39
Posts: 4,706
Re: OS Raspberry specific RPI

And why don't you install OpenPlotter simply? You get a complete image, tested by several thousands of users.
bcn is offline   Reply With Quote
Old 22-07-2019, 04:09   #72
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

Quote:
Originally Posted by transmitterdan View Post
Uwe,

This is a bug that only affects the test button. It is not an issue for other sounds played in the normal course of OpenCPN operation.
Thanks a lot to everybody - in my opinion, we can close this issue here. However, I would recommend to add this info to the FAQ, and may be looking at what pinguino did to overcome this problem.

One other point I think is necessary to add: There will be numerous new users unsig Raspberry Pi 4 now that it has been released. I understand that they use another version of Raspbian - not xenial - maybe this will be added to the info sections in the manuals too?

I too contemplate to switch to Pi 4, assuming that there is a bit more processing power. When I have some intelligence as to system and problems etc. I will be ready to post it here, ok??

Again, many thanks to everybody helping me getting this resolved...

Best,

Uwe
HUR450502 is offline   Reply With Quote
Old 22-07-2019, 05:14   #73
Registered User
 
transmitterdan's Avatar

Join Date: Oct 2011
Boat: Valiant 42
Posts: 6,008
Re: OS Raspberry specific RPI

I don't think we should invest time and resources in the manuals about the test button. Very few users sit and bang on the test button. We should fix the bug in the code and then it won't be a problem any more.
transmitterdan is offline   Reply With Quote
Old 22-07-2019, 05:24   #74
Registered User

Join Date: Jul 2019
Posts: 115
Re: OS Raspberry specific RPI

Quote:
Originally Posted by bcn View Post
And why don't you install OpenPlotter simply? You get a complete image, tested by several thousands of users.
Because i don't have any raspberry board !
juancho38 is offline   Reply With Quote
Old 22-07-2019, 08:02   #75
Registered User

Join Date: Feb 2013
Location: Germany, Bavaria
Boat: Jeanneau Sun Fizz 40' or is it 39'?? :-)
Posts: 206
Re: OS Raspberry specific RPI

Quote:
Originally Posted by transmitterdan View Post
I don't think we should invest time and resources in the manuals about the test button. Very few users sit and bang on the test button. We should fix the bug in the code and then it won't be a problem any more.
I totally agree, my comment was directed at the general sound problems - at least I am having - which required the installation of "pavucontrol". Also "pinguino" mentioned, that he has other builds of OpenCPN who do not have the sound problems. Here, I think we should inform the users, that they may have some additional steps to do, to get to a proper sound.

In general I think, that Raspberry Pi is a very good platform and therefore would need some attention and support, probably more than Windows or Mac (I am running both systems) however: On the Pi I am using a HDMI monitor, the power requiremens of which are between 1 to 1.5 amps - in the config.txt I specified "hdmi_blanking=1", over night I switch off the mouse, so the Pi will "almost" go to sleep (which is not true, it keeps e.g. the anchor watch) but the screen will go into standby and so the power consumption of a very awake Raspberry drops down to 500 mA, which means it helps a lot to preserve power and keeps the batteries alive. For just this and some other reasons, I think a dedicated "Nav-Computer" on this platform is very valuable. The PC I have to switch off, as the power consumption is way too high.

O.K.?

Best regards,

Uwe
HUR450502 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
Rpi OpenCPN System - recommendations geoffr OpenCPN 17 01-02-2017 10:45
Rpi 3/2 hardware opengl and Vector charts jimseng OpenCPN 16 09-04-2016 18:10
Rpi 3 hangs when zoomed out. jimseng OpenCPN 14 11-03-2016 20:53
Raspbian Jessie for RPi duichan OpenCPN 3 29-09-2015 16:47
AIS on RPI not working gbgb OpenCPN 6 10-06-2015 11:29

Advertise Here


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


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.