PmodJSTK2 Reference Manual. Overview. 1 Functional Descriptions. Revised July 19, 2016 This manual applies to the PmodJSTK2 rev. C

Similar documents
Pmod modules are powered by the host via the interface s power and ground pins.

Digilent I 2 C Pin Configurations

Pmod I2S2 Reference Manual

Cerebot Nano Reference Manual. Overview. Revised April 15, 2016 This manual applies to the Cerebot Nano rev. A

chipkit Pmod Shield-Uno Reference Manual

PIC Serial Peripheral Interface (SPI) to Digital Pot

3.3V regulator. JA H-bridge. Doc: page 1 of 7

JTAG-HS1 Programming Cable for Xilinx FPGAs. Overview. Revised January 22, 2015

Doc: page 1 of 6

Voltage Regulator Board User Guide

Doc: page 1 of 6

How to create your own peripheral modules for use with the ARC EMSK and embarc

Pmod ESP32 Reference Manual

chipkit Cmod Reference Manual Overview Revised November 6, 2013 This manual applies to REV E of the board.

USB-to-I2C. Professional Hardware User s Manual.

User s Manual iceprogm1050, icecablem100 and SAB-XXXXX-X V 1.2

Doc: page 1 of 8

EXL x240 Graphic LCD Smart Module 3,8 SHORT FORM TECHNICAL SPECIFICATIONS. Via di Corticella, Bologna, Italy

Cmod Board Reference Manual. Overview. 1 Functional Description. Revised October 26, 2012 This manual applies to the Cmod rev. D

output current sink/source 2 ma PIC 16F690 (see datasheet) SPI resolution 12 bit position accuracy 0.2 deg

ESPino - Specifications

Various power connectors. 3.3V regulator. 64K Flash (Internal) 2K EEPROM (Internal) 4K SRAM (Internal) JA Mem Adr/ Data. Doc: page 1 of 9

Revision: May 11, E Main Suite D Pullman, WA (509) Voice and Fax LED. Doc: page 1 of 6

SBAT90USB162 Atmel. SBAT90USB162 Development Board User s Manual

AN10428 UART-SPI Gateway for Philips SPI slave bridges

SBD WARRIOR DATA SHEET

Win-I2CUSB Hardware User s Manual

Doc: page 1 of 9

USB-to-I2C. Ultra Hardware User s Manual.

eip-10 Embedded TCP/IP 10-BaseT Network Module Features Description Applications

Arduino Uno R3 INTRODUCTION

Skywire RL78/Kurumi Adapter User Manual

3.2inch SPI Module MSP3218 User Manual

Microcontroller. BV523 32bit Microcontroller. Product specification. Jun 2011 V0.a. ByVac Page 1 of 8

Arduino Uno. Arduino Uno R3 Front. Arduino Uno R2 Front

BB-303 Manual Baseboard for TMCM-303

chipkit Cmod Reference Manual Overview Revised November 6, 2013 This manual applies to the chipkit Cmod rev. E

EDBG. Description. Programmers and Debuggers USER GUIDE

USER GUIDE EDBG. Description

WICE-SPI Hardware Operation Manual

Wireless Sensor Networks. FireFly 2.2 Datasheet

Modtronix Engineering Modular Electronic Solutions SBC28DC. Single board computer for 28 pin DIP PICs

SPI (Serial & Peripheral Interface)

Revision: 05/05/ E Main Suite D Pullman, WA (509) Voice and Fax. Various power connectors. 3.3V regulator

ArduCAM-M-5MP Camera Shield

USER GUIDE. Atmel OLED1 Xplained Pro. Preface

PICado Alpha Development Board V1.0

Arduino Dock 2. The Hardware

Evaluation Board User Guide UG-047

Technical Documentation

DEVBOARD3 DATASHEET. 10Mbits Ethernet & SD card Development Board PIC18F67J60 MICROCHIP

DIAMEX DIGI-DOT BOOSTER Drivers for WS2812 and SK6812 LEDs with SPI interface

DIGITAL COMPASS SOLUTION

ARDUINO MEGA 2560 REV3 Code: A000067

RN-174. WiFly GSX Super Module. Features. Description. Applications. rn-174-ds v1.1 1/24/2011

IPC. Preliminary Data Brief. IPC High speed phase current sensor with digital interface Draft Review Released

MPU-6000/MPU Axis Evaluation Board User Guide

Datasheet High performance reaction wheel for 6U and 12U nano-satellites

PCI Host Controller 14a Hardware Reference Release 1.2 (October 16, 2017)

Evaluates: MAX MAX31865PMB1 Peripheral Module. General Description. Features and Benefits. Peripheral Module Board Photo

TO OUR VALUED CUSTOMERS

1.6inch SPI Module user manual

BroadR-Reach click PID: MIKROE Weight: 26 g

HMR3200/HMR3300 APPLICATIONS. Features. General Description. Block Diagram. Compassing & Navigation. Attitude Reference. Satellite Antenna Positioning

