diff --git a/services/shellchat/src/cmds/ver.rs b/services/shellchat/src/cmds/ver.rs index 8f7f8b515..d49a22a52 100644 --- a/services/shellchat/src/cmds/ver.rs +++ b/services/shellchat/src/cmds/ver.rs @@ -23,7 +23,7 @@ impl<'a> ShellCmdApi<'a> for Ver { let dirtystr = if dirty { "dirty" } else { "clean" }; write!(ret, "EC gateware commit: {:x}, {}\n", rev, dirtystr).unwrap(); let (maj, min, rev, commit) = env.com.get_ec_sw_tag().unwrap(); - log::info!("EC sw tag: {}.{}.{}+{}", maj, min, rev, commit); + log::info!("{}ECREV,{},{},{},{},{}", xous::BOOKEND_START, maj, min, rev, commit, xous::BOOKEND_END); write!(ret, "EC sw tag: {}.{}.{}+{}", maj, min, rev, commit).unwrap(); } "wf200" => { @@ -33,12 +33,14 @@ impl<'a> ShellCmdApi<'a> for Ver { "soc" => { let (maj, min, rev, extra, gitrev) = env.llio.soc_gitrev().unwrap(); write!(ret, "SoC git rev {}.{}.{}+{}, commit {:x}", maj, min, rev, extra, gitrev).unwrap(); + log::info!("{}SOCREV,{},{},{},{},{}", xous::BOOKEND_START, maj, min, rev, gitrev, xous::BOOKEND_END); } "dna" => { write!(ret, "SoC silicon DNA: 0x{:x}", env.llio.soc_dna().unwrap()).unwrap(); } "xous" => { write!(ret, "Xous version: {}", env.ticktimer.get_version()).unwrap(); + log::info!("{}XOUSREV,{},{}", xous::BOOKEND_START, env.ticktimer.get_version(), xous::BOOKEND_END); } _ => { write!(ret, "{}", helpstring).unwrap(); diff --git a/xous-rs/src/definitions.rs b/xous-rs/src/definitions.rs index 7f756bdcc..72df0e211 100644 --- a/xous-rs/src/definitions.rs +++ b/xous-rs/src/definitions.rs @@ -45,6 +45,15 @@ pub const PDDB_LEN: u32 = EC_REGION_LOC - PDDB_LOC; // must be 64k-aligned (bulk // quantum alloted to each process before a context switch is forced pub const BASE_QUANTA_MS: u32 = 10; +// sentinel used by test infrastructure to assist with parsing +// The format of any test infrastructure output to recover is as follows: +// _|TT|_,,_|TE|_ +// where _|TT|_ and _|TE|_ are bookends around the data to be reported +// is a single-word identifier that routes the data to a given parser +// is free-form data, which will be split at comma boundaries by the parser +pub const BOOKEND_START: &'static str = "_|TT|_"; +pub const BOOKEND_END: &'static str = "_|TE|_"; + #[cfg(not(any(target_os = "none", target_os = "xous")))] use core::sync::atomic::AtomicU64;