You are on page 1of 1

Welcome to Hackster!

RELATED PROJECTS ×
Overview Hercules LaunchPad MkII:
Hackster
Hackster is a community dedicated to learning hardware, from beginner to pro. Join us, it's free! ePWM Example
Things
Story
Search Projects Log in LaunchPad
Hercules Sign up
CAN
Button A
Bus Test Gig
Button B
Projects Channels News Contests Events Videos
Schematics
Hercules Safety Library
Credits
Self Test
Comments (0) Jan Cumps
Published May 23, 2018 © GPL3+

The 2 User Buttons on the


How to Use a Quadrature
2 Encoder with
TMS570LC43x LaunchPad

Hercules LaunchPad Type II Hercules Driver Library for


Hitachi LCD Displays
How to use the two pushbuttons on the new Hercules LaunchPad type II.
Beginner Protip 1 hour 818 Ad
View more related projects
RELATED CHANNELS AND TAGS

automotive industrial safety

Things used in this project


Hardware components

Texas Instruments Hercules Microcontroller × 1

Story
This post describes how to use the two pushbuttons on the new Hercules
LaunchPad type II.

Button A
Button A connects to pin 55, and is multiplexed as:

MIBSPI3NCS_0
AD2EVT

GIOB_2
EQEP1I

In the HALCoGen PINMUX tab, we set the pin 55 to GIO

The pin 55 is a special case. It also requires that you make the following
Special Pin Muxing setting:

That's all that's needed in HALCoGen.

In Code Composer Studio, add this call to sys_main.c to initialize the gio
driver.

gioInit(); // user button A is on the GIOB port, 2

You can check the state of the button in your code by executing:
gioGetBit(gioPORTB, 2);

Button B
Button B connects to pin 41, and multiplexes as

N2HET1_15
MIBSPI1NCS_4

ECAP1

We MUX Button B as NHET (NHET1 pin 15). This port/pin combination can be
used in the GIO API as a generic GIO pin.

You need to enable the NHET driver in HALCoGen so that the header files
with the HET registers are created. I also call the init of the HET driver.
gioInit();
hetInit(); // user button B is on the HET1 port, 15

You can check the state of the button in your code by executing:
gioGetBit(hetPORT1, 15);

Schematics

schematics

Credits
Jan Cumps
22 projects • 22 followers

Follow Contact

Comments
Please log in or sign up to comment.

Start the conversation!

Similar projects you might like

Hitachi LCD Driver Example for Measure Eclipse 2015 with a Hercules TMS570LC43 RTOS Minimal lwIP Project for Hercules
the Hercules LaunchPad Hercules LaunchPad project - LED Blinky with Two LaunchPad
Tasks
Jan Cumps Jan Cumps Jan Cumps Jan Cumps

852 1 477 4 3.7K 4 3.1K

Hercules: Configure Memory Hercules TMS570LS04 I2C Driver Adapt Web Server and Ethernet IR LaunchPad to LaunchPad
Cache for DMA Library Example for Hercules LaunchPad Communication
Jan Cumps Jan Cumps Jan Cumps Chris Roberts

2 2.2K 1 1.0K 6 1.2K 6 2.9K

About Us Legal Thingies Find Us On Social Visit Our Avnet Family Hackster.io, an Avnet Community © 2023

Hackster Overview Terms of Service  Facebook Avnet


Hackster for Business Code of Conduct  Instagram Premier Farnell
Help Articles Privacy Policy  LinkedIn element14
Brand Resources Privacy Policy for California  Twitter Newark
Sitemap Residents  YouTube
Cookie Policy

You might also like