Page 1 of 1

Turn RPi 3 on with remote?

Posted: Wed Jun 12, 2019 8:17 pm
by Dogga85
Hey all,
I just set my new RPi 3 up with Kodi as my Plex client. I have a Rii remote to use with it which is great, but is there any way to turn the RPi ON with a remote instead of having to turn it off/on by the power switch on the wall every time???

Re: Turn RPi 3 on with remote?

Posted: Wed Jun 12, 2019 8:56 pm
by W. H. Heydt
If the Pi has power, it is on (to varying extent, depending on what else has been done). If it doesn't have power, there is no way for it to act on any signal in the environment. So, basically, the answer is, no, that won't work.

Note: You shouldn't just drop the power on a Pi. Start by issuing a shutdown command. After the system has had time to terminate all processes and quiesce the SD interface (allowing any remaining write activity on the card to *completely* finish), then you can drop the power. If you just cut the power, you may corrupt the SD card.

Re: Turn RPi 3 on with remote?

Posted: Wed Jun 12, 2019 9:13 pm
by Andyroo
The only way I have seen but not tried is https://www.msldigital.com/collections/ ... d-for-pi-3

I guess others are out in the world but this matched the needs of a dead project :lol:

Re: Turn RPi 3 on with remote?

Posted: Wed Jun 12, 2019 11:50 pm
by PhatFil
Its a pretty trivial home automation task, the catch being most RPi home automation solutions employ a Rpi 24/7/365 as a system server..

You could with some careful shopping find some compatible gadgets to link together for a solution with your phone and some cloud served apps.

Edit** Of course any OFF commands you issue should issue a proper shutdown command and delay a sufficient period before cutting power..

the broadlink rm mini can hijack IR signals , and link upto IFTT to control any compatible smart switch via its mobile phone app
https://www.googleadservices.com/pagead ... CDs&adurl=

The sonoff RF bridge and sonoff smart switches with its ewelink phone app will enable lifting most 433mhz RF codes for pairing with and control of smart switches.
** https://sonoff.itead.cc/en/products/app ... bridge-433

the down side being giving 3rd parties access to your phones as every app needs all access for some reason?? and your dependent on the remote servers being up and available, and i would suggest any lags in response to triggers may be longer when coms involve traffic to china and back..

If your prepared to invest in a Rpi-0-w and run it 24/7/365 there are lots of fun ways you can negate relying on remote data mining servers and privacy invading phone apps.

IF power costs are an issue iirc i read in a recent post in here that a headless Pi-0-w power demands should be less than 1w? but with an active Pi your i/o options expand and your response to commands should suffer no lag if all the traffic is local to your net.

** I like sonoff brand devices as they are open to reprogramming with custom firmware
and while i use the tasmota project firmware, you could easily write your own using the arduino ide or any other platform that supports the esp8266 soc.

Re: Turn RPi 3 on with remote?

Posted: Thu Jun 13, 2019 12:55 am
by Imperf3kt
I assume OP is looking for a way to leave the Pi in "standby" mode for convenient on / off via a button on their remote control much like how your TV functions.

You could probably just setup something that momentarily shorts the run pin to ground upon detecting a certain frequency.
Maybe a transistor and IR LED? Hit IR LED with beam from remote, transistor detects current and opens the gate.

Just an idea, I have no idea how practical it would be or if it would work as I think.

Re: Turn RPi 3 on with remote?

Posted: Thu Jun 13, 2019 2:55 am
by W. H. Heydt
Imperf3kt wrote:
Thu Jun 13, 2019 12:55 am
I assume OP is looking for a way to leave the Pi in "standby" mode for convenient on / off via a button on their remote control much like how your TV functions.

You could probably just setup something that momentarily shorts the run pin to ground upon detecting a certain frequency.
Maybe a transistor and IR LED? Hit IR LED with beam from remote, transistor detects current and opens the gate.

Just an idea, I have no idea how practical it would be or if it would work as I think.
By default (IIRC), pins 5 and 6. Short them together and the system shuts down. Do it again, and it reboots. All it takes is a single line in /boot/config.txt.

Code: Select all

dtoverlay=gpio-shutdown

Re: Turn RPi 3 on with remote?

