### Class

# FwupdPlugin Device

#### Description [src]

    class FwupdPlugin.Device : Fwupd.Device
      implements Fwupd.Codec {
      /* No available fields */
    }

A physical or logical device that is exported to the daemon.

See also: `FuDeviceLocker`, `FwupdDevice`.

#### Ancestors

- FwupdDevice
- GObject

#### Descendants

- FuBluezDevice
- FuCfiDevice
- FuEfiX509Device
- FuIntelMeDevice
- FuProcessorDevice
- FuUdevDevice
- FuUefiDevice

#### Implements

- FwupdCodec

#### Constructors

###### fu_device_new

Creates a new `Fudevice`.

since: 1.8.2

#### Functions

###### fu_device_instance_flags_to_string

Converts an enumerated value to a string.

#### Instance methods

###### fu_device_activate

Activates up a device, which normally means the device switches to a new firmware version. This should only be called when data loss cannot occur.

since: 1.2.6

###### fu_device_add_child

Sets any child device. An child device is logically linked to the primary device in some way.

since: 1.0.8

###### fu_device_add_event

Adds an event to the device.

since: 2.0.0

###### fu_device_add_flag

Adds a device flag to the device.

since: 0.1.0

###### fu_device_add_instance_id

Adds an visible, quirked, instance ID to the device.

since: 1.2.5

###### fu_device_add_instance_id_full

Adds an instance ID or GUID with all parameters set.

since: 1.2.9

###### fu_device_add_instance_str

Assign a value for the `key`.

since: 1.7.7

###### fu_device_add_instance_strsafe

Assign a sanitized value for the `key`.

since: 1.7.7

###### fu_device_add_instance_strup

Assign a uppercase value for the `key`.

since: 1.7.7

###### fu_device_add_instance_u16

Assign a value to the `key`, which is padded as `4X`.

since: 1.7.7

###### fu_device_add_instance_u32

Assign a value to the `key`, which is padded as `8X`.

since: 1.7.7

###### fu_device_add_instance_u4

Assign a value to the `key`, which is padded as `1X`.

since: 1.7.7

###### fu_device_add_instance_u8

Assign a value to the `key`, which is padded as `2X`.

since: 1.7.7

###### fu_device_add_json

No description available.

###### fu_device_add_parent_backend_id

Sets any parent device using the physical ID. An parent device is logically linked to the primary device in some way and can be added before or after `self`.

since: 1.9.7

###### fu_device_add_parent_guid

Sets any parent device using a GUID. An parent device is logically linked to the primary device in some way and can be added before or after `self`.

since: 1.0.8

###### fu_device_add_parent_physical_id

Sets any parent device using the physical ID. An parent device is logically linked to the primary device in some way and can be added before or after `self`.

since: 1.6.2

###### fu_device_add_possible_plugin

Adds a plugin name to the list of plugins that might be able to handle this device. This is typically called from a quirk handler.

since: 1.5.1

###### fu_device_add_private_flag

Adds a private flag that can be used by the plugin for any purpose.

since: 1.6.2

###### fu_device_add_problem

Prevent the device from being updated, changing it from `FWUPD_DEVICE_FLAG_UPDATABLE` to `FWUPD_DEVICE_FLAG_UPDATABLE_HIDDEN` if not already inhibited.

since: 1.8.1

###### fu_device_add_security_attrs

Adds HSI security attributes.

since: 1.6.0

###### fu_device_add_string

Add daemon-specific device metadata to an existing string.

since: 1.7.1

###### fu_device_attach

Attaches a device from the bootloader into application mode.

since: 1.0.8

###### fu_device_attach_full

Attaches a device from the bootloader into application mode.

since: 1.7.0

###### fu_device_bind_driver

Binds a driver to the device, which normally means the kernel driver takes control of the hardware.

since: 1.5.0

###### fu_device_build_instance_id

Creates an instance ID from a prefix and some key values. If the key value cannot be found, the parent and then proxy is also queried.

since: 1.7.7

###### fu_device_build_instance_id_full

Creates an instance ID with specific flags from a prefix and some key values. If any of the key values are unset then no instance ID is added.

since: 1.9.8

###### fu_device_build_instance_id_strv

