Unable to change A1 and A2 LED

Topics about the Software of Revolution Pi
Post Reply
endress_cg
Posts: 4
Joined: 09 Oct 2018, 21:02
Answers: 0
Location: Indianapolis

Unable to change A1 and A2 LED

Post by endress_cg »

Hello, a college setup some strange stuff on once of our RevPi boxes and now I am unable to change the LED states using piTest command, I am assuming some service or interface has not been started, but cannot see what:

pi@RevPi4038:~ $ piTest -d
Found 1 devices:

Address: 0 module type: 95 (0x5f) RevPi Core V1.2
input offset: 0 length: 6
output offset: 6 length 5

pi@RevPi4038:~ $ piTest -w RevPiLED,4
pi@RevPi4038:~ $ piTest -w 6,1,4
Write value 4 hex (-4 dez) to offset 6.
pi@RevPi4038:~ $

a) Strange that the write with RevPiLED did not reply with anything (1st hint as to problem ?)
b) Second write does the same as on a working box but LED did not change
User avatar
Mathias
Posts: 130
Joined: 29 Nov 2016, 10:46
Answers: 0

Re: Unable to change A1 and A2 LED

Post by Mathias »

Hi,
piTest was developed as a demo program, it is not perfect in all parts. For example -w does not display an error message if a variable does not exist. Therefore your first call of piTest does not work.
The second call
$ piTest -w 6,1,4
Write value 4 hex (=4 dec) to offset 6.
should work.
Could it be that another program writes to the LED variable?
Can you send me the output of 'piTest -1 -r 0,11'?

Mathias
endress_cg
Posts: 4
Joined: 09 Oct 2018, 21:02
Answers: 0
Location: Indianapolis

Re: Unable to change A1 and A2 LED

Post by endress_cg »

Hi, I certainly cannot rule out another program writing to the LEDs but I do not know what it is if there.

As for the 'piTest -1 -r 0,11' test, the output was 11x '0'
User avatar
Mathias
Posts: 130
Joined: 29 Nov 2016, 10:46
Answers: 0

Re: Unable to change A1 and A2 LED

Post by Mathias »

Then the piControl driver is not running correctly.
Please delete the file /var/log/kern.log
reboot the RevPi
and send the new /var/log/kern.log file to me.
endress_cg
Posts: 4
Joined: 09 Oct 2018, 21:02
Answers: 0
Location: Indianapolis

Re: Unable to change A1 and A2 LED

Post by endress_cg »

Here is the log file
Attachments
kern.log.zip
(7.66 KiB) Downloaded 575 times
hobbit
Posts: 11
Joined: 04 Jan 2018, 18:50
Answers: 0

Re: Unable to change A1 and A2 LED

Post by hobbit »

Hi all
So far I was using RevPi Core 1 with Wheezy Image. But for some networking problems i recently updated to Jessie Image. My Python application also changes the A1 and A2 LED by 'piTest -w RevPiLED,<value>'. Since I updated to Jessie this doesn't work anymore. No changes on LEDs happen. A1 and A2 are allways off.
'piTest -1 -r 0,11' outputs 11x '0' as well.
'piTest -v RevPiLED' shows:
variable name: RevPiLED
offset: 0
length: 0
bit: 0

Any ideas what's the problem?
User avatar
Mathias
Posts: 130
Joined: 29 Nov 2016, 10:46
Answers: 0

Re: Unable to change A1 and A2 LED

Post by Mathias »

Hi,
that's a really stupid bug, I am really sorry about that.
You flashed the original image. In that image the configuration file /var/www/pictory/projects/_config.rsc is empty. That leads to this behaviour.
We use the same image when we produce the RevPis, but we run a test program afterwards. This program copies a nonempty file to the filesystem and everything is fine.
Unfortunately piTest shows the same output in both cases.

So please, open PiCtory, insert a RevPi V2.1, save the configuration and restart the driver. Then the LEDs should be working.

Mathias
hobbit
Posts: 11
Joined: 04 Jan 2018, 18:50
Answers: 0

Re: Unable to change A1 and A2 LED

Post by hobbit »

Perfect! This solved the problem for me.
endress_cg
Posts: 4
Joined: 09 Oct 2018, 21:02
Answers: 0
Location: Indianapolis

Re: Unable to change A1 and A2 LED

Post by endress_cg »

Hi, i sent you a log file a week ago and as yet no information on how to fix the led issue, I did attempt to do the instructions you gave to the other forum member, but am unable to due to the other changes on our box.
RaspAP installed (web access bring this up instead), no access to PiCore (link on local GUI does not work), unable to find and get to PiCtory
User avatar
Mathias
Posts: 130
Joined: 29 Nov 2016, 10:46
Answers: 0

Re: Unable to change A1 and A2 LED

Post by Mathias »

Hi,
according to your logfile your _config.rsc file is empty and the solution I described should help you.
I never used RaspAP. I am sorry, but I cannot help you with that.
Mathias
Post Reply