PowerOff options

Tanix Tx3 Mini running 8.90.2

I wonder about the differences between doing a power off from the Kodi power menu and pressing the Power button on the remote control … could someone point me to where I might read about the differences between these?

I see a huge difference in the time it takes to shut down, so I expect one is doing much more than the other … but have not been able to find what.

Thanks.

I’ve still not found any direct comparison.
Anyone got a pointer for me?

Thanks.

Pressing power on your remote invokes a shutdown via the OS and bypasses Kodi.

Pressing shutdown in the Kodi menu will ensure that databases are closed correctly and then issues the shutdown command to the OS.

1 Like

@anon88919003 Thank you.

It seems there is no real difference if I understand correctly, as an OS shutdown will send a signal to running processes (incl Kodi) which should cause them to shutdown gracefully.

Do I understand correctly?

It doesn’t appear to be a graceful shutdown when using power off via IR.

It doesn’t appear to be a graceful shutdown when using power off via IR.

OK, thanks, that might explain why I believe I notice some difference in the shutdown times.

How might I find out what the shutdown command used is for the power off switch?
Sorry for such a basic question but I am still trying to find my way around.

Powerdown

Thanks.
Kodi uses a ‘powerdown()’ function … and for the moment I will make a dangerous assumption that this would be similar to, if not exactly,
shutdown now -h
I have failed to find that function defined. :frowning:
(of course it might be something completely different)

When the power button is pressed on the remote what command is issued?
Can you point me to where I might find that info?

Thanks for any hints or pointers to where I should look.

I’m pretty sure that it is the command that I programmed into my Harmony remotes for poweroff. It definitely is shutting down the OS for me (takes ~3+ secs for the box to go off). Make a backup before you try and then it’s easy to fix, if your suspicions are correct. :wink:

I am using the remote that came with the Tanix Tx3 mini device and cannot seem to locate the relevant file to determine what command is being used, or maybe try to edit that command to see if I get a different result from using it.
Any ideas?
Thanks.

I doubt you will be able to edit the hard coded signal for on/off from your remote.
I suspect the nearest you can get is to redefine another key for OFF using the info available here.
I’m pretty spoilt myself, since I use Harmony remotes, so probably not much help to you

OK, thanks.
There are no spare keys on this remote which is very basic.

I will continue to observe behaviour and maybe in the meantime someone might be able to point me in the right direction to check what command the Power button invokes.

It might well be the same as the Kodi command and/or the one I posted above.

The power button is so much simpler than using the Kodi menu, so I would like to be sure that partitions are unmounted correctly and processes stopped before power is withdrawn when used.

Backup, change one button and find out if kodi inbuilt Powerdown works for you. If so, choose which button to change existing abilty. If not, restore, and all is as it was.

I’m actually used to use the power off on my Videostrong - Blue Grey MECOOL M8S Pro remote mapped by WRXTASY. So should all of us use the power off in Kodi or is it in my case safe enough to use the power off on my remote?

I can see from the remote file that work_mode is set to software, repeat_enable is set to true with “0x59 116 # power”

If, when you press power off on the remote, there’s a delay of a few seconds before the box turns off, then I think that is a good indication that the OS is shutting down properly. Instant off, not a good sign!

1 Like

good to know what happens when press power off on remote, but i guess its shutdown (as it takes 2 or 3 sec until the box goes to standby) triggered by kodi.
a power off should take 1 sec only.
in kodi power off and shutdow function, i dont see any difference on my box (same time and goes to standby)

I think a better point would be why are you shutting down? These devices are such low power that they consume the same as your average router, there is really little need to be doing it.

mhm, well i just need it on demand, 1 or 2 days a week and i am used to save power :wink:
its not huge money you save, but also not very less

It costs less than €10/$10 to keep one of these devices powered on 24/7 for a whole year.

I always turn off power to all devices every night … including TVs and associated equipment.
I do not do it for the sake of the money saved.
I do so as a precautionary measure, because PSUs can and do fail and cause damage, particularly if there is no one to notice. … and I am aware I am using some cheap Chinese made devices …
True 99.9% of the time that is not needed, but I sleep better knowing it most definitely will not happen. :wink:


On the matter of this thread … I tried the second devel release to see if it would make any difference to the delay shutting down from the Kodi menu, and it did (although the display stayed at ‘boot’).
Because of the display problem I reverted (today) to 8.90.2 and I no longer see the problem I had.
I checked the small difference in shutdown time between Kodi menu and Power button, and it is about 5 secs only (was a lot more).
It does appear that the Power button is issuing a command that causes the OS to shutdown gracefully as there is little difference between the two.

I also compared the times to issuing the shutdown command from an SSH session and it too worked as expected.

My only conclusion is that I had some corruption on the SD card which has been cleared by upgrading the OS.

My apologies for raising such a fuss about this, only to find it disappear without a proper explanation.

Thanks to all for the helpful posts.