Skip to content

Releases: SludgePhD/evdevil

v0.5.0

18 Jun 21:39

Choose a tag to compare

Breaking Changes

  • EffectKind no longer implements Eq.
  • Effect::kind() now returns EffectKind instead of Option<EffectKind>.
  • ForceFeedbackEvent::code() now returns ForceFeedbackCode instead of Option<ForceFeedbackCode>.
  • EventKind::Other has been renamed and hidden, and is no longer part of the public API.
  • UnknownVariant error type is now called ParseVariantError.
    • The From<UnknownVariant> for io::Error implementation has been removed.
  • Effect::direction() now uses a Direction wrapper type.
  • The log functionality is now hidden behind a "log" Cargo feature (enabled by default).
  • Evdev::set_X_mask now accepts an impl IntoIterator argument rather than a &BitSet<V>.
  • Previously deprecated APIs have been removed.

Other Changes

  • Condition-based force-feedback effects (Spring, Friction, …) now have explicit constructors
    in addition to the From implementations.
  • Added new Bus and InputProp constants from upstream.

v0.4.6

17 Jun 23:17

Choose a tag to compare

Fixes

  • Fix the return value of BitSet::insert to match the documentation.
  • Make validation of values to be inserted into a BitSet less strict, to permit the same set of
    BitSets that the kernel will produce.

v0.4.5

17 Jun 16:59

Choose a tag to compare

Deprecations

  • The Evdev::write method was deprecated in favor of a new Evdev::write_events method, to align the naming with read_events.
    • Similar deprecations have been performed for other types.

Other Changes

  • No longer map ENODEV to ErrorKind::NotFound when opening an Evdev (instead of ErrorKind::Uncategorized).
    • This reverts a change was previously introduced in v0.4.3.
    • Users of Evdev::open already had to handle ENODEV regardless of this mapping,
      so nothing changes for correct applications.
      Both types of errors were possible before, and remain possible after the change.

v0.4.4

16 Jun 20:15

Choose a tag to compare

Improvements

  • Add new event codes from upstream.
  • Depend on serde_core instead of serde when the "serde" feature is enabled.
  • Don't report ENODEV errors to callers when enumerating devices that disappeared.
  • Document the possible error types when opening a device.

v0.4.3

03 May 13:38

Choose a tag to compare

Improvements

  • Add EffectId::{from_raw, raw} to allow conversion from/to raw integers.
  • Map ENODEV to ErrorKind::NotFound when opening an Evdev (instead of ErrorKind::Uncategorized).

v0.4.2

03 May 10:21

Choose a tag to compare

Improvements

  • Add UinputDevice::async_events for asynchronously reading from a uinput device.
  • Add UinputDevice::read_events to mirror Evdev::read_events.
  • Minor documentation improvements.

v0.4.1

20 Apr 22:36

Choose a tag to compare

Fixes

  • Don't clamp the value of absolute axes in EventReader.
    • This fixes usage with certain drivers that deliberately send out-of-range axis values.

v0.4.0

11 Jan 19:20

Choose a tag to compare

Breaking Changes

  • Removed FromRawFd implementation of UinputDevice.
    • Replaced with UinputDevice::from_owned_fd.
  • Removed Evdev::path (Evdev no longer stores the path it was opened from).
    • enumerate and enumerate_hotplug now yield (PathBuf, Evdev).
  • Removed all MAX and CNT constants from event code types.
  • Shortened lifetime of Effects returned by ForceFeedbackUpload to be tied to &self.
  • Remove all name methods from event code types.
    • Codes can instead be formatted via Debug or serialized with serde to obtain the name.
  • Removed all deprecated functionality.

Improvements

  • Added raw and from_raw functions to all types that wrap an integer and didn't already have them.
  • Added Switch::USB_INSERT.
  • Yield paths alongside devices when enumerating.
  • Document more clearly that new enumeration constants can be added in minor releases.
  • Document the evdev device lifecycle.
  • Add a few missing setters to force-feedback types.
  • EventReader::valid_slots now returns a real iterator type instead of impl Iterator.

Fixes

  • Limit number of reports processed by EventReader::update, to prevent getting stuck in there forever.
  • Made enumerate_hotplug() more robust, avoiding duplicate devices.
  • Don't wrap ENODEV in a custom error, making it easier to detect unplugged devices.

v0.3.5

08 Dec 13:48

Choose a tag to compare

Fixes

  • Fix a panic in examples/keymap.rs.
  • Fix all-zero Scancodes being printed as the empty string.

Improvements

  • Include the /dev/uinput path in the io::Error when opening the device fails.
  • Run the unit tests on Big Endian emulation in CI.

v0.3.4

07 Dec 04:25

Choose a tag to compare

Improvements

  • Add a few missing getters for force-feedback types.
  • Derive PartialOrd and Ord for EffectId.
  • Rename with_device_id to with_input_id (with deprecation).
  • Rename the ForceFeedbackEvent constructors to more evocative names (with deprecation).
  • Add #[inline] to more functions.

Fixes

  • Fix a bug where uninitialized bytes would be unsoundly reinterpreted as &[u8] when reading events from a UinputDevice.
  • Fix the PartialEq implementation of Periodic not comparing custom waveform data.

Other changes

  • Improved documentation a bit.
  • Deduplicated the internal implementation so that all event I/O happens in two root functions.
  • Audited the crate for Undefined Behavior.
  • Run CI on aarch64 Linux (GNU and musl).
  • Add the crate to the os::freebsd-apis category on crates.io.