13. Joystick:bit V2

13.1. Introduction


Joystick:bit V2 is a JoyStick based on micro:bit. It contains a 4-direction joystick and 4 undefined buttons as as classic JoyStick. At the same time, with the board buzzer and vibration motor, it also enhance game experience. Joystick:bit V2 can be remote control handle for micro:bit which on compact appearance and comfortable touch.

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_01.jpg

13.2. Packing List


1 x Joystick:bit v2

13.3. Features


  • Develop Environment:Javascript / Makecode / Microsoft Touch Develop / Python.

  • With buzzer.

  • Vibration feedback for better game experience.

  • Add makecode package, simple for software.

  • Automatically power outage while micro:bit is pulled out.

  • Lead out 7 IO ports of micro:bit board.

13.4. Appearance & location dimension


https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_02.png

13.5. Function module introduction


Joystick

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_03.png

Connect X & Y of joystick to P1 & P2 of micro:bit.

Buzzer

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_04.png

The buzzer is a passive buzzer which is connect to P0 of micro:bit.

Vibration motor

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_05.png

The vibration motor is connect to P16 of micro:bit.

Buttons

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_06.png

The four buttons C&D&E&F are respectively connect to P12&P13&P14&P15 of micro:bit.

7 GVS ports

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_07.png

It contains 7 GVS extension ports which could be soldered pin head and master more extension possibilities.

13.6. Let’s do it


Install

Install two 3A batteries to game:bit and insert the micro:bit.

Add joystick:bit package

Go ahead makecode and add new project, click on Extensions.

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_08.png

Search joystickbit and add joystick:bit package.

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_09.png https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_10.png

13.7. Program


Make your code. Ever once you press buttons of your joystick:bit, it comes about vibration feedback with buttons sign showing.

https://raw.githubusercontent.com/elecfreaks/learn-en/master/microbitExtensionModule/images/joystick_v2_11.png

Click the link here to see the whole program: https://makecode.microbit.org/_AD3P71UrTCA1

You can also download it from the page below:

When download is finished, turn on the power switch and you will hear system sound.

Push button C, the game:bit will vibrate once. Push button D, the game:bit will vibrate once. Push button E, the game:bit will vibrate once. Push button F, the game:bit will vibrate once.

13.8. More Information


For more details, please log on: http://www.elecfreaks.com.