This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
RPI, OpenCPN and buzzer
#1
Bonjour,
Je voudrais avoir un buzzer au lieu de la sonnerie de l'alarme AIS. (Je n'ai aucun amplificateur).
Je pensais que c'était simple avec GPIO, mais en fait, je ne sais pas comment faire ça.
Une idée?
Reply
#2
You would need something like a transistor to use as a switch for the buzzer. RPI GPIO pins don't provide enough current for a buzzer directly.
Reply
#3
(2018-03-13, 09:34 PM)abarrow Wrote: You would need something like a transistor to use as a switch for the buzzer. RPI GPIO pins don't provide enough current for a buzzer directly.

I know. But my first problem is to open a GPIO pin...
Reply
#4
Here is a good thread on doing it using PWM. GPIO pins on RPIs are limited to a safe current of 16ma, so you won't get much volume without a transistor to switch the power to the buzzer.

https://www.raspberrypi.org/forums/viewt...hp?t=40515
Reply
#5
Thank you, but how AIS alarm can switch on GPIO pin ?
Reply
#6
Don't know for sure, but I would think you could do it with Node Red.
Reply
#7
Node-red, that's what I was thinking about. But I don't know how to do that.
Reply
#8
""Thank you, but how AIS alarm can switch on GPIO pin ?""

you can look into this node i haven't played with it yet but looks like it would work, probably work for anchor watch too..
https://flows.nodered.org/node/node-red-...b-geofence
https://www.npmjs.com/package/node-red-node-geofence

opencpn has AIS "sound cpa alarm"
Reply
#9
OK, but I think it's too complicated.
Isn't it possible to use OpenCPN alarm system for switching on a GPIO pin?
Reply
#10
http://forum.openmarine.net/showthread.php?tid=1032
if i had something built already to do it i would give it to you but i don't sorry
https://opencpn.org/wiki/dokuwiki/doku.p..._activated
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)