Could be, but I can't get to understand how that, in time, translates to:pcmanbob wrote: ↑Fri Dec 08, 2017 1:02 pmI suspect your relay board and the LCD display being powered from the pi gpio 5v pin is what's causing your problem, either the relay switching is causing a volt drop on the power supply or noise is being put back into the 5v supply by the relay board.
try powering the relay board from its own 5v power supply , you will need to remove the jumper to do this, connecting the new power supply to JD-VCC and Gnd. check JD-VCC with a meter once you have removed the jumper and make sure there is no 5v on it before connecting your new power supply.
Code: Select all
root 523 81.6 2.3 1586840 10448 pts/1 Ssl+ Dec07 707:34 \_ /usr/bin/python /root/deposito_v4.py # w 10:55:10 up 14:27, 1 user, load average: 133.95, 135.62, 133.84
Code: Select all
root 513 7.2 1.6 152212 7492 pts/1 Ssl+ 13:34 10:08 \_ /usr/bin/python /root/deposito_v4.py # w 15:54:38 up 2:20, 1 user, load average: 0.20, 0.19, 0.18
That's the weirdness in all of this. There's nothing running but the python program, and nginx to serve a simple static website showing some graphs updated every 5 minutes with gnuplot from the application log. The pi gets rebooted by a cron job daily at early morning (to avoid potential stuff like that; despite having other pi systems running for months, I prefer this one to be "daily fresh").pcmanbob wrote: ↑Fri Dec 08, 2017 4:54 pmThere is no way the relay board can affect CPU load it after all just connected to the GPIO and it makes no difference to the CPU if the relay board is connected or not the GPIO will still be driven just the same by what ever program is controlling it.
Assuming you had the same programs running in both of the above cases, was one after the pi had been running for some time and one just after a reboot by ant chance.
They're using te RPi's 5V output not an external 5V power source (yet). As I said a few posts ago, tried that setup in the beginning to see if it were avoiding me the LCD's garbling but it did not, so I took the rc snubber way and kept RPi's power source for the relays hence simplifying the design without a 2nd power source (not space/resources limit/problem, just that it didn't seem necessary at the time).. I'm not entirely sure about what you mean with the "the forward current for each optocoupler"... The optocouplers are integrated in the relay board design, basically, theres's not much you can do about that (afaik).
Yes, those relay boards are active low. I'm using a 2803 between the relay and the RPi also.
That is not the issue. The supply fior the relays is not coming throught the GPIO pins, but from the 5V rail. This could possibly overload the supply (which is why it's worth trying a separate one), but it's not related to the 50mA per GPIO bank limit.