Creates an instance ID from a prefix and an array of key values. If the key value cannot be found, the parent and then proxy is also queried.

since: 2.0.14

###### fu_device_build_vendor_id

Builds a device vendor ID, if `value` is not `NULL`.

since: 2.0.0

###### fu_device_build_vendor_id_u16

Builds a device vendor ID, if `value` is not 0.

since: 2.0.0

###### fu_device_check_fwupd_version

Checks the fwupd version that created the emulation.

since: 2.0.13

###### fu_device_cleanup

Cleans up a device after an update. A different plugin can handle each of FuDevice->write_firmware(), FuDevice->attach() and FuDevice->cleanup().

since: 1.3.3

###### fu_device_clear_events

Clears all the `FuDeviceEvent` objects added with fu_device_add_event(), typically after saving the device to an emulation.

since: 2.0.0

###### fu_device_close

Closes a device, optionally running a object-specific vfunc.

since: 1.1.2

###### fu_device_convert_instance_ids

Converts all the Device instance IDs added using `fu_device_add_instance_id()` into actual GUIDs, unless `FU_DEVICE_PRIVATE_FLAG_NO_AUTO_INSTANCE_IDS` has been set.

since: 1.2.5

###### fu_device_convert_version

Converts the integer version to a string version, using the device-specific converter.

since: 2.0.18

###### fu_device_detach

Detaches a device from the application into bootloader mode.

since: 1.0.8

###### fu_device_detach_full

Detaches a device from the application into bootloader mode.

since: 1.7.0

###### fu_device_dump_firmware

Reads the raw firmware image from the device by calling a plugin-specific vfunc. This raw firmware image may contain serial numbers or device-specific configuration but should be a byte-for-byte match compared to using an external SPI programmer.

since: 1.5.0

###### fu_device_emit_request

Emit a request from a plugin to the client.

since: 1.9.8

###### fu_device_ensure_from_component

Ensure all properties from the donor AppStream component as required.

since: 1.8.13

###### fu_device_ensure_from_release

Ensure all properties from the donor AppStream release as required.

since: 2.0.5

###### fu_device_ensure_id

If not already set, generates a device ID with the optional physical and logical IDs.

since: 1.1.2

###### fu_device_from_json

No description available.

###### fu_device_get_acquiesce_delay

Returns the time the daemon should wait for devices to finish hotplugging after the update has completed.

since: 1.8.3

###### fu_device_get_backend

Gets the backend, if set with fu_device_set_backend().

since: 2.0.0

###### fu_device_get_backend_id

Gets the ID set for the device as recognized by the backend. This is typically a Linux sysfs path or USB platform ID. If unset, it also falls back to the physical ID as this may be the same value.

since: 1.5.8

###### fu_device_get_backend_parent

Creates a device parent (of the correct type) using the current backend.

since: 2.0.0

###### fu_device_get_backend_parent_with_subsystem

Creates a device parent (of the correct type) using the current backend for a given device kind.

since: 2.0.0

###### fu_device_get_battery_level

Returns the battery level.

since: 1.5.8

###### fu_device_get_battery_threshold

Returns the battery threshold under which a firmware update cannot be performed.

since: 1.6.0

###### fu_device_get_child_by_logical_id

Gets a child device by the logical ID.

since: 2.0.17

###### fu_device_get_children

Gets any child devices. A child device is logically “below” the current device and this may be reflected in client tools.

since: 1.0.8

###### fu_device_get_contents

Reads a blob of ASCII text from the file, emulating if required.

since: 2.0.12

###### fu_device_get_contents_bytes

Reads a blob of data from the file, emulating if required.

since: 2.0.2

###### fu_device_get_context

Gets the context assigned for this device.

since: 1.6.0

###### fu_device_get_counterpart_guids

Returns all the counterpart GUIDs.

since: 1.9.21

###### fu_device_get_created_usec

Gets when the device was created.

since: 2.0.0

###### fu_device_get_custom_flags

Gets the custom flags for the device from the quirk system.

since: 1.1.0

###### fu_device_get_equivalent_id

Gets any equivalent ID for a device.

since: 0.6.1

###### fu_device_get_events

Gets all the `FuDeviceEvent` objects added with fu_device_add_event().

