libcec_sys

Struct libcec_configuration

Source
#[repr(C)]
pub struct libcec_configuration {
Show 30 fields pub clientVersion: u32, pub strDeviceName: [c_char; 15], pub deviceTypes: cec_device_type_list, pub bAutodetectAddress: u8, pub iPhysicalAddress: u16, pub baseDevice: cec_logical_address, pub iHDMIPort: u8, pub tvVendor: u32, pub wakeDevices: cec_logical_addresses, pub powerOffDevices: cec_logical_addresses, pub serverVersion: u32, pub bGetSettingsFromROM: u8, pub bActivateSource: u8, pub bPowerOffOnStandby: u8, pub callbackParam: *mut c_void, pub callbacks: *mut ICECCallbacks, pub logicalAddresses: cec_logical_addresses, pub iFirmwareVersion: u16, pub strDeviceLanguage: [c_char; 3], pub iFirmwareBuildDate: u32, pub bMonitorOnly: u8, pub cecVersion: cec_version, pub adapterType: cec_adapter_type, pub comboKey: cec_user_control_code, pub iComboKeyTimeoutMs: u32, pub iButtonRepeatRateMs: u32, pub iButtonReleaseDelayMs: u32, pub iDoubleTapTimeoutMs: u32, pub bAutoWakeAVR: u8, pub bAutoPowerOn: u8,
}

Fields§

§clientVersion: u32

< the version of the client that is connecting

§strDeviceName: [c_char; 15]

< the device name to use on the CEC bus, name + 0 terminator

§deviceTypes: cec_device_type_list

< the device type(s) to use on the CEC bus for libCEC

§bAutodetectAddress: u8

< (read only) set to 1 by libCEC when the physical address was autodetected

§iPhysicalAddress: u16

< the physical address of the CEC adapter

§baseDevice: cec_logical_address

< the logical address of the device to which the adapter is connected. only used when iPhysicalAddress = 0 or when the adapter doesn’t support autodetection

§iHDMIPort: u8

< the HDMI port to which the adapter is connected. only used when iPhysicalAddress = 0 or when the adapter doesn’t support autodetection

§tvVendor: u32

< override the vendor ID of the TV. leave this untouched to autodetect

§wakeDevices: cec_logical_addresses

< list of devices to wake when initialising libCEC or when calling PowerOnDevices() without any parameter.

§powerOffDevices: cec_logical_addresses

< list of devices to power off when calling StandbyDevices() without any parameter.

§serverVersion: u32

< the version number of the server. read-only

§bGetSettingsFromROM: u8

< true to get the settings from the ROM (if set, and a v2 ROM is present), false to use these settings.

§bActivateSource: u8

< make libCEC the active source on the bus when starting the player application

§bPowerOffOnStandby: u8

< put this PC in standby mode when the TV is switched off. only used when bShutdownOnStandby = 0

§callbackParam: *mut c_void

< the object to pass along with a call of the callback methods. NULL to ignore

§callbacks: *mut ICECCallbacks

< the callback methods to use. set this to NULL when not using callbacks

§logicalAddresses: cec_logical_addresses

< (read-only) the current logical addresses. added in 1.5.3

§iFirmwareVersion: u16

< (read-only) the firmware version of the adapter. added in 1.6.0

§strDeviceLanguage: [c_char; 3]

< the menu language used by the client. 3 character ISO 639-2 country code. see http://http://www.loc.gov/standards/iso639-2/ added in 1.6.2

§iFirmwareBuildDate: u32

< (read-only) the build date of the firmware, in seconds since epoch. if not available, this value will be set to 0. added in 1.6.2

§bMonitorOnly: u8

< won’t allocate a CCECClient when starting the connection when set (same as monitor mode). added in 1.6.3

§cecVersion: cec_version

< CEC spec version to use by libCEC. defaults to v1.4. added in 1.8.0

§adapterType: cec_adapter_type

< type of the CEC adapter that we’re connected to. added in 1.8.2

§comboKey: cec_user_control_code

< key code that initiates combo keys. defaults to CEC_USER_CONTROL_CODE_STOP. CEC_USER_CONTROL_CODE_UNKNOWN to disable. added in 2.0.5

§iComboKeyTimeoutMs: u32

< timeout until the combo key is sent as normal keypress

§iButtonRepeatRateMs: u32

< rate at which buttons autorepeat. 0 means rely on CEC device

§iButtonReleaseDelayMs: u32

< duration after last update until a button is considered released

§iDoubleTapTimeoutMs: u32

< prevent double taps within this timeout. defaults to 200ms. added in 4.0.0

§bAutoWakeAVR: u8

< set to 1 to automatically waking an AVR when the source is activated. added in 4.0.0

§bAutoPowerOn: u8

< set to 1 and save eeprom config to wake the tv when usb is powered. added in 5.0.0 / fw v9

Trait Implementations§

Source§

impl Clone for libcec_configuration

Source§

fn clone(&self) -> libcec_configuration

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for libcec_configuration

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for libcec_configuration

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Copy for libcec_configuration

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.