MX8 suspend: Difference between revisions

From Variscite Wiki
No edit summary
No edit summary
Line 92: Line 92:
- Pressing any key on debug console defined as wake-up source before entering suspend (see below):<br>
- Pressing any key on debug console defined as wake-up source before entering suspend (see below):<br>
  {{#varexists:UART_CONSOLE_PATH|
  {{#varexists:UART_CONSOLE_PATH|
  echo enabled > {{#var:UART_CONSOLE_PATH}}
  # echo enabled > {{#var:UART_CONSOLE_PATH}}
  |
  |
  {{#ifeq: {{#var:HARDWARE_NAME}}|VAR-SOM-MX8X|
  {{#ifeq: {{#var:HARDWARE_NAME}}|VAR-SOM-MX8X|
  echo enabled > /sys/devices/platform/5a090000.serial/tty/ttyLP3/power/wakeup
  # echo enabled > /sys/devices/platform/5a090000.serial/tty/ttyLP3/power/wakeup
  |
  |
  echo enabled > /sys/devices/platform/5a060000.serial/tty/ttyLP0/power/wakeup
  # echo enabled > /sys/devices/platform/5a060000.serial/tty/ttyLP0/power/wakeup
}}
}}
}}
}}

Revision as of 15:13, 2 June 2021

VAR-SOM-MX8X Suspend to RAM

Suspend to RAM

This state offers significant power savings as everything in the system is put into a low-power state, except for memory, which is placed into the self-refresh mode to retain its contents.

To suspend to RAM execute the following command:

# pm-suspend

Wake up

There are many possible ways to wake up from suspend.
A few examples:
- Pushing the ON/OFF button (when present on the board)
- Pushing a button on the board which has the boolean property "wakeup-source" set in its device tree node (under gpio_keys), e.g.:

	gpio-keys {
		compatible = "gpio-keys";
		pinctrl-names = "default";
		pinctrl-0 = <&pinctrl_gpio_keys>;
               ...
               back {
                       label = "Back";
                       gpios = <&gpio4 6 GPIO_ACTIVE_LOW>;
                       linux,code = <KEY_BACK>;
                       wakeup-source;
               };
	};

- Pressing the capacitive touch which has the "wakeup-source" property set in its device tree node, e.g.:

       ft5x06_ts: ft5x06_ts@38 {
               status = "disabled";
               compatible = "edt,edt-ft5x06";
               reg = <0x38>;
               reset-gpios = <&gpio4 5 GPIO_ACTIVE_LOW>;
               pinctrl-names = "default";
               pinctrl-0 = <&pinctrl_touch>;
               interrupt-parent = <&gpio1>;
               interrupts = <14 0>;
               touchscreen-size-x = <800>;
               touchscreen-size-y = <480>;
               touchscreen-inverted-x;
               touchscreen-inverted-y;
               wakeup-source;
       };

- Pressing any key on debug console defined as wake-up source before entering suspend (see below):

  1. echo enabled > /sys/devices/platform/5a090000.serial/tty/ttyLP3/power/wakeup