since: 2.0.0

###### fu_device_get_firmware_gtype

Gets the default firmware type for the device.

since: 1.7.2

###### fu_device_get_firmware_size_max

Gets the maximum size of the firmware blob.

since: 1.2.6

###### fu_device_get_firmware_size_min

Gets the minimum size of the firmware blob.

since: 1.2.6

###### fu_device_get_id_display

This gets the device ID suffixed with the name if set.

since: 2.0.17

###### fu_device_get_instance_str

Looks up an instance ID by a key.

since: 1.8.15

###### fu_device_get_logical_id

Gets the logical ID set for the device, which disambiguates devices with the same physical ID.

since: 1.1.2

###### fu_device_get_metadata

Gets an item of metadata from the device.

since: 0.1.0

###### fu_device_get_metadata_boolean

Gets an item of metadata from the device.

since: 0.9.7

###### fu_device_get_metadata_integer

Gets an item of metadata from the device.

since: 0.9.7

###### fu_device_get_modified_usec

Gets when the device was modified.

since: 2.0.0

###### fu_device_get_order

Gets the device order, where higher numbers are installed after lower numbers.

since: 1.0.8

###### fu_device_get_parent

Gets any parent device. An parent device is logically “above” the current device and this may be reflected in client tools.

since: 2.0.18

###### fu_device_get_parent_backend_ids

Gets any parent device IDs. If a device is added to the daemon that matches the physical ID added from `fu_device_add_parent_backend_id()` then this device is marked the parent of `self`.

since: 1.9.7

###### fu_device_get_parent_guids

Gets any parent device GUIDs. If a device is added to the daemon that matches any GUIDs added from `fu_device_add_parent_guid()` then this device is marked the parent of `self`.

since: 1.0.8

###### fu_device_get_parent_internal

No description available.

###### fu_device_get_parent_physical_ids

Gets any parent device IDs. If a device is added to the daemon that matches the physical ID added from `fu_device_add_parent_physical_id()` then this device is marked the parent of `self`.

since: 1.6.2

###### fu_device_get_physical_id

Gets the physical ID set for the device, which represents the electrical connection used to compare devices.

since: 1.1.2

###### fu_device_get_pid

Gets the device product code.

since: 2.0.0

###### fu_device_get_possible_plugins

Gets the list of possible plugin names, typically added from quirk files.

since: 1.3.3

###### fu_device_get_priority

Gets the device priority, where higher numbers are better.

since: 1.1.1

###### fu_device_get_proxy

Gets any proxy device. A proxy device can be used to perform an action on behalf of another device, for instance attach()ing it after a successful update.

since: 2.0.18

###### fu_device_get_proxy_gtype

Gets the specialized type of the device.

since: 1.9.15

###### fu_device_get_proxy_guid

Gets the proxy GUID device, which is set to let the engine match up the proxy between plugins.

since: 1.4.1

###### fu_device_get_proxy_internal

No description available.

###### fu_device_get_proxy_with_fallback

Gets the proxy device if `FU_DEVICE_PRIVATE_FLAG_USE_PROXY_FALLBACK` is set, falling back to the device itself.

since: 1.6.2

###### fu_device_get_remove_delay

Returns the maximum delay expected when replugging the device going into bootloader mode.

since: 1.0.2

###### fu_device_get_request_cnt

Returns the number of requests of a specific kind. This function is only useful to the daemon, which uses it to synthesize artificial events for plugins not yet ported to `FwupdRequest`.

since: 1.6.2

###### fu_device_get_required_free

Returns the required amount of free firmware space.

since: 2.0.12

###### fu_device_get_results

Gets the results of the last update operation on the device by calling a vfunc.

since: 1.6.2

###### fu_device_get_root

Gets the root parent device. A parent device is logically “above” the current device and this may be reflected in client tools.

since: 1.4.0

###### fu_device_get_smbios_string

Gets a hardware SMBIOS string.

since: 2.0.10

###### fu_device_get_specialized_gtype

Gets the specialized type of the device.

since: 1.3.3

###### fu_device_get_update_image

Gets the update image URL.

since: 2.0.0

###### fu_device_get_update_message

Gets the update message string.

