PDA

View Full Version : RPi and PIR-1, logger loops - "PIR-1 arrived" 2 seconds later, "PIR-1" removed...



declan slater
November 14th, 2015, 12:11 AM
RPi and PIR-1, logger just loops - "PIR-1 arrived" 2 seconds later, "PIR-1" removed... over and over...

What am I doing wrong?

Is there still a glitch creating the 'Girder 6.ini' file, it was missing when I installed and I had to make the directory, the file, and key info from scratch. Did I miss something?

running as a user "girder", but it has root and sudo permissions... and I even "sudo startx" too...

help? - Thanks Ron!
-Declan.

declan slater
November 14th, 2015, 11:25 AM
Found the same problem here...
21984-Girder6-Rasperry-Pi-PIR-1
(Sorry, I can't post links yet...)

I've got a fresh wheezy install, according to the sticky, I did not install the extra bits before girder like that though, is that necessary? Do I need to start over from scratch now?


RPi and PIR-1, logger just loops - "PIR-1 arrived" 2 seconds later, "PIR-1" removed... over and over...

What am I doing wrong?

Is there still a glitch creating the 'Girder 6.ini' file, it was missing when I installed and I had to make the directory, the file, and key info from scratch. Did I miss something?

running as a user "girder", but it has root and sudo permissions... and I even "sudo startx" too...

help? - Thanks Ron!
-Declan.

Ron
November 16th, 2015, 08:33 AM
Can you try running the PIR-1 via a powered USB hub. When connected to a desktop computer does the PIR-1 work as expected?

declan slater
November 16th, 2015, 01:47 PM
Thanks for the reply, yes I have a powered hub, that is correctly recognized during boot, and the PIR-1 also works fine under windows 7. I would have tried it under debian on a pc, but that install has jessie on it, and I believe that won't work yet. I'll try it out on a different pc today, if I can find and image that is still available.


Can you try running the PIR-1 via a powered USB hub. When connected to a desktop computer does the PIR-1 work as expected?

declan slater
November 17th, 2015, 12:59 AM
Ok, I just started over again, using Dietpi (Wheezy) - which actually runs very well compared to Raspbian, but it does exactly the same thing. hymm.

Yep, I had to create the missing Girder 6.ini' file again too, is it missing from the script or something? Is that related to my problem maybe?

I'll double check the powered usb hub tomorrow on my windows 7 machine running Girder to see if anything odd happens there, I guess...

Thanks!


Thanks for the reply, yes I have a powered hub, that is correctly recognized during boot, and the PIR-1 also works fine under windows 7. I would have tried it under debian on a pc, but that install has jessie on it, and I believe that won't work yet. I'll try it out on a different pc today, if I can find and image that is still available.

declan slater
November 17th, 2015, 11:29 AM
Ok, Just tried the powered hub on my win7 installation, works perfectly straight away. Girder finds it right away, without any need to reboot, and does not forget it 2 seconds later, and loop like it does on my Rpi1.

So, I guess my next step is to try installing wheezy on a laptop or something to see if it is a linux thing or something?

Does it work for you on an Rpi1? Maybe something updated somewhere that goofed it up?... There has got to be a catch here, If so, whats the trick? Maybe, can you post an image file that you have that works?

Thanks for the help... I'm pretty stuck.


Ok, I just started over again, using Dietpi (Wheezy) - which actually runs very well compared to Raspbian, but it does exactly the same thing. hymm.

Yep, I had to create the missing Girder 6.ini' file again too, is it missing from the script or something? Is that related to my problem maybe?

I'll double check the powered usb hub tomorrow on my windows 7 machine running Girder to see if anything odd happens there, I guess...

Thanks!

declan slater
November 17th, 2015, 02:16 PM
I found this older thread, with the same problem:
http://www.promixis.com/forums/showthread.php?21984-Girder6-Rasperry-Pi-PIR-1/page2

where you mention: "I have a feeling that two Girder might have been fighting each other... One running on startup and one started by separately."

might that be the issue? if so, how can I fix and/or prevent that?

declan slater
November 17th, 2015, 02:45 PM
Ok, I ran "htop" and killed the /opt/girder/Girder6 process that was automatically started at boot by root, then ran "startx", and started Girder from the desktop as root - now it works great... No looping! Yeah!

So, how do I prevent that from happening again, and why does that not happen with windows...
Hymm... (scratching head sound...) - Sorry to be such a nube, with the dumb questions...

Ron
November 17th, 2015, 03:04 PM
I can't remember the magic incantation :) but I think it's something like this:



sudo update-rc.d girder disable

declan slater
November 17th, 2015, 03:07 PM
Thanks, but what does that do? (asks the student)...

Ron
November 17th, 2015, 03:26 PM
So the problem is that Girder is running in the background as well. This is really what you want most likely. So if you'd like to keep Girder running on your RPI don't do the above and when starting the GUI go to the second tab called local network and select the entry from the list. The default password is Girder.

If you still want to stop Girder from running in the background run the code above and reboot your RPI. That command removes Girder from the init.d system. (or whatever debian is using on the RPI).

declan slater
November 17th, 2015, 03:26 PM
Thanks, but what does that do? (asks the student)...

Sorry to ask, but when I run just the front end now, right after boot - it works fine.

If I start the back end first at the command prompt, then startx, then run the front end, I get the looping

If I then close the front end (File / Exit) - it leaves the first /opt/girder/Girder6 process running, but closes its window, and if I then run the front end again, it starts a duplicate /opt/girder/Girder6 process, making the looping worse/faster...

So, I should just either run the back end, or the front end, not both on the same machine, right?

I should also be careful to be sure to REALLY kill the Girder6 process, if I close it out to prevent dupes, then?

Ron
November 17th, 2015, 04:06 PM
Girder has two parts.

1. The back-end, this does all the automation - it's completely separate from the UI, and lives beyond the UI (which is what it is supposed to do).

2. The front-end, this is the UI, this typically has a shorter life than the back-end.

(UI = user interface).

Girder can start in 3 different modes:

1. Back-end only

2. Front-end only

3. In Process = Back-end + Front-end.

If you have the back-end running in mode 1 and then start Girder in Mode 3, you effectively have 2 backends which turns out to create this odd loop. So when running Girder make sure that you only run the front-end (mode 2) and leave the back-end just to run.

declan slater
November 17th, 2015, 05:07 PM
Thanks Ron, That's a TON of help! Thanks for the extra explanation too!

I've got some learnin' to do on mode 2...