Download Print this page

Parallax 27808 Quick Start Manual page 7

Gimbal joystick with adapter

Advertisement

RCTIME Circuit
Lacking an analog-to-digital converter, it is still possible to measure the joystick position by timing the
discharge of a capacitor. Here's the circuit, which is applicable to the BASIC Stamp family of products:
Horizontal 5K Pot
Vertical 5K Pot
Quad-Bearing Gimbal Joystick
To measure each wiper position, the attached microcontroller will charge that wiper's capacitor by
outputting a high on the associated pin. Then it will tri-state the pin and let the cap discharge through
the potentiometer to ground and time how long it takes for the voltage to go below the micro's input
logic threshold. The higher the resistance being measured, the longer the discharge time will be.
BASIC Stamp Example
The wiring diagram below is compatible with the BASIC Stamp Board of Education or HomeWork Board.
Connect the joystick, the two resistors, and the two capacitors to the breadboard as shown below.
Copyright © Parallax Inc.
BLK
BLU
YEL
ORG
BRN
GRN
Gimbal Joystick with Adapter (#27808)
220R
Horizontal
0.1uF
220R
Vertical
0.1uF
v1.2 11/13/2019 Page 7 of 9

Advertisement

loading