since: 2.0.0

###### fu_device_get_update_request_id

Gets the update request ID as specified from `LVFS::UpdateRequestId`.

since: 1.8.6

###### fu_device_get_vid

Gets the device vendor code.

since: 2.0.0

###### fu_device_has_guid

Finds out if the device has a specific GUID.

since: 1.2.2

###### fu_device_has_inhibit

Check if the device already has an inhibit with a specific ID.

since: 1.8.0

###### fu_device_has_instance_id

Finds out if the device has this specific instance ID.

since: 2.0.4

###### fu_device_has_parent_backend_id

Searches the list of parent IDs for a string match.

since: 1.9.7

###### fu_device_has_parent_guid

Searches the list of parent GUIDs for a string match.

since: 1.0.8

###### fu_device_has_parent_physical_id

Searches the list of parent IDs for a string match.

since: 1.6.2

###### fu_device_has_private_flag

Tests for a private flag that can be used by the plugin for any purpose.

since: 1.6.2

###### fu_device_has_private_flag_quark

No description available.

###### fu_device_has_problem

Query if a device has a specific problem.

since: 1.8.11

###### fu_device_incorporate

Copy some properties from the donor object if they have not already been set.

since: 2.0.0

###### fu_device_incorporate_flag

Copy the value of a specific flag from the donor object.

since: 1.3.5

###### fu_device_incorporate_from_proxy

Copy some properties from the proxy object if they have not already been set.

since: 2.1.2

###### fu_device_inhibit

Prevent the device from being updated, changing it from `FWUPD_DEVICE_FLAG_UPDATABLE` to `FWUPD_DEVICE_FLAG_UPDATABLE_HIDDEN` if not already inhibited.

since: 1.6.0

###### fu_device_is_updatable

No description available.

###### fu_device_load_event

Loads a new event with a specific ID from the device.

since: 2.0.0

###### fu_device_open

Opens a device, optionally running a object-specific vfunc.

since: 1.1.2

###### fu_device_poll

Polls a device, typically querying the hardware for status.

since: 1.1.2

###### fu_device_poll_locker_new

Returns a device locker that prevents polling on the device. If there are no open poll lockers then the poll callback will be called.

since: 1.8.1

###### fu_device_prepare

Prepares a device for update. A different plugin can handle each of FuDevice->prepare(), FuDevice->detach() and FuDevice->write_firmware().

since: 1.3.3

###### fu_device_prepare_firmware

Prepares the firmware by calling an optional device-specific vfunc for the device, which can do things like decompressing or parsing of the firmware data.

since: 1.1.2

###### fu_device_probe

Probes a device, setting parameters on the object that does not need the device open or the interface claimed. If the device is not compatible then an error should be returned.

since: 1.1.2

###### fu_device_probe_complete

Tell the device that all probing has finished. This allows it to release any resources that are only valid during coldplug or hotplug.

since: 1.8.12

###### fu_device_probe_invalidate

Normally when calling `fu_device_probe()` multiple times it is only done once. Calling this method causes the next requests to `fu_device_probe()` and `fu_device_setup()` actually probe the hardware.

since: 1.1.2

###### fu_device_query_file_exists

Checks if a file exists.

since: 2.0.2

###### fu_device_read_firmware

Reads firmware from the device by calling a plugin-specific vfunc. The device subclass should try to ensure the firmware does not contain any serial numbers or user-configuration values and can be used to calculate the device checksum.

since: 2.0.11

###### fu_device_register_private_flag

Registers a private device flag so that it can be set from quirk files and printed correctly in debug output.

since: 2.0.0

###### fu_device_reload

Reloads a device that has just gone from bootloader into application mode.

since: 1.3.3

###### fu_device_remove_child

Removes child device.

since: 1.6.2

###### fu_device_remove_children

Removes all child devices.

since: 2.0.0

###### fu_device_remove_flag

Removes a device flag from the device.

since: 1.6.0

###### fu_device_remove_metadata

Removes an item of metadata on the device.

since: 1.3.3

###### fu_device_remove_possible_plugin

Removes a plugin name to the list of plugins that might be able to handle this device. This is typically called from a quirk handler.

since: 2.0.18

###### fu_device_remove_private_flag

