diff --git a/services/keyboard/src/api.rs b/services/keyboard/src/api.rs index 22dd7e958..123cc6cf0 100644 --- a/services/keyboard/src/api.rs +++ b/services/keyboard/src/api.rs @@ -26,16 +26,16 @@ pub struct RowCol { #[derive(Debug)] #[repr(C)] pub struct KeyRawStates { - mid: usize, + mid: u32, pub keydowns: Vec, pub keyups: Vec, } impl KeyRawStates { - pub fn mid(&self) -> usize { self.mid } + pub fn mid(&self) -> usize { self.mid as usize } pub fn new() -> Self { KeyRawStates { - mid: xous::names::GID_KEYBOARD_RAW_KEYSTATE_EVENT, + mid: xous::names::GID_KEYBOARD_RAW_KEYSTATE_EVENT as u32, keydowns: Vec::new(), keyups: Vec::new(), }