TS-7970 Silabs Sleep Mode

From embeddedTS Manuals
Revision as of 17:44, 31 May 2016 by Mark (talk | contribs) (Created page with "Even though the "tsmicroctl" command allows you to directly put the system to sleep, this is not usually what you want to directly call. This would be equivalent to pulling p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Even though the "tsmicroctl" command allows you to directly put the system to sleep, this is not usually what you want to directly call. This would be equivalent to pulling power to the system which can cause data loss. When systemd shuts down it will call all executables in /lib/systemd/system-shutdown/. You can create a script silabs-sleep in this directory with these contents:

#!/bin/bash

tsmicroctl --sleep 10

And make it executable:

chmod a+x /lib/systemd/system-shutdown/silabs-sleep

Now the board will sleep immediately following a shutdown. It is safe during the sleep mode to disconnect power.