Removes a private flag that can be used by the plugin for any purpose.

since: 1.6.2

###### fu_device_remove_problem

Allow the device from being updated if there are no other inhibitors, changing it from `FWUPD_DEVICE_FLAG_UPDATABLE_HIDDEN` to `FWUPD_DEVICE_FLAG_UPDATABLE`.

since: 1.8.1

###### fu_device_replace

Copy properties from the old (no-longer-connected) device to the new (connected) device.

since: 1.9.2

###### fu_device_report_metadata_post

Collects metadata that would be useful for debugging a failed update report.

since: 1.5.0

###### fu_device_report_metadata_pre

Collects metadata that would be useful for debugging a failed update report.

since: 1.5.0

###### fu_device_rescan

Rescans a device, re-adding GUIDs or flags based on some hardware change.

since: 1.3.1

###### fu_device_retry

Calls a specific function a number of times, optionally handling the error with a reset action.

since: 1.4.0

###### fu_device_retry_add_recovery

Sets the optional function to be called when `fu_device_retry()` fails, which is possibly a device reset.

since: 1.4.0

###### fu_device_retry_full

Calls a specific function a number of times, optionally handling the error with a reset action.

since: 1.5.5

###### fu_device_retry_set_delay

Sets the recovery delay between failed retries.

since: 1.4.0

###### fu_device_save_event

Creates a new event with a specific ID and adds it to the device.

since: 2.0.0

###### fu_device_security_attr_new

Creates a new `FwupdSecurityAttr` for this specific device.

since: 1.8.4

###### fu_device_set_acquiesce_delay

Sets the time the daemon should wait for devices to finish hotplugging after the update has completed.

since: 1.8.3

###### fu_device_set_backend

Sets the backend that created this device.

since: 2.0.0

###### fu_device_set_backend_id

Sets the backend ID on the device. This is designed to disambiguate devices with the same physical ID. This is typically a Linux sysfs path or USB platform ID.

since: 1.5.8

###### fu_device_set_battery_level

Sets the battery level, or `FWUPD_BATTERY_LEVEL_INVALID`.

since: 1.5.8

###### fu_device_set_battery_threshold

Sets the battery level, or `FWUPD_BATTERY_LEVEL_INVALID` for the default.

since: 1.6.0

###### fu_device_set_contents

Writes `stream` to `filename`, emulating if required.

since: 2.0.2

###### fu_device_set_contents_bytes

Writes `blob` to `filename`, emulating if required.

since: 2.0.2

###### fu_device_set_context

Sets the optional context which may be useful to this device. This is typically set after the device has been created, but before the device has been opened or probed.

since: 1.6.0

###### fu_device_set_created_usec

Sets when the device was created.

since: 2.0.0

###### fu_device_set_custom_flags

Sets the custom flags from the quirk system that can be used to affect device matching. The actual string format is defined by the plugin.

since: 1.1.0

###### fu_device_set_equivalent_id

Sets any equivalent ID for a device.

since: 0.6.1

###### fu_device_set_firmware_gtype

Sets the default firmware type for the device.

since: 1.7.2

###### fu_device_set_firmware_size

Sets the exact allowed size of the firmware blob.

since: 1.2.6

###### fu_device_set_firmware_size_max

Sets the maximum allowed size of the firmware blob.

since: 1.1.2

###### fu_device_set_firmware_size_min

Sets the minimum allowed size of the firmware blob.

since: 1.1.2

###### fu_device_set_fwupd_version

Sets the fwupd version that created the emulation.

since: 2.0.8

###### fu_device_set_id

Sets the ID on the device. The ID should represent the connection of the device, so that any similar device plugged into a different slot will have a different `id` string.

since: 0.7.1

###### fu_device_set_logical_id

Sets the logical ID on the device. This is designed to disambiguate devices with the same physical ID.

since: 1.1.2

###### fu_device_set_metadata

Sets an item of metadata on the device.

since: 0.1.0

###### fu_device_set_metadata_boolean

Sets an item of metadata on the device. When `value` is set to `TRUE` the actual stored value is `true`.

since: 0.9.7

###### fu_device_set_metadata_integer

Sets an item of metadata on the device. The integer is stored as a base-10 string internally.

