Skip to content

Instantly share code, notes, and snippets.

View fmilburn3's full-sized avatar

Frank Milburn fmilburn3

  • Seattle, Washington USA
View GitHub Profile
@fmilburn3
fmilburn3 / Joystick_demo.ico
Last active August 29, 2015 14:22
Energia two axis joystick with pushbutton demonstration
/*
Read Joystick and Push Button - display result to serial monitor
Tested with the Texas Instruments MSP540F5529LP LaunchPad using Energia
and an Addicore joystick with push button:
https://www.addicore.com/Dual-Axis-XY-Joystick-Module-with-Push-Button-p/139.htm
Note: The pin connections shown below will work with most MSP430 LaunchPads.
The maximum values of xValue and yValue will depend on the Analog Digital
Converter (ADC) - e.g. the F5529 is 12 bit (0 to 4095) while the 430G2
is 10 bit (0 to 1023).