STM32

Bit Banding in the STM32

Wondrous though the STM32 (ARM Cortex M3) might be, it makes something of a meal of atomic access to individual bits in memory. The technique used is called bit-banding. Although it is simple enough in concept and pretty friendly to the assembly language programmer, it is easy enough to get lost in C. Or should that be at C?

STM32 USART basics

A USART is a universal synchronous asynchronous receiver transmitter. A serial port if you like. On the STM32 however, it really is universal. This peripheral has a raft of features for a huge range of serial protocols including all the usual asynchronous modes plus IrDA, LIN, Smartcard Emulation and the ability to function as an SPI port…

ARM STM32 JTAG

JTAG is a common standard for communicating with modern electronic devices like FPGAs and microcontrollers. A JTAG connection will allow you to do in-circuit debugging in a bewildering variety of ways and will generally allow you to program your device. The standard, apparently, defines five connections for this purpose. Add in power and ground and you have a minimum of 7 connections needed to implement JTAG. The trick is getting them delivered to your board or device…

Crossworks projects startup and debugging

Crossworks or, more accurately, CrossStudio for the Arm, running on a mac is probably one of the better development environments. It has its quirky side but, so far, I am really happy with it. Now might be a good time to look at how projects are organised, how the code gets onto the target and how it is started up…

Crossworks Blinky Project 3 - PLL and HSE

Last time, the STM32 was set up to use the Internal RC oscillator, HSI. This runs at 8MHz. The PLL multiplier was told to use the HSI/2 as its input and the multiplier value was set to x 5. The result being a 20MHz system clock. Now, what happens if the PLL multiplier is increased to make the system run faster…