Note 1: RoHS compliant. Note 2: LCM weight tolerance: ± 5%.

SPI Xpress. Data sheet

Environmental Data Acquisition Using (ENC28J60)

EPT-200TMP-TS-U2 TMP102 Temperature Sensor Docking Board Data Sheet

E6486. User Manual. The New Vision of Touch

ZSSC4151 Evaluation Kit Hardware Manual

Table of Contents 1 Typical Applications General Description Block Diagram Pinout System Connections Typical A

HP07 Digipot Interface Module

HMR3200/HMR3300. Digital Compass Solutions. User s Guide HMR3200/HMR3300 SENSOR PRODUCTS

W25X05CL/10CL/20CL 2.5 / 3 / 3.3 V 512K / 1M / 2M-BIT SERIAL FLASH MEMORY WITH 4KB SECTORS AND DUAL I/O SPI

Mercury System SB310

ARDUINO MEGA ADK REV3 Code: A000069

PIXI click PID: MIKROE Weight: 28 g

Please refer to "4. Evaluation Board" on page 2 for more information about these steps. Figure 1. System Connections

Prototyping Module Datasheet

An SPI interface for the 65(C)02 family of microprocessors

Flex Series User Guide

MAXSANTAFEEVSYS User Manual

Atmel AVR datasheet. Matrix Multimedia Atmel AVR Board EB Contents