Posted: Fri Jun 14, 2019 9:39 am
by Dogga85
Yes exactly, I was hoping I can do it just like a TV. I was concerned about leaving it on all the time. But perhaps leaving it on is the easiest solution? Hahaha

Re: Turn RPi 3 on with remote?

Posted: Fri Jun 14, 2019 10:58 am
by hippy
Imperf3kt wrote:
Thu Jun 13, 2019 12:55 am
You could probably just setup something that momentarily shorts the run pin to ground upon detecting a certain frequency.
Maybe a transistor and IR LED? Hit IR LED with beam from remote, transistor detects current and opens the gate.
It needs a little more than that but can easily be done with a microcontroller or another Pi. The main problem isn't so much powering-on as preventing a reset at an inopportune time.

Re: Turn RPi 3 on with remote?

Posted: Fri Jun 14, 2019 8:44 pm
by Imperf3kt
@hippy
W. H. Heydt's solution would presumably fix an unexpected reset and is admittedly, better than my own thoughts.

Still needs some more control though, seemingly.
I'll watch this thread to see what others come up with, it's an interesting idea.

Re: Turn RPi 3 on with remote?

Posted: Fri Jun 14, 2019 8:53 pm
by W. H. Heydt
What it really amounts to is that *something* has to be active and drawing power. That something has to be smart enough to recognize an input signal by some means or other and then trigger any further actions as needed. The very simplest solution of all is...don't turn the Pi off.

Re: Turn RPi 3 on with remote?

Posted: Sat Jun 15, 2019 1:36 am
by Dogga85
Thanks so much for everyone's replies. Looks like there's not really a solution for what I was after, so for the moment I just won't turn it off. Might buy a Flirc v2 case for it so it keeps nice and cool.

Re: Turn RPi 3 on with remote?

Posted: Sat Jun 15, 2019 3:01 am
by W. H. Heydt
Dogga85 wrote:
Sat Jun 15, 2019 1:36 am
Thanks so much for everyone's replies. Looks like there's not really a solution for what I was after, so for the moment I just won't turn it off. Might buy a Flirc v2 case for it so it keeps nice and cool.
I think I ought to point out that a TV that can be "turned on" or "turned off" with a remote, is never really "off". As in my point about, *something* has to be active for that trick to appear to work.

Re: Turn RPi 3 on with remote?

Posted: Sat Jun 15, 2019 4:37 am
by Imperf3kt
Which reminds me, isn't there some HDMI protocol which can turn supported devices on and off when the TV is switched on and off?
Could the Pi be configured to use this?

Edit: I'm sure I was thinking of a different protocol, but HDMI CEC seems like it may work.
https://en.wikipedia.org/wiki/Consumer_ ... cs_Control
CEC[3] is a separate electrical signal from the other HDMI signals. This allows a device to disable its high-speed HDMI circuitry in sleep mode, but be woken up by CEC. It is a single shared bus, which is directly connected between all HDMI ports on a device, so it can flow through a device which is completely powered off (not just asleep).

The bus is electrically identical to the AV.link protocol, but CEC adds a detailed higher-level message protocol.

The bus is an open-collector line, somewhat like I²C, passively pulled up to +3.3 V, and driven low to transmit a bit.

Re: Turn RPi 3 on with remote?

Posted: Sat Jun 15, 2019 12:22 pm
by hippy
Imperf3kt wrote:
Sat Jun 15, 2019 4:37 am
Which reminds me, isn't there some HDMI protocol which can turn supported devices on and off when the TV is switched on and off?
Could the Pi be configured to use this?
No, not without external hardware.

I am not sure if the Pi can receive CEC or whatever through HDMI but, even if it could, when powered off there would be nothing powered which could receive such commands.

The Pi only has three power states; power supplied and running, power supplied but not running, power not supplied.

There is no 'power supplied but only some things running' state which is what all wake-from-not-running systems require. That can only be achieved by using external hardware.

True; the reset handling is still running when the SoC is not running, but it requires external hardware to activate it.

It would seem possible to have this -

Code: Select all

HDMI Cable         Pi Computer
                 .--------------.
                _|_             |
        .-.__  |   |            |
========| |__| |   | CEC  Reset |
        `-'    |___|----.   o   |
                 |      |   |   |
                 `------|---|---'
                        |   |
                 .------|---|---.
                 |              |
                 `--------------'
               CEC Wake-Up Detector