You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Usage: ectool [--dev=n] [--interface=dev|i2c|lpc] [--i2c_bus=n][--name=cros_ec|cros_fp|cros_pd|cros_scp|cros_ish] [--ascii] <command> [params]
--i2c_bus=n Specifies the number of an I2C bus to use. For
example, to use /dev/i2c-7, pass --i2c_bus=7.
Implies --interface=i2c.
Commands:
adcread <channel>
Read an ADC channel.
addentropy [reset]
Add entropy to device secret
apreset
Issue AP reset
autofanctrl <on>
Turn on automatic fan speed control.
backlight <enabled>
Enable/disable LCD backlight
battery
Prints battery info
batterycutoff [at-shutdown]
Cut off battery output power
batteryparam
Read or write board-specific battery parameter
boardversion
Prints the board version
button [vup|vdown|rec] <Delay-ms>
Simulates button press.
cbi
Get/Set/Remove Cros Board Info
chargecurrentlimit
Set the maximum battery charging current
chargecontrol
Force the battery to stop charging or discharge
chargeoverride
Overrides charge port selection logic
chargestate
Handle commands related to charge state v2 (and later)
chipinfo
Prints chip info
cmdversions <cmd>
Prints supported version mask for a command number
console
Prints the last output to the EC debug console
cec
Read or write CEC messages and settings
echash [CMDS]
Various EC hash commands
eventclear <mask>
Clears EC host events flags where mask has bits set
eventclearb <mask>
Clears EC host events flags copy B where mask has bits set
eventget
Prints raw EC host event flags
eventgetb
Prints raw EC host event flags copy B
eventgetscimask
Prints SCI mask for EC host events
eventgetsmimask
Prints SMI mask for EC host events
eventgetwakemask
Prints wake mask for EC host events
eventsetscimask <mask>
Sets the SCI mask for EC host events
eventsetsmimask <mask>
Sets the SMI mask for EC host events
eventsetwakemask <mask>
Sets the wake mask for EC host events
extpwrlimit
Set the maximum external power limit
fanduty <percent>
Forces the fan PWM to a constant duty cycle
flasherase <offset> <size>
Erases EC flash
flasheraseasync <offset> <size>
Erases EC flash asynchronously
flashinfo
Prints information on the EC flash
flashspiinfo
Prints information on EC SPI flash, if present
flashpd <dev_id> <port> <filename>
Flash commands over PD
flashprotect [now] [enable | disable]
Prints or sets EC flash protection state
flashread <offset> <size> <outfile>
Reads from EC flash to a file
flashwrite <offset> <infile>
Writes to EC flash from a file
forcelidopen <enable>
Forces the lid switch to open position
fpcontext
Sets the fingerprint sensor context
fpencstatus
Prints status of Fingerprint sensor encryption engine
fpframe
Retrieve the finger image as a PGM image
fpinfo
Prints information about the Fingerprint sensor
fpmode [capture|deepsleep|fingerdown|fingerup]
Configure/Read the fingerprint sensor current mode
fpseed
Sets the value of the TPM seed.
fpstats
Prints timing statisitcs relating to capture and matching
fptemplate [<infile>|<index 0..2>]
Add a template if <infile> is provided, else dump it
gpioget <GPIO name>
Get the value of GPIO signal
gpioset <GPIO name>
Set the value of GPIO signal
hangdetect <flags> <event_msec> <reboot_msec> | stop | start
Configure or start/stop the hang detect timer
hello
Checks for basic communication with EC
hibdelay [sec]
Set the delay before going into hibernation
hostsleepstate
Report host sleep state to the EC
hostevent
Get & set host event masks.
i2cprotect <port> [status]
Protect EC's I2C bus
i2cread
Read I2C bus
i2cwrite
Write I2C bus
i2cxfer <port> <slave_addr> <read_count> [write bytes...]
Perform I2C transfer on EC's I2C bus
infopddev <port>
Get info about USB type-C accessory attached to port
inventory
Return the list of supported features
kbfactorytest
Scan out keyboard if any pins are shorted
kbid
Get keyboard ID of supported keyboards
kbinfo
Dump keyboard matrix dimensions
kbpress
Simulate key press
keyscan <beat_us> <filename>
Test low-level key scanning
led <name> <query | auto | off | <color> | <color>=<value>...>
Set the color of an LED or query brightness range
lightbar [CMDS]
Various lightbar control commands
mkbpget <buttons|switches>
Get MKBP buttons/switches supported mask and current state
mkbpwakemask <get|set> <event|hostevent> [mask]
Get or Set the MKBP event wake mask, or host event wake mask
motionsense [CMDS]
Various motion sense control commands
panicinfo
Prints saved panic info
pause_in_s5 [on|off]
Whether or not the AP should pause in S5 on shutdown
pdcontrol [suspend|resume|reset|disable|on]
Controls the PD chip
pdchipinfo <port>
Get PD chip information
pdlog
Prints the PD event log entries
pdwritelog <type> <port>
Writes a PD event log of the given <type>
pdgetmode <port>
Get All USB-PD alternate SVIDs and modes on <port>
pdsetmode <port> <svid> <opos>
Set USB-PD alternate SVID and mode on <port>
port80flood
Rapidly write bytes to port 80
port80read
Print history of port 80 write
powerinfo
Prints power-related information
protoinfo
Prints EC host protocol information
pse
Get and set PoE PSE port power status
pstoreinfo
Prints information on the EC host persistent storage
pstoreread <offset> <size> <outfile>
Reads from EC host persistent storage to a file
pstorewrite <offset> <infile>
Writes to EC host persistent storage from a file
pwmgetfanrpm [<index> | all]
Prints current fan RPM
pwmgetkblight
Prints current keyboard backlight percent
pwmgetnumfans
Prints the number of fans present
pwmgetduty
Prints the current 16 bit duty cycle for given PWM
pwmsetfanrpm <targetrpm>
Set target fan RPM
pwmsetkblight <percent>
Set keyboard backlight in percent
pwmsetduty
Set 16 bit duty cycle of given PWM
rand <num_bytes>
generate <num_bytes> of random numbers
readtest <patternoffset> <size>
Reads a pattern from the EC via LPC
reboot_ec <RO|RW|cold|hibernate|hibernate-clear-ap-off|disable-jump> [at-shutdown|switch-slot]
Reboot EC to RO or RW
reboot_ap_on_g3
Requests that the EC will automatically reboot the AP the next time
we enter the G3 power state.
rollbackinfo
Print rollback block information
rtcget
Print real-time clock
rtcgetalarm
Print # of seconds before real-time clock alarm goes off.
rtcset <time>
Set real-time clock
rtcsetalarm <sec>
Set real-time clock alarm to go off in <sec> seconds
rwhashpd <dev_id> <HASH[0] ... <HASH[4]>
Set entry in PD MCU's device rw_hash table.
rwsig <info|dump|action|status> ...
info: get all info about rwsig
dump: show individual rwsig field
action: Control the behavior of RWSIG task.
status: Run RW signature verification and get status.
{ rwsigaction (DEPRECATED; use "rwsig action")
Control the behavior of RWSIG task.
rwsigstatus (DEPRECATED; use "rwsig status"
Run RW signature verification and get status.
sertest
Serial output test for COM2
smartdischarge
Set/Get smart discharge parameters
stress [reboot] [help]
Stress test the ec host command interface.
sysinfo [flags|reset_flags|firmware_copy]
Display system info.
switches
Prints current EC switch positions
temps <sensorid>
Print temperature.
tempsinfo <sensorid>
Print temperature sensor info.
thermalget <platform-specific args>
Get the threshold temperature values from the thermal engine.
thermalset <platform-specific args>
Set the threshold temperature values for the thermal engine.
tpselftest
Run touchpad self test.
tpframeget
Get touchpad frame data.
tmp006cal <tmp006_index> [params...]
Get/set TMP006 calibration
tmp006raw <tmp006_index>
Get raw TMP006 data
typeccontrol <port> <command>
Control USB PD policy
typecdiscovery <port> <type>
Get discovery information for port and type
typecstatus <port>
Get status information for port
uptimeinfo
Get info about how long the EC has been running and the most
recent AP resets
usbchargemode <port> <mode> [<inhibit_charge>]
Set USB charging mode
usbmux <mux>
Set USB mux switch state
usbpd <port> <auto | [toggle|toggle-off|sink|source] [none|usb|dp|dock] [dr_swap|pr_swap|vconn_swap]>
Control USB PD/type-C [deprecated]
usbpdmuxinfo
Get USB-C SS mux info
usbpdpower [port]
Get USB PD power information
version
Prints EC version
waitevent <type> [<timeout>]
Wait for the MKBP event of type and display it
wireless <flags> [<mask> [<suspend_flags> <suspend_mask>]]
Enable/disable WLAN/Bluetooth radio
Especially relevant when laptop is suspend, hence the power LED is blinking and the lid is not closed, as it can literally light up the whole room in the dark.
Activity
Benjamin-Loison commentedon Sep 2, 2024
Related to #13.
Benjamin-Loison commentedon Sep 2, 2024
ectool helpOutput:
Related to Benjamin-Loison/cinnamon/issues/168#issuecomment-3582164843.
pwm occurrences do not seem interesting.
Should check entry by entry and possible new commits.
Benjamin-Loison commentedon Sep 8, 2024
Note that sometimes the power LED is blinking for an unknown reason and being able to set a lower brightness or even 0 would be nice.
Benjamin-Loison commentedon Sep 19, 2024
Especially relevant when laptop is suspend, hence the power LED is blinking and the lid is not closed, as it can literally light up the whole room in the dark.
Benjamin-Loison commentedon Nov 23, 2025
jonas-schievink/keylightd/blob/933a4cf851009d4a8c1b4ce7725556d69d4b82db/README.md?plain=1#L47
jonas-schievink/keylightd/blob/933a4cf851009d4a8c1b4ce7725556d69d4b82db/src/main.rs#L68-L83
does not seem yet as promising.
Related to issues/33#issuecomment-3567296419.