PCB-STM32-F3U. Development baseboard for the STMicro Discovery-F3 module (STMicro part# STM32F3DISCOVERY)

AVR Prog-S. Programmer for AVR microcontrollers. User Manual

I2C-IN830M, I2C-IN830MA 8-Input Optocouplers I2C-bus, DIN rail supports

ISPcable II. User s Guaid. Programer for AVR, AT89S and AT90S Atmel microcontrollers with serial interface. REV Beta 1.1. Many ideas one solution

MultiConnect OCG. Break-Out Board. Developer s Guide

ED-22 Analog Output Series Magnetic Encoder

PIC18F452 Oven Calibrator Using the MAX6674/MAX6675 Thermocouple-to-Digital Converter. Group: SMOKE Duston Cline Adam McCorkle

Serial communications with SPI

CB-1 Peripheral Board Technical Manual

TMCM-302 Stepper Motor Motion Control Module

User's Manual Rev. 1. Freescale Semiconductor Inc. TWRS08UNIVUM

chipkit Network Shield Reference Manual Overview Revised February 26, 2016 This manual applies to the chipkit Network Shield rev.

Omega MP. Multi-Programming Shield for Atmel Microcontrollers. User Manual

± 2g Tri-axis Accelerometer Specifications

Freescale Semiconductor Inc. TWR-MCF51CN User Manual Rev. 1.2

2. Hardware Connectivity

SPI Storm. Data sheet

Transcription:

1300 Henley Court Pullman, WA 99163 509.334.6306 www.digilentinc.com PmodJSTK2 Reference Manual Revised July 19, 2016 This manual applies to the PmodJSTK2 rev. C Overview The Digilent PmodJSTK2 (Revision C) is a versatile user input device that can be easily incorporated into a wide variety of projects. With a two-axis joystick on a center button, a trigger button, and a programmable RGB LED capable of 24-bit color. Features include: Factory Calibrated Two Axis Resistive Joystick Center Joystick Button Trigger Style Push Button 24-bit RGB LED 6-pin Pmod connector with SPI interface Library and example code available in resource center The PmodJSTK2. 1 Functional Descriptions The PmodJSTK2 utilizes two potentiometers oriented orthogonally to one another and are manipulated by moving the joystick in the X and Y directions. As the joystick moves, the voltage output at the sweep pin of each potentiometer changes and is measured by the 10-bit ADC present on the embedded PIC16F1618 microcontroller. The raw measured data is stored at a rate of 100 Hz as a 16-bit right-justified variable in RAM with the upper 6 bits masked with zeros. Additionally, each successive measurement also produces two 8-bit values representative of the joysticks physical location with respect to each axis. Note that if inversion of either of the 8-bit position axis are set, the values will not change until the data has been re-collected by the PIC16 at the 100 Hz rate. DOC#: 502-330 Other product and company names mentioned may be trademarks of their respective owners. Page 1 of 9

2 Specifications Parameter Min Typical 1 Max Units Recommended Operating Voltage 3.1 3.3 3.5 V Maximum Supply Voltage - - 5.5 V Power Supply Current 2-4.85 - ma Power Supply Current 3-17.6 - ma Parameter Value Units Maximum Joystick Angle 25 Degrees Communication Protocol Note¹: Data in the Typical Column uses VCC at 3.3V unless otherwise noted Note²: Normal operation with the RGB LED Off and no buttons pressed Note³: Normal operation with the RGB LED set to white and both buttons pressed SPI 3 Interfacing with the Pmod The PmodJSTK2 communicates with the host board via the SPI protocol. With the PmodJSTK2, there are two types of data packet protocols: the standard data packet of 5 bytes and an extended data packet with 6 or 7 bytes in total. With the standard 5 byte protocol, users may use the old code from the PmodJSTK without any syntax errors. The 5 byte packet structure is provided in the image below: As noted in the standard data packet structure, users may either send a zero and a series of 4 dummy bytes to receive the standard 5 bytes of data or they may send a single command byte with up to 4 parameters in the four following bytes to set the internal values such as the joystick calibration or on-board RGB LED. The extended data protocol allows for additional data to be obtained from the device during a communication session after the standard 5 bytes of information such as normalized 8-bit positional data for each axis. Users may also obtain the current calibration values and the status of the module through this method. Other product and company names mentioned may be trademarks of their respective owners. Page 2 of 9

3.1 SPI Timing Requirements The embedded PIC16F1618 requires certain SPI timing requirements in order for successful communication to occur. When the Chip Select line is brought low, users must wait at least 15 μs before sending the first byte of data. An interbyte delay of at least 10 μs is required when transferring multiple bytes. When the Chip Select line is brought high after the last byte has been transferred, at least 25 μs is required before users may bring the Chip Select line low again to initiate another communication session. 3.2 Calibrating the Module The PmodJSTK2 has a set of factory loaded calibration values that are used to calculate the 8-bit position values for each axis. Users may enter calibration mode to recalculate all of those values by rotating the joystick around so the embedded PIC16 can record all of the maximum and minimum samples for the two axes. The on-board blue LED will be flashing to indicate that the calibration sequence is taking place. When the embedded microcontroller detects that the joystick has not changed for an entire second, allowing the microcontroller to presume that the most recent set of measurements correspond to the joystick's center position, the blue LED will stop flashing and the green LED will flash twice to indicate that the calibration procedure was successful. However, if 10 seconds pass without the PIC16 detecting the center position, the blue LED will stop flashing and the red LED will flash twice indicating that the calibration procedure was not successful. Once the Chip Select pin goes high after the calibration command has been processed, the PmodJSTK2 will not accept any new commands during the calibration procedure. Users may still poll the status register to determine the current status of the device during this time. Other product and company names mentioned may be trademarks of their respective owners. Page 3 of 9

3.3 Using the High-endurance Flash The PmodJSTK2 has a set of factory loaded calibration values that are used to calculate the 8-bit position values for each axis. Users may enter calibration mode to recalculate all of those values by rotating the joystick around so the embedded PIC16 can record all of the maximum and minimum samples for the two axes. The on-board blue LED will be flashing to indicate that the calibration sequence is taking place. When the embedded microcontroller detects that the joystick has not changed for an entire second, allowing the microcontroller to presume that the most recent set of measurements correspond to the joystick's center position, the blue LED will stop flashing and the green LED will flash twice to indicate that the calibration procedure was successful. However, if 10 seconds pass without the PIC16 detecting the center position, the blue LED will stop flashing and the red LED will flash twice indicating that the calibration procedure was not successful. Once the Chip Select pin goes high after the calibration command has been processed, the PmodJSTK2 will not accept any new commands during the calibration procedure. Users may still poll the status register to determine the current status of the device during this time. Other product and company names mentioned may be trademarks of their respective owners. Page 4 of 9

3.4 Command Summary 3.4.1 Get Commands Other product and company names mentioned may be trademarks of their respective owners. Page 5 of 9

3.4.2 Set Commands Other product and company names mentioned may be trademarks of their respective owners. Page 6 of 9

Other product and company names mentioned may be trademarks of their respective owners. Page 7 of 9

3.4.3 Other Commands Other product and company names mentioned may be trademarks of their respective owners. Page 8 of 9

4 Pinout Description Table A pinout table of the PmodJSTK2 is provided below. Pin Signal Description 1 CS Chip Select 2 MOSI Master-Out-Slave-In 3 MISO Master-In-Slave-Out 4 SCK Serial Clock 5 GND Power Supply Ground 6 VCC Power Supply (3.3V/5V) Although users are welcome to create their own interface code for the PmodJSTK2 if they so desire, preconstructed libraries that provide functions for initializing the module, reading in values, and adjusting calibration values exist. They are available on the PmodJSTK2 example code page. Any external power applied to the PmodJSTK2 must be within 2.95V and 5.5V; however, it is recommended that Pmod is operated at 3.3V. 5 Physical Dimensions The pins on the pin header are spaced 100 mil apart. The PCB is 1.875 inches long on the sides parallel to the pins on the pin header, 0.9375-inch-long on the sides perpendicular to the pin header, and 1.75 inches tall. With the 3- D printed housing the module is 1.875 inches long on the sides parallel to the pins on the pin header, 1.125 inches long on the sides perpendicular to the pin header, and 1.75 inches tall. Other product and company names mentioned may be trademarks of their respective owners. Page 9 of 9