since: 0.9.7

###### fu_device_set_modified_usec

Sets when the device was modified.

since: 2.0.0

###### fu_device_set_name

Sets the name on the device. Any invalid parts will be converted or removed.

since: 0.7.1

###### fu_device_set_order

Sets the device order, where higher numbers are installed after lower numbers.

since: 1.0.8

###### fu_device_set_parent

Sets any parent device. An parent device is logically “above” the current device and this may be reflected in client tools.

since: 1.0.8

###### fu_device_set_physical_id

Sets the physical ID on the device which represents the electrical connection of the device to the system. Multiple `FuDevices` can share a physical ID.

since: 1.1.2

###### fu_device_set_pid

Sets the product ID.

since: 2.0.0

###### fu_device_set_poll_interval

Polls the hardware every interval period. If the subclassed `->poll()` method returns `FALSE` then a warning is printed to the console and the poll is disabled until the next call to fu_device_set_poll_interval().

since: 1.1.2

###### fu_device_set_priority

Sets the device priority, where higher numbers are better.

since: 1.1.1

###### fu_device_set_progress

Sets steps on the progress object used to write firmware.

since: 1.7.0

###### fu_device_set_proxy

Sets any proxy device. A proxy device can be used to perform an action on behalf of another device, for instance attach()ing it after a successful update.

since: 1.4.1

###### fu_device_set_proxy_gtype

Sets the specialized type of the device.

since: 1.9.15

###### fu_device_set_proxy_guid

Sets the GUID of the proxy device. The proxy device may update `self`.

since: 1.4.1

###### fu_device_set_quirk_kv

Sets a specific quirk on the device.

since: 2.0.2

###### fu_device_set_remove_delay

Sets the amount of time a device is allowed to return in bootloader mode.

since: 1.0.2

###### fu_device_set_required_free

Sets the required amount of free firmware size.

since: 2.0.12

###### fu_device_set_specialized_gtype

Sets the specialized type of the device.

since: 2.0.0

###### fu_device_set_target

Sets the target device where `FuDeviceEvent` objects added to `self` should actually be added.

since: 2.0.0

###### fu_device_set_update_image

Sets the update image URL.

since: 2.0.0

###### fu_device_set_update_message

Sets the update message string.

since: 2.0.0

###### fu_device_set_update_request_id

Sets the update request ID as specified in `LVFS::UpdateRequestId`.

since: 1.8.6

###### fu_device_set_update_state

Sets the update state, clearing the update error as required.

since: 1.6.2

###### fu_device_set_vendor

Sets the vendor name on the device.

since: 1.6.2

###### fu_device_set_version

Sets the device version, sanitizing the string if required.

since: 1.2.9

###### fu_device_set_version_bootloader

Sets the device bootloader version, sanitizing the string if required.

since: 1.4.0

###### fu_device_set_version_format

Sets the device version format.

since: 1.4.0

###### fu_device_set_version_highest

Sets the highest allowed device version, sanitizing the string if required.

since: 2.1.2

###### fu_device_set_version_highest_raw

Sets the raw highest device version from an integer value and the device version format.

since: 2.1.2

###### fu_device_set_version_lowest

Sets the device lowest version, sanitizing the string if required.

since: 1.4.0

###### fu_device_set_version_lowest_raw

Sets the raw device version from a integer value and the device version format.

since: 2.0.7

###### fu_device_set_version_raw

Sets the raw device version from a integer value and the device version format.

since: 1.9.8

###### fu_device_set_vid

Sets the vendor ID.

since: 2.0.0

###### fu_device_setup

Sets up a device, setting parameters on the object that requires the device to be open and have the interface claimed. If the device is not compatible then an error should be returned.

since: 1.1.2

###### fu_device_sleep

Delays program execution up to 100 seconds, unless the device is emulated where no delays is performed.

since: 1.8.11

###### fu_device_sleep_full

Delays program execution up to 1000 seconds, unless the device is emulated where no delays is performed.

since: 1.8.11

###### fu_device_to_string

This allows us to easily print the device, the release and the daemon-specific metadata.

since: 0.9.8

###### fu_device_unbind_driver

