Working with Analog joysticks in IoAbstraction

By dave on May 21, 2021

IoAbstraction fully supports analog joysticks, and it does so in many modes, you can use them in three ways: You can get the values of the joystick using an AnalogDevice directly. This is the simplest case and you would read the present floating point value as needed. You can treat an axis of the joystick as a rotary encoder, and either use it to track a range of values, or in direction only mode.

Working with Analog input events in IoAbstraction

By dave on December 2, 2020

IoAbstraction has a class named AnalogInEvent to support event based programming for Analog Inputs, it is based on the BaseEvent class within the base library TaskManagerIO. The class itself is very flexible and can work with both polling and interrupt based approaches, or even a hybrid of the two. If you are not familiar with events, I recommend reading about them in the above TaskManagerIO link. You can see the reference guide for analog event here.

IoAbstraction Analog Core documentation

By dave on August 15, 2019

IoAbstraction has a simple interface to the analog capabilities of all supported boards. It provides frequently used functionality around acquiring and setting analog values from ADC, PWM and DACs. Having the ability to read and write analog values as float, where the value is between 0 and 1; where 0 is off and 1 is fully on. this capability allows you share code across different Arduino and mbed boards. The base class for this abstraction is AnalogDevice and you can see the full documentation in the reference guide.

tcMenu for Arduino

This site uses cookies to analyse traffic, and to record consent. We also embed Twitter, Youtube and Disqus content on some pages, these companies have their own privacy policies.

Our privacy policy applies to all pages on our site

Should you need further guidance on how to proceed: External link for information about cookie management.

Send a message
X

Please use the forum for help with UI & libraries.

This message will be securely transmitted to our servers.