Capabilities of the Microcontroller. Don’t underestimate the mini-computer

Reading Time: 4 minutes

The microcontroller on which we are working does have different capabilities which help us in making our work more efficient, better, and easier. The microcontroller stm32f3-discovery board also shares multiple capabilities that we use to solve all sorts of different problems.

In all my previous blogs we talked about the internals of the stm32 discovery board like how we can achieve safe access to the registers and how we can communicate with the Registers. You can check those blogs also.

So in today’s blog, we are going to discuss the same capabilities of the microcontroller and how they can be used effectively in Embedded Development.

As we are working with the Embedded Systems they make our task fast and reliable. Also, they are much smaller in size compared to traditional computers, which makes them compact and portable, and useful for mass production. Management of Embedded Systems is pretty easy, as elements used in their creation are cheap & long-lasting. Embedded Systems are also cost-effective.

Capabilities of stm32f3 Discovery Board

Interrupts

  • Talking about Interrupts, when working in real life or to interact with real-life scenarios we have to respond quickly whenever an event occurs. The microcontroller does have the ability to get “interrupt” at this time. Whenever any event occurs the microcontroller stops whatever work it is doing at that moment and responds to that event.
  • It’s useful when we want to stop a motor when a button is pressed, or measure a sensor when a timer finishes counting down.
  • We have to manage the interrupt properly as we want to make sure that we respond to events quickly, but also allow other work to continue as well.

DMA (Direct Memory Access)

The next is DMA:

Direct memory access (DMA) is a means of having a peripheral device control a processor’s memory bus directly.

DMA basically helps us in performing bulk transfer of Data. We saw in the I2C chapter how we transfer register data in bytes only using peripheral like UART and I2C. Either from RAM to RAM, from a peripheral, like a UART, to RAM, or from RAM to a peripheral.

Digital Inputs

As we saw already in the blog in which we blink the LEDs that we used the led pins as digital output but did not talk about them as Digital Input. We can configure these pins as digital inputs.

In digital inputs, these pins can read the binary state of switches (on/off) or buttons (pressed/not pressed).

RTC (Real Time Clock)

The RTC peripheral can measure the time in real format or can say in “human format”. It can keep track of seconds, minutes, hours, and even of days, months and years. It can also track leap years.

This peripheral handles the translation from “ticks” to these human-friendly units of time.

ADC (Analog-to-Digital Converters)

There are many sensors on which we can work. We can use a protocol like I2C or SPI to read these sensors.

Analog sensors also exist which basically generate the output voltage which is proportional to the magnitude they are sensing.

The ADC peripheral can be used to convert that “analog” voltage level, into a “digital” number range, that the processor can use in its calculations.

DAC (Digital-to-Analog Converters)

So talking about DAC it is opposite to ADC converters, as DAC basically converts the Digital value written on registers into Analog value.

A Digital-to-Analog Converter (DAC) consists of a number of binary inputs and a single output. In general, the number of binary inputs of a DAC will be a power of two.

So these are some of the Capabilities that a Microcontroller like stm32f3 board consists. We use them to solve many problems.

This is the end of this blog, I hope you liked it. Thanks for reading..

If you want to read more content like this? Subscribe to Rust Times Newsletter and receive insights and latest updates, bi-weekly, straight into your inbox. Subscribe to Rust Times Newsletter: https://bit.ly/2Vdlld7.

Written by 

Nitin is a Software Consultant, with experience of more than 7 months. He works on Rust Programming Language and Embedded Development using Rust. He is also fond of Java Programming & Artificial Intelligence. Apart from that, his hobbies are Watching Netflix, Reading, Singing & Writing.