pub fn write_bool(writer: &mut impl Write, v: bool) -> Result<(), WalletError>
Write a bool: 0x00=false, 0x01=true.