pub struct SystemFlags {
pub flags: u32,
pub byte_1: u8,
pub byte_2: u8,
pub current_program: u8,
}
Fields§
§flags: u32
Bit mask. From left to right: no.1 to no.8 bit - Page index no.12 bit = Radio Data mode on no.14 bit = Brain button double clicked no.15 bit = Battery is charging no.17 bit = Brain button clicked no.18 bit = Is VexNet mode no.19 bit = Has partner controller no.22 bit = Radio connected no.23 bit = Radio available no.24 bit = Controller tethered no.30 bit = Page changed no.32 bit = Device added/removed (RESEARCH NEEDED)
byte_1: u8
Battery percent = First four bits * 8 Controller battery percent = Last four bits * 8
byte_2: u8
Radio quality = First four bits * 8 Partner controller battery percent = Last four bits * 8
current_program: u8
The current program slot number, 0 means not in a program. 129 = ClawBot program 145 = Driver program
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SystemFlags
impl RefUnwindSafe for SystemFlags
impl Send for SystemFlags
impl Sync for SystemFlags
impl Unpin for SystemFlags
impl UnwindSafe for SystemFlags
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more