[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avrdude-dev] [bug #40748] linuxgpio doesn't work on Raspberry PI re
From: |
Joakim Lubeck |
Subject: |
Re: [avrdude-dev] [bug #40748] linuxgpio doesn't work on Raspberry PI rev. 2. |
Date: |
Sat, 30 Nov 2013 08:59:35 +0100 |
User-agent: |
SquirrelMail/1.4.21 |
On Fri, November 29, 2013 11:42 pm, René Liebscher wrote:
> Hi,
>
> I'm sure how you can get the error you observe. In the loop pin should
> never set to 0 for open the gpio file. (value = 0 is filtered and all
> exceptions of this are set to non-0 values.)
> Could print out the relevant values in the loop so I can understand what
> going on.
>
> Just insert the following line in the for loop:
>
> fprintf(stderr, "linuxgpio: i=%d, pin=%d, mask=%08x,
> inverse=%08x\n", i, pgm->pinno[i], pgm->pin[i].mask[0],
> pgm->pin[i].inverse[0]);
Hello,
With that printf as the first statement in the for loop I get,
Loop starts with i = 0
---
sudo ./avrdude -c linuxgpio -p t1634
linuxgpio: i=0, pin=0, mask=00000000, inverse=00000000
linuxgpio: i=1, pin=-2147483648, mask=00000000, inverse=00000000
linuxgpio: i=2, pin=-2147483648, mask=00000000, inverse=00000000
Can't export GPIO 0, already exported/busy?: Device or resource busy
avrdude done. Thank you.
---
Loop starts with i = 2
---
sudo ./avrdude -c linuxgpio -p t1634
linuxgpio: i=2, pin=-2147483648, mask=00000000, inverse=00000000
linuxgpio: i=3, pin=17, mask=00020000, inverse=00000000
linuxgpio: i=4, pin=2, mask=00000004, inverse=00000000
linuxgpio: i=5, pin=3, mask=00000008, inverse=00000000
linuxgpio: i=6, pin=4, mask=00000010, inverse=00000000
linuxgpio: i=7, pin=0, mask=00000000, inverse=00000000
linuxgpio: i=8, pin=0, mask=00000000, inverse=00000000
linuxgpio: i=9, pin=0, mask=00000000, inverse=00000000
linuxgpio: i=10, pin=0, mask=00000000, inverse=00000000
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e9412
avrdude: safemode: Fuses OK (E:1F, H:DF, L:E2)
avrdude done. Thank you.
---
/Joakim