<div dir="ltr"><div><div><div><div><div>Hey Charles,<br><br></div>Thanks for the prompt response.<br><br></div>After sudo bash I get:<br>root@raspberrypi:/home/pi# echo gpio17 &gt; /sys/class/gpio/export<br>bash: echo: write error: Invalid argument<br>
<br></div><div>The previous commands I tried were sudo&#39;ing everything and also &#39;sudo -i&#39;.<br><br></div><div>OAN:<br></div><div><br></div>Dumb question #256<br></div>I&#39;m presuming &#39;gpio17&#39; is to allow access to pin 17 and not what was my first impression that gpio17 allows access to all 18 pins?<br>
<br></div>Best wishes,<br><br>Julian<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On 2 April 2013 10:35, Charles Goyard <span dir="ltr">&lt;<a href="mailto:cg@fsck.fr" target="_blank">cg@fsck.fr</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Julian,<br>
<br>
The commands I gave and to be run as root.<br>
so:<br>
<br>
sudo bash<br>
<div class="im">echo gpio17 &gt; /sys/class/gpio/export<br>
echo out &gt; /sys/class/gpio/gpio17/direction<br>
chown charles /sys/class/gpio/gpio17/value<br>
</div>exit<br>
pd &amp;<br>
<br>
Can you post the full command set you tried ?<br>
<br>
It seems there&#39;s an overall consensus on running pd (and all kinds of<br>
other stuff) as root on the pi. I don&#39;t agree with this but that&#39;s life<br>
and I don&#39;t use the pi much anyway.<br>
<br>
Cheers,<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Charles<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
Julian Brooks wrote:<br>
&gt; Hi Charles / list,<br>
&gt;<br>
&gt; Can I ask you/anyone a question re: permissions for accessing the gpio pins<br>
&gt; please?<br>
&gt;<br>
&gt; Currently I can&#39;t get past:<br>
&gt; &quot;echo gpio17 &gt; /sys/class/gpio/export&quot;<br>
&gt; which gives me &quot;permission denied&quot; with everything I&#39;ve tried.<br>
&gt;<br>
&gt; Are you using WiringPi to allow access to the gpio and if not how?<br>
&gt;<br>
&gt; I&#39;d like to stick with Miller&#39;s [gpio] object<br>
&gt; <a href="http://crca.ucsd.edu/~msp/syllabi/206.13w/index.htm" target="_blank">http://crca.ucsd.edu/~msp/syllabi/206.13w/index.htm</a><br>
&gt; (found in the earlier split thread - apologies for the noise)<br>
&gt; and keep as much within Pd as possible.<br>
&gt;<br>
&gt; Best wishes,<br>
&gt;<br>
&gt; Julian<br>
&gt;<br>
&gt;<br>
&gt; On 28 January 2013 14:14, Charles Goyard &lt;<a href="mailto:cg@fsck.fr">cg@fsck.fr</a>&gt; wrote:<br>
&gt;<br>
&gt; &gt; Hi list,<br>
&gt; &gt;<br>
&gt; &gt; I could make use of gpio (as output) within pd with just [textfile] :<br>
&gt; &gt;<br>
&gt; &gt; on the command-line:<br>
&gt; &gt;<br>
&gt; &gt; echo gpio17 &gt; /sys/class/gpio/export<br>
&gt; &gt; echo out &gt; /sys/class/gpio/gpio17/direction<br>
&gt; &gt; chown charles /sys/class/gpio/gpio17/value<br>
&gt; &gt;<br>
&gt; &gt; inside pd:<br>
&gt; &gt;<br>
&gt; &gt; [ set 1 (  [ write /sys/class/gpio/gpio17/value cr (<br>
&gt; &gt; |<br>
&gt; &gt; [ textfile ]<br>
&gt; &gt;<br>
&gt; &gt; works.<br>
&gt; &gt;<br>
&gt; &gt;<br>
&gt; &gt; I use it to drive a light system from a track of a audio file containing<br>
&gt; &gt; only square waves at a given frequency (say, cues embedded inside an<br>
&gt; &gt; audio file).<br>
&gt; &gt;<br>
&gt; &gt; I basically snapshot~ and see if it&#39;s over or below 0, and turn the gpio<br>
&gt; &gt; on/off on change.<br>
&gt; &gt;<br>
&gt; &gt; I started using pd on the pi three hours ago and have it playing audio and<br>
&gt; &gt; banging the gpio in no time.<br>
&gt; &gt;<br>
&gt; &gt; Thanks to all for this wonderful community.<br>
&gt; &gt;<br>
&gt; &gt; I&#39;m very happy ;).<br>
&gt; &gt;<br>
&gt; &gt;<br>
&gt; &gt; --<br>
&gt; &gt; Charles<br>
&gt; &gt;<br>
&gt; &gt; _______________________________________________<br>
&gt; &gt; <a href="mailto:Pd-list@iem.at">Pd-list@iem.at</a> mailing list<br>
&gt; &gt; UNSUBSCRIBE and account-management -&gt;<br>
&gt; &gt; <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br>
&gt; &gt;<br>
<br>
_______________________________________________<br>
<a href="mailto:Pd-list@iem.at">Pd-list@iem.at</a> mailing list<br>
UNSUBSCRIBE and account-management -&gt; <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br>
</div></div></blockquote></div><br></div>