Component: Joystick (Sparkfun Quiic) 2D (Analog Input): Difference between revisions
Appearance
m Text replacement - "class="wikitable" style="width:60%; background-color:#FFFFFF;"" to "class="mtx-class-macrotable wikitable"" |
m Text replacement - "style="background-color:#EAE1EA;"" to "class="mtx-class-propfolder"" |
||
| (4 intermediate revisions by the same user not shown) | |||
| Line 66: | Line 66: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''ChangeI2CAddress''' | ||
|- | |- | ||
| colspan="2" | Allows the I2C Device address to be changed which in turn allows more then one RFID reader to sit on the same physical I2C bus. Returns 1 if succesful. | | colspan="2" | Allows the I2C Device address to be changed which in turn allows more then one RFID reader to sit on the same physical I2C bus. Returns 1 if succesful. | ||
| Line 85: | Line 85: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''CheckButton''' | ||
|- | |- | ||
| colspan="2" | Checks to see if the button has been pressed since the last read of CheckButton or ReadButton. | | colspan="2" | Checks to see if the button has been pressed since the last read of CheckButton or ReadButton. | ||
| Line 99: | Line 99: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Initialise''' | ||
|- | |- | ||
| colspan="2" | Initialises the I2C bus ready for communications with the module. | | colspan="2" | Initialises the I2C bus ready for communications with the module. | ||
| Line 113: | Line 113: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''ReadAxis''' | ||
|- | |- | ||
| colspan="2" | Reads a single axis of the joystick and returns as a signed integer value. | | colspan="2" | Reads a single axis of the joystick and returns as a signed integer value. | ||
| Line 137: | Line 137: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''ReadButton''' | ||
|- | |- | ||
| colspan="2" | Checks to see if the button is currently pressed | | colspan="2" | Checks to see if the button is currently pressed | ||
| Line 151: | Line 151: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''SimMoveThumbStick''' | ||
|- | |- | ||
| colspan="2" | | | colspan="2" | | ||
| Line 181: | Line 181: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-prop-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Properties''' | ||
|- | |- | ||
|- | |- | ||
| Line 190: | Line 190: | ||
| colspan="2" | Decides if the joystick automatically returns to the center position when released. Yes: The joystick will return to the center when released. No: The joystick will remain in the current position when released. | | colspan="2" | Decides if the joystick automatically returns to the center position when released. Yes: The joystick will return to the center when released. No: The joystick will remain in the current position when released. | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Limits | ||
|- | |- | ||
|- | |- | ||
| Line 209: | Line 209: | ||
| colspan="2" | | | colspan="2" | | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Theme | ||
|- | |- | ||
|- | |- | ||
| Line 238: | Line 238: | ||
| colspan="2" | Outline line style | | colspan="2" | Outline line style | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Connections | ||
|- | |- | ||
|- | |- | ||
| Line 277: | Line 277: | ||
| colspan="2" | On older microcontroller devices there is a potential for the I2C hardware channel to lock up if there is not a 10ms delay between an I2C stop event and the next I2C start event. Most modern microcontrollers will not have a problem so this property can be disabled to speed up the I2C communications. | | colspan="2" | On older microcontroller devices there is a potential for the I2C hardware channel to lock up if there is not a 10ms delay between an I2C stop event and the next I2C start event. Most modern microcontrollers will not have a problem so this property can be disabled to speed up the I2C communications. | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Simulation | ||
|- | |- | ||
|- | |- | ||
Latest revision as of 14:37, 13 July 2026
| Author | Matrix TSL |
| Version | 10.0 |
| Category | Analog Input |
Joystick (Sparkfun Quiic) 2D component
An XY sprung joystick with click switch allowing for easy user input control. Connected using I2C bus.
Version information
Library Version, Component Version, Date, Author, Info 10, 10.0, 04-12-24, MW,Icon edited so compatible with dark theme
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
ChangeI2CAddress
CheckButton
| CheckButton | |
| Checks to see if the button has been pressed since the last read of CheckButton or ReadButton. | |
| Return | |
Initialise
| Initialise | |
| Initialises the I2C bus ready for communications with the module. | |
| Return | |
ReadAxis
| ReadAxis | |
| Reads a single axis of the joystick and returns as a signed integer value. | |
| Axis | |
| Range 0-1 Where 0=X, 1=Y | |
| Type | |
| 0 = Signed (-512 to 511), 1 = Unsigned (0 to 1023) | |
| Return | |
ReadButton
| ReadButton | |
| Checks to see if the button is currently pressed | |
| Return | |
SimMoveThumbStick
| SimMoveThumbStick | |
| X | |
| Y | |
| Component | |
| Return | |
Property reference
Component Source Code
Please click here to download the component source project: FC_Comp_Source_Sparkfun_Quiic_Joystick_2dgi.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_Sparkfun_Quiic_Joystick_2dgi.fcfx