Getting Started with Tiva ARM Cortex M4 Microcontrollers: A Lab Manual for Tiva LaunchPad Evaluation Kit
By Dhananjay V. Gadre and Sarthak Gupta
()
About this ebook
Related to Getting Started with Tiva ARM Cortex M4 Microcontrollers
Related ebooks
Real-Time Critical Systems Rating: 3 out of 5 stars3/5Microprocessor and Microcontroller Interview Questions: A complete question bank with real-time examples Rating: 0 out of 5 stars0 ratingsProgramming Microcontrollers with Python: Experience the Power of Embedded Python Rating: 0 out of 5 stars0 ratingsArchitecting and Building High-Speed SoCs: Design, develop, and debug complex FPGA based systems-on-chip Rating: 0 out of 5 stars0 ratingsDeep Belief Nets in C++ and CUDA C: Volume 3: Convolutional Nets Rating: 0 out of 5 stars0 ratingsDeep Belief Nets in C++ and CUDA C: Volume 2: Autoencoding in the Complex Domain Rating: 0 out of 5 stars0 ratingsSimulating Nonlinear Circuits with Python Power Electronics: An Open-Source Simulator, Based on Python™ Rating: 0 out of 5 stars0 ratingsError Control Coding for B3G/4G Wireless Systems: Paving the Way to IMT-Advanced Standards Rating: 0 out of 5 stars0 ratingsPractical Contiki-NG: Programming for Wireless Sensor Networks Rating: 0 out of 5 stars0 ratingsBuilding Telephony Systems with OpenSER Rating: 0 out of 5 stars0 ratingsDeep Belief Nets in C++ and CUDA C: Volume 1: Restricted Boltzmann Machines and Supervised Feedforward Networks Rating: 0 out of 5 stars0 ratingsBlockchain Foundation Courseware - English Rating: 0 out of 5 stars0 ratingsLearning PyTorch 2.0, Second Edition: Utilize PyTorch 2.3 and CUDA 12 to experiment neural networks and deep learning models Rating: 0 out of 5 stars0 ratingsLearning PyTorch 2.0, Second Edition Rating: 0 out of 5 stars0 ratingsIntroduction to Quantum Computing & Machine Learning Technologies: 1, #1 Rating: 0 out of 5 stars0 ratingsPLCs for Beginners: An introductory guide to building robust PLC programs with the Structured Text language Rating: 0 out of 5 stars0 ratingsEmbedded Software Design and Programming of Multiprocessor System-on-Chip: Simulink and System C Case Studies Rating: 0 out of 5 stars0 ratingsAdvanced Network Simulations Simplified: Practical guide for wired, Wi-Fi (802.11n/ac/ax), and LTE networks using ns-3 Rating: 0 out of 5 stars0 ratingsThe IoT Hacker's Handbook: A Practical Guide to Hacking the Internet of Things Rating: 0 out of 5 stars0 ratingsSmart Sensor Systems: Emerging Technologies and Applications Rating: 0 out of 5 stars0 ratingsBeginning e-Textile Development: Prototyping e-Textiles with Wearic Smart Textiles Kit and the BBC micro:bit Rating: 0 out of 5 stars0 ratingsTkinter GUI Application Development Blueprints Rating: 0 out of 5 stars0 ratingsInternet of Things Security: Principles and Practice Rating: 0 out of 5 stars0 ratingsEmbedded Deep Learning: Algorithms, Architectures and Circuits for Always-on Neural Network Processing Rating: 0 out of 5 stars0 ratingsHands-On GPU Programming with Python and CUDA: Explore high-performance parallel computing with CUDA Rating: 0 out of 5 stars0 ratingsHands-on ESP32 with Arduino IDE: Unleash the power of IoT with ESP32 and build exciting projects with this practical guide Rating: 0 out of 5 stars0 ratingsHands-on Question Answering Systems with BERT: Applications in Neural Networks and Natural Language Processing Rating: 0 out of 5 stars0 ratingsGetting Started with Oracle Tuxedo Rating: 0 out of 5 stars0 ratingsDatabase Benchmarking and Stress Testing: An Evidence-Based Approach to Decisions on Architecture and Technology Rating: 0 out of 5 stars0 ratings
Electrical Engineering & Electronics For You
Beginner's Guide to Reading Schematics, Fourth Edition Rating: 4 out of 5 stars4/5Off-Grid Projects: Step-by-Step Guide to Building Your Own Off-Grid System Rating: 0 out of 5 stars0 ratingsThe Homeowner's DIY Guide to Electrical Wiring Rating: 5 out of 5 stars5/5Beginner's Guide to Reading Schematics, Third Edition Rating: 0 out of 5 stars0 ratingsThe Innovators: How a Group of Hackers, Geniuses, and Geeks Created the Digital Revolution Rating: 4 out of 5 stars4/5Electricity for Beginners Rating: 4 out of 5 stars4/5How to Diagnose and Fix Everything Electronic, Second Edition Rating: 4 out of 5 stars4/5Electrician's Pocket Manual Rating: 0 out of 5 stars0 ratingsBasic Electricity Rating: 4 out of 5 stars4/5Upcycled Technology: Clever Projects You Can Do With Your Discarded Tech (Tech gift) Rating: 5 out of 5 stars5/5Electrical Engineering | Step by Step Rating: 0 out of 5 stars0 ratingsDIY Lithium Battery Rating: 3 out of 5 stars3/5Practical Electrical Wiring: Residential, Farm, Commercial, and Industrial Rating: 4 out of 5 stars4/52022 Adobe® Premiere Pro Guide For Filmmakers and YouTubers Rating: 5 out of 5 stars5/5Digital Filmmaking for Beginners A Practical Guide to Video Production Rating: 0 out of 5 stars0 ratingsRaspberry Pi Electronics Projects for the Evil Genius Rating: 3 out of 5 stars3/5Circuitbuilding Do-It-Yourself For Dummies Rating: 0 out of 5 stars0 ratingsSchaum's Outline of Basic Electricity, Second Edition Rating: 5 out of 5 stars5/5Basic Electronics: Book 2 Rating: 5 out of 5 stars5/5The Electrician's Trade Demystified Rating: 0 out of 5 stars0 ratingsRaspberry Pi Projects for the Evil Genius Rating: 0 out of 5 stars0 ratingsComplete Electronics Self-Teaching Guide with Projects Rating: 3 out of 5 stars3/5The Off Grid Solar Power Bible For Beginners Rating: 0 out of 5 stars0 ratingsTwo-Stroke Engine Repair and Maintenance Rating: 0 out of 5 stars0 ratingsMaking Everyday Electronics Work: A Do-It-Yourself Guide: A Do-It-Yourself Guide Rating: 4 out of 5 stars4/5Electrical Engineering Rating: 4 out of 5 stars4/5Designing, Building, and Testing Your Own Speaker System with Projects Rating: 3 out of 5 stars3/5Canadian Radio Amateur Answers Manual: CRAAM Rating: 0 out of 5 stars0 ratingsRamblings of a Mad Scientist: 100 Ideas for a Stranger Tomorrow Rating: 0 out of 5 stars0 ratings
Reviews for Getting Started with Tiva ARM Cortex M4 Microcontrollers
0 ratings0 reviews
Book preview
Getting Started with Tiva ARM Cortex M4 Microcontrollers - Dhananjay V. Gadre
© Springer (India) Pvt. Ltd. 2018
Dhananjay V. Gadre and Sarthak GuptaGetting Started with Tiva ARM Cortex M4 Microcontrollershttps://doi.org/10.1007/978-81-322-3766-2_1
1. Introduction
Dhananjay V. Gadre¹ and Sarthak Gupta²
(1)
Division of Electronics and Communications Engineering, Netaji Subhas Institute of Technology, New Delhi, India
(2)
TI Centre for Embedded Product Design, Netaji Subhas Institute of Technology, New Delhi, India
Dhananjay V. Gadre
Email: [email protected]
This lab manual allows the user to get acquainted with the Tiva C Series microcontroller family based on ARM Cortex M4 through a hands-on approach by performing experiments on a hardware evaluation kit, namely, the EK-TM4C123GXL LaunchPad from Texas Instruments. Texas Instruments offers many Tiva-based LaunchPad kits, but for the remainder of the text, we will refer to this as the Tiva Launchpad. The Tiva Launchpad offers great value for money but as is the common feature of all the LaunchPad kits, there are not many user interfaces that a beginner could use to learn the various features of the microcontroller. To alleviate this problem, we have designed a motherboard with many popular input and output devices and connected them to a set of connectors that allows the user to plug the Tiva LaunchPad onto the motherboard using these connectors and get access to these peripheral devices. This motherboard is called Padmaboard.¹
The experiments proposed in the manual are divided on basis of the microcontroller peripherals required to perform those experiments. The difficulty level of experiments increases as reader progresses through the manual. The later experiments will require combination of multiple microcontroller peripherals together to perform them. Apart from experiments mentioned in the manual, many more experiments can be performed by combination of various features of the PadmaBoard. Apart from performing academic experiments, PadmaBoard can also be used in initial prototyping and testing of many projects.
This manual also emphasizes on the development of standalone projects based on Tiva C Series microcontroller family. This includes the development of hardware as well as software part for any microcontroller of Tiva C series family.
1 Tiva LaunchPad
Tiva C Series EK-TM4C123GXL LaunchPad Evaluation Kit from Texas Instruments is referred in this lab manual for the user to get acquainted with ARM cortex M4 Tiva C series microcontroller family. This evaluation kit includes:
1.
Tiva LaunchPad Circuit Board (as shown in Fig. 1)
2.
USB micro-B plug to USB-A plug cable
A331507_1_En_1_Fig1_HTML.gifFig. 1
Tiva LaunchPad
There are two USB micro-B connectors, one is for ICDI (In-circuit Debug Interface) for debug applications and another one is for the user to connect the Tiva microcontroller to external Host as a USB device. Connect USB cable to the ICDI USB Micro-B connector and make sure that the slide switch is push toward the Debug side. If the USB cable is connected to Device USB port and the slide switch is toward the Device side, it will still power the Tiva LaunchPad but user will not be able to program it directly. After connecting the USB cable with slide switch in correct position, yellow power LED will light up. This LED will remain ON indicating that LaunchPad is receiving power from source through USB port.
2 PadmaBoard
PadmaBoard is a peripheral motherboard of Tiva LaunchPad. This board is placed beneath the Tiva LaunchPad and connected to Tiva LaunchPad through its bottom side of expansion headers as shown in Fig. 2. This board allows the user to utilize various peripherals of microcontroller. The user can perform various experiments based on peripherals like Universal Asynchronous Receiver and Transmitter (UART), Serial Peripheral Interface (SPI), Inter-Integrated Circuit (I2C), and Analog-to-Digital Converter (ADC), which are not possible with just Tiva LaunchPad.
A331507_1_En_1_Fig2_HTML.gifFig. 2
Tiva LaunchPad with PadmaBoard
When PadmaBoard is connected to Tiva LaunchPad. Now power Tiva LaunchPad through USB port, then power LED LED1 on PadmaBoard will light up and will remain ON indicating that PadmaBoard is receiving power from Tiva LaunchPad.
3 Tiva C Series Microcontroller Breakout Board
To develop standalone projects on Tiva C Series microcontroller family, a breakout board of Tiva TM4C1231H6PZ² microcontroller is used. Figure 3 shows the breakout board. This board can be programmed (or debug) and powered through FRC connector. Also, breakout board can be powered through the expansion headers. Whenever the breakout board is powered up, power LED LED1 will light up and will remain ON indicating that it is receiving power from the source.
A331507_1_En_1_Fig3_HTML.gifFig. 3
Tiva TM4C1231H6PZ Microcontroller Breakout Board
4 Look Ahead!
Once it is ensured that the kits (PadmaBoard and Tiva LaunchPad) are running properly, it is time to review the coverage of this lab manual.
Chapter 2 provides overview ARM cortex M4 architecture along with its peripherals. However it does not cover the detail coverage on ARM processors, for that reader is advised to go through the user guide of processor architecture from ARM. This chapter also includes brief description of peripherals of the microcontrollers belonging to Texas Instrument’s Tiva C Series family.
Chapter 3 discuses about the Tiva C Series TM4C123G LaunchPad Evaluation Board along with its features like power supply, clock, reset, on board ICDI port, LEDs, switches, and expansion headers.
Chapter 4 discuses about the PadmaBoard (Peripheral Motherboard of Tiva C Series LaunchPad) in particular about various onboard features in terms of hardware circuit diagram and operation. Peripherals included are temperature sensor, audio input, light sensor, magnetic field sensor, UART connector (for Bluetooth, RS232, RS485 communication), ultrasonic sensor connector, IR transmitter and receiver, Serial LCD and 16 keys Keypad, SD card interface, TV and potentiometer, RTC, dual DAC and audio output, and I2C bus connector (for connecting other external I2C-based modules available in market).
Chapter 5 deals with the development of standalone ARM projects, implemented using Texas Instrument’s Tiva C Series Microcontrollers family. Also includes various ways of programing TIVA C Series microcontrollers.
Chapter 6 deals with installation of software tools that are necessary to program Tiva LaunchPad or any Tiva C Series microcontrollers. This chapter illustrates the setup of a complete toolchain to program Tiva LaunchPad or any other Texas Instruments Tiva C series microcontrollers by using open-source tools.
Chapter 7 deals with the basic structure of embedded C programs. It also includes the basic programs for Tiva C Series microcontrollers using register access.
Chapter 8 deals with the driver library provided by Texas Instruments for their Tiva C Series microcontrollers. This driver library eases the programming of microcontrollers as user does not need to go into much details by using these libraries. Although this library contains a number of functions, but the basic functions that are most commonly used are illustrated in this chapter.
Chapter 9 deals with the control of digital input and output ports of Tiva C Series microcontrollers. Also, the chapter deals with peripherals which are controlled with digital IO pins such as LEDs, Switches, buzzer, and ultrasonic module.
Chapter 10 deals with the various interrupts sources offered by the Tiva C series microcontrollers. Also, this microcontroller family has a pretty nicely ordered interrupt structure and has large number of interrupt sources among which any digital pin can act as interrupt source. This chapter includes a description on using digital pin as an interrupt source.
Chapter 11 deals with the timers. Tiva C Series microcontrollers have 16-bit, 32-bit, and 64-bit timers. This chapter describes the various modes of timers in which they can be operated in. Also deals with the generation of delays, PWM, interrupts, etc., by using timers.
Chapter 12 describes Universal Asynchronous Receiver and Transmitter (UART) peripheral on Tiva C Series microcontrollers, which is used to communicate with the host computer and other bluetooth devices.
Chapter 13 deals with the various modes of operation of microcontroller such as run mode, sleep mode, and deep-sleep mode for power saving.
Chapter 14 deals with the multichannel Analog-to-Digital Converter (ADC) present on Tiva C Series microcontrollers. This chapter also describes the various peripherals which provide the analog output such as potentiometer, audio input either through MIC or 3.5 mm audio jack, Hall effect sensor, LDR (Light- Dependent Resistor), and temperature sensor using LM35 or thermistor.
Chapter 15 deals with the serial communication peripherals which includes SPI (Serial Peripheral Interface) and I2C (Inter-Integrated Circuit). This chapter also includes applications of such serial communication peripherals like real-time clock (RTC), digital-to-analog converters using I2C peripheral and microSD card, and television display using SPI peripheral.
Chapter 16 deals with the various ways of user interface (input as well as output) such as 16 $$\times $$ 2 LCD, 16 keys keypad, and PS/2 keyboard. Also, includes the use of shift registers as 16 $$\times $$ 2 LCD and 16 keys keypad is connected serially through the shift registers.
Chapter 17 focuses on development of standalone projects by using Tiva C Series microcontrollers instead of Tiva LaunchPad. This chapter will help the reader in developing their own standalone circuits or projects independent of the Tiva LaunchPad.
5 List of Experiments
The experiments listed below can be implemented using Tiva LaunchPad and PadmaBoard. The list also includes experiments related to standalone implementation of Tiva microcontrollers. The list is divided into two parts (Tables 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11):
Experiments using Register Access
Experiments using API (Application Programming Interface)
Experiment list under API is further divided on basis of the requirement of microcontroller peripherals to perform that experiment. A brief description for each experiment is mentioned below in tabular format.
Experiments Using Register Access
Table 1
Overview of experiments based on register access
Experiments Using API (Application Programming Interface)
a. Digital Input/Output
Table 2
Overview of experiments based on digital input/output
b. Interrupt
Table 3
Overview of experiments based on interrupt
c. Timer
Table 4
Overview of experiments based on timer
d. Universal Asynchronous Receiver and Transmitter (UART)
Table 5
Overview of experiments based on UART
e. Power Management and System Control
Table 6
Overview of experiments based on power management and system control
f. Analog to Digital Converter (ADC)
Table 7
Overview of experiments based on ADC