[mythtv-users] Raspberry Pi 4 FrontEnd Remote Control Issues
Barry Martin
barry3martin at gmail.com
Mon May 18 20:10:26 UTC 2020
Hi Stephen!
> Getting rid of the need for a password is tricky. It involves
> creating an /etc/sudoers.d file
I was snooping around last night and found this at
https://stackoverflow.com/questions/233217/how-to-pass-the-password-to-su-sudo-ssh-without-overriding-the-tty
:
echo <password> | su -c <command> <user>
So: echo MyPassword | su -l pi -c /home/pi/Load_MythFE.sh
(substitute the real password up there)
Modified the line in /etc/lirc/irexec.lircrc and seems to work.
Admittedly not a good solution for some as is easily found and displayed
in plain text but for me is fine. Will keep your suggestion as might
need a more secure option, and so far not 100% working – I haven’t
gotten the loading button on the remote to work yet.
Also had found my system wanted /export DISPLAY=:0.0/ – needed the
addition of “.0”. Found that at
https://forums.xilinx.com/t5/Embedded-Linux/Qt-window-can-not-be-displayed-Could-not-connect-to-any-X/td-p/902773
OK, still having problems I think with ‘the beginning’: when the yellow
button is pressed (KEY_C) nothing happens. I’m guessing this the
location of the problem because:
/etc/lirc/irexec.lircrc
Supposed to ‘see’ the button is pushed and run Load_MythFE.sh. If I run
the script at the Terminal things work. I also tried looking at the
MythWeb page of the Backend – which system is idle, active, etc. Yellow
button, nothing. Manual entry – becomes active. Just wanted to make sure
there wasn’t a display issue and the Frontend merely wasn’t being seen.
Also tried changing “config = echo “This is the C key”” to see if
anything pops up - - but to where? So tried “config = echo “This is the
C key” > /home/pi/Test.txt” hoping it would create the test file. Nope.
Trouble is I don’t know for certain if these test commands are right.
Guessing so as the first test is from some LIRC file.
So then while looking to see is the Test.txt file was being created saw
I had Test_LIRC.py. Not quite sure it’s supposed to do as was at the end
of an article I was using to guide me before asking for help here.
Article dead-ended at the script so I wasn’t sure what it did. Did give
me a potential clue: error message “no module named lirc”. (Didn’t we
install it like a dozen times early on?) (At Terminal) lirc → command
not found. sudo lirc → command not found. OK. install → already
installed. <sizzle>
I think off the “no module named lirc’ error Googled and found these
specifically on the RPi4:
https://www.raspberrypi.org/forums/viewtopic.php?t=269703
Thu Apr 02, 2020 → The latest version appears to be broken.
- -
Mon Apr 06, 2020 → As there has been no response from this I've been
looking at alternatives.
It looks like pigpio provides what I need which is easier than using
Lirc anyway.
https://www.raspberrypi.org/forums/viewtopic.php?t=235256
[Stretch/Buster] Using LIRC with kernel 4.19.X and gpio-i
<https://www.raspberrypi.org/forums/viewtopic.php?f=28&t=235256&sid=cda4dc3db943f0d9642a34f6fc2f088c>
Kernel 4.19 does not include lirc_dev, so it is recommended to use
gpio-ir.
https://lb.raspberrypi.org/forums/viewt ... 1&start=50
<https://lb.raspberrypi.org/forums/viewtopic.php?f=29&t=224931&start=50>
<More of article>
So at this point I’m not sure what to do. The second reference seems to
indicate patches and etc. I don’t ‘read’ code so at this point if better
to toss out the lirc stuff and go with pigpio (which I initially read as
“pig – pe – oh” and later occurred to me it’s ‘[raspberry] pi G-P-I-O’).
Could also just go back to the load at boot. ...Doesn’t quite make sense
why once MythFrontend is loaded the remote works.
I don’t know how much time and effort you want to put into this, though
I may be ‘leading the pack’ with a remote-operated RPi 4!
Barry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20200518/d1b69674/attachment.htm>
More information about the mythtv-users
mailing list