From ef5c05683c1f6970e95ec17dcb0efcfc8f13b017 Mon Sep 17 00:00:00 2001 From: bunnie Date: Tue, 15 Nov 2022 02:23:13 +0800 Subject: [PATCH] add a quick and dirty test command for headphone state --- services/shellchat/src/cmds/test.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/services/shellchat/src/cmds/test.rs b/services/shellchat/src/cmds/test.rs index 6dc1c733f..9e845b089 100644 --- a/services/shellchat/src/cmds/test.rs +++ b/services/shellchat/src/cmds/test.rs @@ -665,6 +665,9 @@ impl<'a> ShellCmdApi<'a> for Test { Err(e) => log::error!("couldn't get input: {:?}", e), } } + "hpstate" => { + write!(ret, "HP state: {:?}", self.codec.poll_headphone_state()).ok(); + } "ecup" => { let ecup_conn = env.xns.request_connection_blocking("__ECUP server__").unwrap(); xous::send_message(ecup_conn,