Skip to main content

Meadow.Foundation.Sensors.Hid.DigitalJoystick

DigitalJoystick
StatusStatus badge: working
Source codeGitHub
NuGet packageNuGet Gallery for Meadow.Foundation

Class DigitalJoystick

Represents a 4 switch digital joystick / directional pad (D-pad)

Assembly: Meadow.Foundation.dll
View Source
Declaration
public class DigitalJoystick : IDigitalJoystick, IDisposable

Implements:
Meadow.Peripherals.Sensors.Hid.IDigitalJoystick, System.IDisposable

Properties

Position

Get the current digital joystick position

View Source
Declaration
public DigitalJoystickPosition? Position { get; protected set; }

ButtonUp

The PushButton class for the up digital joystick switch

View Source
Declaration
public PushButton ButtonUp { get; protected set; }

ButtonDown

The PushButton class for the down digital joystick switch

View Source
Declaration
public PushButton ButtonDown { get; protected set; }

ButtonLeft

The PushButton class for the left digital joystick switch

View Source
Declaration
public PushButton ButtonLeft { get; protected set; }

ButtonRight

The PushButton class for the right digital joystick switch

View Source
Declaration
public PushButton ButtonRight { get; protected set; }

IsDisposed

Is the object disposed

View Source
Declaration
public bool IsDisposed { get; }

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

View Source
Declaration
public void Dispose()

Dispose(bool)

Dispose of the object

View Source
Declaration
protected virtual void Dispose(bool disposing)
Parameters
TypeNameDescription
System.BooleandisposingIs disposing

Events

Updated

Raised when the digital joystick position changes

View Source
Declaration
public event EventHandler<ChangeResult<DigitalJoystickPosition>> Updated
Event Type

System.EventHandler<Meadow.ChangeResult<Meadow.Peripherals.Sensors.Hid.DigitalJoystickPosition>>

Implements

  • Meadow.Peripherals.Sensors.Hid.IDigitalJoystick
  • System.IDisposable