This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
en:iot-open:iotmicrocontrollers2 [2023/08/22 09:53] – created pczekalski | en:iot-open:iotmicrocontrollers2 [2024/05/27 10:12] (current) – pczekalski | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===== Introduction to the IoT Microcontrollers ===== | + | ====== Introduction to the IoT Microcontrollers ====== |
- | <todo @ktokarz>Describe | + | {{: |
+ | At the perception layer of IoT systems usually some kind of computer operates. Depending on the complexity of the device the computational power of it does not need to be very high. Its design is similar to the Embedded System with the difference that the IoT node device should be equipped with some communication module. We can denote the IoT end-device as the constrained computer, built with four modules: a **sensing unit**, a **processing unit**, a **communication unit**, and a **power supply unit**, as presented in the figure {{ref> | ||
+ | <figure RefIoTnode> | ||
+ | {{ : | ||
+ | < | ||
+ | </ | ||
+ | |||
+ | Every computer consists of at least the central processing unit (processor), | ||
+ | There exists a variety of different kinds of processors with capabilities adjusted to the target system requirements. The most universal is the general-purpose processor which can be a microprocessor, | ||
+ | Currently, the most popular choice to design the IoT node is some kind of single-chip computer: microcontroller, | ||
+ | Wireless networking capability makes Microcontrollers even more complex | ||
+ | The typical microcontroller includes general-purpose units like: | ||
+ | * CPU core, | ||
+ | * Program memory, | ||
+ | * Data memory, | ||
+ | * Timers, Counters, | ||
+ | * Interrupt controller, | ||
+ | * I/O ports, | ||
+ | * Serial synchronous and asynchronous communication ports, | ||
+ | * Analog to Digital converter, | ||
+ | * PWM (Pulse width Modulation unit for Digital to Analog conversion), | ||
+ | * DMA controller, | ||
+ | * Supervisory units (Watchdog, Reset, Brownout). | ||
+ | Embedded Processor or System on Chip can contain also: | ||
+ | * Network interface, | ||
+ | * USB controller, | ||
+ | * Memory interface module, | ||
+ | * Floating point unit (FPU), | ||
+ | * Cryptographic module, | ||
+ | * Other application-specific extensions. | ||
+ | The **CPU core** is the unit that executes the main program. It controls program flow, executes general-purpose instructions, | ||
+ | The program instructions are fetched from **program memory**, usually implemented as internal or external flash memory. Data is stored in internal **data memory** implemented as static RAM. If more memory is needed, some microcontrollers have a memory management unit that allows them to connect external DRAM memory. Flash memory is often used as a place for file storage. | ||
+ | **Timers and counters** are units that help to generate pulses of specified length and square signals of selected frequency. They can also measure delays and synchronise the work of other modules like serial ports, converters, and displays. Timers can generate pulse width modulated signals to control the speed of motors and light brightness. | ||
+ | Microcontrollers have **digital input and output ports** to connect other elements of the systems. Connecting external sensors to collect information from the surroundings and output devices to manipulate environmental parameters is possible. **Analogue inputs** can read the voltage value generated by simple sensors. | ||
+ | **Serial communication ports** are used to connect more complex sensors and displays to communicate with the user or another computer system. | ||
+ | An **interrupt controller** is a unit that automatically executes subroutines responsible for handling tasks specific to the hardware that signalled the situation that needs the processor' | ||
+ | **Supervisory units** help to recover from some abnormal situations. Watchdog resets the processor in case the software hangs up. Brownout detector constantly monitors the power supply voltage. It stops the processor if the voltage is too low for proper operation to avoid execution errors, flash write errors, and other malfunctions. Supervisory interfaces like JTAG allow writing the programs into flash memory and debugging the code. | ||
+ | **Direct Memory Access** (DMA) module performs memory operations without processor intervention. It is usually used for copying data blocks between memory and other peripheral units. For example, data from the network unit is stored automatically in the buffer, and the CPU is informed while the data transfer is complete. | ||
+ | |||
+ | Details of the internal construction and operation of many internal modules of popular microcontrollers are described in further chapters of this book. | ||
+ |