The library supports both event based (callback mode) and the normal mode. Refer to the examples to find out how to use the library in both the modes.
The library supports the following events
- All 8 directions of Joystick. (Up, RightUp, Right, RightDown, Down, LeftDown, Left and LeftUp)
- Joystick button press
- All 4 button press (Up, Right, Down, Left)
The library has two examples sketches which explains the modes
- SimpleExample – Shows the normal way of using the library
- CallbackExample – Shows how to use the library in callback mode.
You can download the library from my github page. The examples are there inside the /examples folder. After downloading place the JoystickShield folder inside your Arduino’s /library folder
The library and the example are released under released under BeerWare license.
I would, however, consider it a great courtesy if you could email me and tell me about your project and how this code was used, just for my own continued personal gratification
You can also find other ways to make me happy, if you liked this project.
I would be posting updates about this library in my blog and in Twitter. If you want to be informed when new version of this library is released, then you can either subscribe to this blog’s RSS feed or follow me in Twitter.
- 2011-04-08 – v0.1 – Initial version
- 2012-05-19 – v0.2 – Added compatibility for Arduino 1.0