Presentation is loading. Please wait.

Presentation is loading. Please wait.

MSP432™ MCUs Training Part 5: Digital Peripherals

Similar presentations


Presentation on theme: "MSP432™ MCUs Training Part 5: Digital Peripherals"— Presentation transcript:

1 MSP432™ MCUs Training Part 5: Digital Peripherals
Timers: TimerA, Timer32, RTC, WDT eUSCI: UART, SPI, I2C GPIO DMA Welcome to part five of the MSP432 MCU Training series. In this section we will take a quick survey at all of the digital peripherals that are available on the MSP432. We will start off with various timer resources; we will then cover the serial communication, the digital IO and then finish with DMA.

2 + Timers | Overview Timer Instances # of Bits Lowest Operating mode
Interval PWM Main/Other Function Timer_A 4 16 LPM0, LPM0_LF ✔✔ Capture, Compare Timer32 2 32 SysTick 1 24 RTC 32* LPM3, LPM3.5 WDT So first off with timers, there are quite a few timer resources available on MSP432. Each with different feature sets to fit different requirements and different types of applications. Starting off with Timer A, Timer A is a 16 bit timer available on many existing MSP430 devices; it is also the most flexible timer, essentially a Swiss Army knife of timer because it can be used in many different use cases. So each Timer A module comes with five capture and compares channels. Each of the channels can be configured in many different counting modes, such as continuous counting mode, up down and it could also be used in different output modes such as toggle, set, reset and so on so forth. So all of these combinations that I just mentioned, you could leverage any of those across the five channels across the four instances, to essentially create and fulfil as many different timer scenarios as possible, such as creating an interval timer, driving multiple PWMs of either the same time base or different time bases, or even having multiple capture and compare input channels. Timer A can also be sourced by any high speed as well as low speed clock sources. Moving on to the next two timers are Timer 32 and SysTick, these two are the two standard on timer modules. With Timer 32 as the name suggest, it is a 32-bit timer and there are two instances of Timer 32 on MSP432 and they can be cascaded together. So you could use the Timer 32 to essentially create any interval with a resolution of up to 32bit. Similarly, SysTick could either be used to count the number of CPU ticks or it can also be used to create an interval of up to 24 bit of resolution. So both Timer 32 and SysTick must be sourced from a high speed clock source typically there is an MCLK. The MSP432 also includes two low frequency timers, the Real Time Clock as well as the Watchdog Timer. Both of these timers can use a 32KHz clock source and they can operate all the way down to LPM3.3 and LPM 3.5 power modes. In addition to their primary functions as RTC and Watchdog, they can also be used as interval timers, which can be really useful for the device to wake up periodically from LPM3. So all of these timers that we have covered here they are all capable of generating interrupt based on their primary functions, whether that be PWM, capture compare, RTC or Watchdog, as well as they can also generate an interrupt as a generic interval timer. RTC & WDT: only have a few selection of pre-set intervals ✔✔ Timer_A, Timer32, SysTick: configurable intervals with 16/32/24-bit granularity

3 eUSCI | Serial Communication
400kHz & up to 1MHz 4 hardware slave addresses supported with dedicated TX/RX interrupts Byte counter for autonomous operation UART Enhanced baud rate generation Auto baud rate detection SPI 3 & 4-wire modes Up to 14MBps eUSCI A0 eUSCI A1 eUSCI B0 SPI, UART SPI, I2C Next, let’s take a look at the digital serial communication on MSP432. So the MSP432 includes an eUSCI module. This is the same module that is available on many existing MSP430 Families. Like other peripherals on MSP such as the Timer A, the eUSCI is also really flexible peripheral. It could also be called the Swiss Army knife of serial communication because the same module could be used to drive different communication interfaces such as I2C, UART and SPI. So the eUSCI can be split into two modules, the eUSCI A which is capable of driving the UART or the SPI communication and the eUSCI B is capable of driving the SPI and I2C communication. So starting off with UART, the eUSCI can drive multiple flexible UART configurations. It also introduces enhanced baud rate generation as well as baud rate detection. SPI communication on MSP 432 also supports both 3 and 4 wire modes and the SPI communication speed can be up to 14 Mbps. Lastly the I2C module on MSP432 can be used up to 400KHz and even 1MHz operating speed. We have also enhanced the I2C hardware module to include up to four hardware slave addresses supported with dedicated TX/RX interrupts. For more information on eUSCI as well as serial communication interfaces on MSP, refer to the existing application notes as well as user guides and software that we have created for various different MSP devices. You can find all of this information on MSPWare, please follow the link below here.