Unbinds the driver from the device, which normally means the kernel releases the hardware so it can be used from userspace.

since: 1.5.0

###### fu_device_uninhibit

Allow the device from being updated if there are no other inhibitors, changing it from `FWUPD_DEVICE_FLAG_UPDATABLE_HIDDEN` to `FWUPD_DEVICE_FLAG_UPDATABLE`.

since: 1.6.0

###### fu_device_write_firmware

Writes firmware to the device by calling a plugin-specific vfunc.

since: 2.0.7

##### Methods inherited from FwupdDevice (109)

Please see FwupdDevice for a full list of methods.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

##### Methods inherited from FwupdCodec (8)

###### fwupd_codec_add_string

Converts an object that implements `FwupdCodec` to a debug string, appending it to `str`.

###### fwupd_codec_from_json

Converts an object that implements `FwupdCodec` from a JSON object.

###### fwupd_codec_from_json_string

Converts an object that implements `FwupdCodec` from a JSON string.

###### fwupd_codec_from_variant

Converts an object that implements `FwupdCodec` from a `GVariant` value.

###### fwupd_codec_to_json

Converts an object that implements `FwupdCodec` to a JSON builder object.

###### fwupd_codec_to_json_string

Converts an object that implements `FwupdCodec` to a JSON string.

###### fwupd_codec_to_string

Converts an object that implements `FwupdCodec` to a debug string.

###### fwupd_codec_to_variant

Converts an object that implements `FwupdCodec` to a `GVariant`.

#### Properties

###### FwupdPlugin.Device:backend

The `FuBackend` that created the device.

since: 2.0.0

###### FwupdPlugin.Device:backend-id

The device backend ID.

since: 1.5.8

###### FwupdPlugin.Device:context

The `FuContext` to use.

since: 1.6.0

###### FwupdPlugin.Device:equivalent-id

The device equivalent ID.

since: 2.0.0

###### FwupdPlugin.Device:logical-id

The device logical ID.

since: 1.1.2

###### FwupdPlugin.Device:parent

The device parent.

since: 1.0.8

###### FwupdPlugin.Device:physical-id

The device physical ID.

since: 1.1.2

###### FwupdPlugin.Device:pid

The device product ID.

since: 2.0.0

###### FwupdPlugin.Device:private-flags

The device private flags.

since: 1.9.1

###### FwupdPlugin.Device:proxy

The device proxy to use.

since: 1.4.1

###### FwupdPlugin.Device:required-free

The required amount of free firmware space.

since: 2.0.12

###### FwupdPlugin.Device:update-image

The update image for the device.

since: 2.0.0

###### FwupdPlugin.Device:update-message

The device update message.

since: 2.0.0

###### FwupdPlugin.Device:vid

The device vendor ID.

since: 2.0.0

##### Properties inherited from FwupdDevice (14)

###### Fwupd.Device:battery-level

The device battery level in percent.

###### Fwupd.Device:battery-threshold

The device battery threshold in percent.

###### Fwupd.Device:flags

The device flags.

###### Fwupd.Device:id

The device ID.

###### Fwupd.Device:parent

The device parent.

###### Fwupd.Device:percentage

The current device percentage.

###### Fwupd.Device:problems

The problems with the device that the user could fix, e.g. “lid open”.

###### Fwupd.Device:request-flags

The device request flags.

###### Fwupd.Device:status

The current device status.

###### Fwupd.Device:update-error

The device update error.

###### Fwupd.Device:update-state

The device update state.

###### Fwupd.Device:vendor

The device vendor.

###### Fwupd.Device:version

The device version.

###### Fwupd.Device:version-format

The version format of the device.

#### Signals

###### FwupdPlugin.Device::child-added

The ::child-added signal is emitted when a device has been added as a child.

since: 1.0.8

###### FwupdPlugin.Device::child-removed

The ::child-removed signal is emitted when a device has been removed as a child.

since: 1.0.8

###### FwupdPlugin.Device::request

The ::request signal is emitted when the device needs interactive action from the user.

since: 1.6.2

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct FwupdPluginDeviceClass {
      FwupdDeviceClass parent_class;

    }

No description available.

###### Class members

`parent_class: FwupdDeviceClass`

  No description available.