[arm-allstar] URIx GPIO use

Doug Crompton doug at crompton.com
Tue Jan 19 01:48:14 EST 2016


Robert,

 I should write a howto on this but there is some guidance out there if you search. Basically it is this - 
; When you configure a GPIO pin, you can either designate it as 
; 'in' (input), 'out0' (output with a default state of 'off'), 
; or 'out1' (output with a default state of 'on'). 

gpio1=out0 ; in, out0 or out1

This sets the bit as default off

Then you can create functions to control the bit. The function numbers can be anything you want that does not conflict with those in use.

In the [functions] section of rpt.conf -

82=cop,62,GPIO1=0 ; Turn off GPIO 1 
83=cop,62,GPIO1=1 ; Turn on GPIO 1

So in this case a dtmf *82 would turn the bit off and *83 on. You could also send the command from a macro, a script, the asterisk client, a cron job, etc.

Be careful with the hardware interface. For the DMK/URI they a 5V on the RPi2 3V. There are many isolated cheap relay modules that will interface directly to these bits.

See -

http://ohnosec.org/drupal/node/177

http://latinovoip.net/allstar-and-the-gpio-fan-script-for-dmk-engineering-uri/

Also see the USB GPIO and using GPIO on the Pi howto's on the hamvoip.org web page. There is a link there for relay modules.

You have three choices - use the DMK/URI bits as above, use the RPi2 GPIO, or use dedicated USB GPIO. 

73 Doug
WA3DSP
http://www.crompton.com/hamradio


Date: Mon, 18 Jan 2016 23:47:53 -0600
From: n4wgy.ham at gmail.com
To: arm-allstar at hamvoip.org
Subject: [arm-allstar] URIx GPIO use

Greetings everyone.I'm looking for some guidance on manipulating the gpio pins that are available in the URIx.It would be particularly nice to learn how to tie configurations of those gpio pins to a *5x macro, if such a thing is possible.
--Robert ConklinN4WGY


_______________________________________________

arm-allstar mailing list
arm-allstar at hamvoip.org
http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar

Visit the BBB and RPi2 web page - http://hamvoip.org 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.hamvoip.org/pipermail/arm-allstar/attachments/20160119/267492b9/attachment.html>


More information about the arm-allstar mailing list