4 Digital I/O | Overview Ultra low-leakage IOs (± 20 nA Max)
Capacitive touch function available on all IOs Pull-up/Pull-down Interrupt/Wake-up capability available on 6 ports (48 pins) Port Map: 30 digital functions available to each of 24 port-mappable IOs Up to 4 pins with 20mA max output, suitable for optional high-drive functionality (P2.0-P2.3) 8 IOs with glitch filtering capability The MSP432 also features the same ultra-low leakage IOs that are well known on the MSP430 devices. These IOs are extremely easy to use, highly configurable and highly interruptible. The MSP432 devices also enable the capacitive touch function based on the pin oscillator feature on every single IO of the device. The digital IOs also include integrated Pull-up and Pull-down resistors. There are 6 ports or a total of 48 pins that are capable for interrupt as well as wake up functions on the device. There are also 24 digital IO pins on the device that are capable of port map function. What this means here is that each of the 24 port pins can be programmed or configured to utilize one of the 30 digital functions available to the device. This can become quite handy when you lay out the application, since you can essentially move any of these 24 pins around and designate any function that you like out of the 30 digital functions. Last but not least, also new to MSP432, there are four unique pins available on the device starting with P2.0 through P2.3 and these four pins have high current drive capability allowing for each of them to drive up to 20miliamp current out from each pin. So if you have one of the MSP432 LaunchPads, you can see that the extremely bright LEDs are driven by the high current Drive IOs

5 DMA | PL230 MicroDMA Single 32-bit AHB-Lite master interface for transferring data Supports multiple DMA transfer data widths and address increment values transfers in a single DMA access Each DMA channel has 2 channel control data structures (primary/alternate) stored in RAM Channel control data is stored in RAM Multiple DMA transfer types: Basic Auto-Request Ping-Pong Memory Scatter-Gather Peripheral Scatter-Gather Each DMA channel has a programmable priority level. Error indication in case any transfer comes back with a bus error response. The MSP432 also includes a micro DMA module that is standardized from ARM. It is a highly -flexible and highly configurable DMA module that allows you to have up to 8 DMA channels. You can configure the DMA to transfer in different types, such as basic, Auto-Request, Ping-Pong, Memory Scatter-Gather or Peripheral Scatter-Gather. Moreover, you could also configure anywhere form transfers in a single DMA access. So all of this configuration and control data go into RAM and you only need to exercise one drive API call to configure the entire API channel. Another improvement compared to MSP430 devices, is that Micro DMA allows each DMA channel to have a programmable priority level so even at run time, if you need to escalate the priority of one DMA channel over another, you have the ability to do so with Micro DMA. Keep in mind that Micro DMA has higher Priority Access over CPU. So if they need to share the same accesses DMA will gain access to the resources before CPU.

6 DMA | Triggers mapping Channel SRCCFG=0 SRCCFG=1 SRCCFG=2 SRCCFG=3
=7 Reserved eUSCI_A0 TX eUSCI_B0 TX0 eUSCI_B3 TX1 eUSCI_B2 TX2 eUSCI_B1 TX3 TA0CCR0 AES256_Trig gen0 1 RX RX0 eUSCI_B3 RX1 eUSCI_B2 RX2 eUSCI_B1 RX3 TA0CCR2 AES256_Trig gen1 2 eUSCI_A1 eUSCI_B1 eUSCI_B0 TX1 eUSCI_B3 TX2 eUSCI_B2 TX3 TA1CCR0 AES256_Trig gen2 3 eUSCI_B0 RX1 eUSCI_B3 RX2 eUSCI_B2 RX3 TA1CCR2 4 eUSCI_A2 eUSCI_B2 eUSCI_B1 TX1 eUSCI_B0 TX2 eUSCI_B3 TX3 TA2CCR0 5 eUSCI_B1 RX1 eUSCI_B0 RX2 eUSCI_B3 RX3 TA2CCR2 6 eUSCI_A3 eUSCI_B3 eUSCI_B2 TX1 eUSCI_B1 TX2 eUSCI_B0 TX3 TA3CCR0 External pin 7 eUSCI_B2 RX1 eUSCI_B1 RX2 eUSCI_B0 RX3 TA3CCR2 ADC14 Not only providing flexible Micro DMA. The MSP432 also wraps the DMA around the various sources and triggers that are particular to the MSP430 peripherals. As you can see we have a pretty diverse map of channels and different triggers that can be associated with each channel on MSP432 DMA. You have a variety of sources starting with serial communication, UART, SPI, I2C, or ADC, Timers, AES as well as some external pin. This flexibility allows you to use the DMA to create a pretty complex signal chain. For example, you can configure ADC to sample the signal from an ADC channel and when that conversion is finished, the DMA can take the value from ADC memory results over to the SPI transmit buffer, vice versa you can configure the DMA to receive the data from an I2C receive buffer and transfer that directly into memory. So with that we have concluded Part 5 of the MSP432 MCU training series, where we have covered the different peripherals available on MSP432. We covered the Timer Resources, serial communication as well as the IO and DMA. Thanks for watching.


Download ppt "MSP432™ MCUs Training Part 5: Digital Peripherals"

Similar presentations


Ads by Google