What can you do with a microcontroller?

What can you do with a microcontroller?

Typical input and output devices on microcontrollers can include switches, LED displays, and even sensors that can measure temperature, humidity, light levels, etc. You can attach something like this photoresistor into a breadboard and then connect it to a microcontroller to sense light levels. ( Image source)

How does a microcontroller work in a washing machine?

When the water level reaches the level of the clothes, the microcontroller will tell the motor controller to turn off the flow of water and begin the washing cycle. There are some benefits for opting to use a microcontroller in specific applications like my washing machine instead of a traditional computer system, and it namely boils down to:

How does a microcontroller control the speed of the processor?

A Way to Stay on Track – A microcontroller needs a way to control the speed of its processor, and it does this by using an oscillator or a clock which acts as the engine to drive your MCU. Of course, the size of all of these different pieces of hardware is much smaller than a traditional computer.

How does ROM work in a microcontroller?

Some microcontrollers ship with built-in ROM, while others can accept ROM added as an external chip. It varies between each microcontroller. Another feature nestled within a microcontroller is the program counter, which allows your mini computer to execute a program based on a series of programmed instructions.

Computers (which have inputs and outputs, storage, and processing) can run multiple programs at a time — you can surf the Internet, reminisce with old photos, write a paper, and have like 1000 tabs open all at the same time! Microcontrollers… not so much. You can do one of those things, but not all.

How to safely connect external devices to a microcontroller?

This article covers important drivers and proper circuitry required to safely connect external devices to an MCU’s I/O. As soon as you have an idea for a project, it is very tempting to jump right in and connect Arduinos and micro:bit devices to circuits and devices such as LEDs, relays, and speakers.

What happens when a microcontroller outputs a 0?

When the microcontroller (connected to “IN”), outputs a 1 then the transistor Q1 turns on. This turns on relay RL1 and the result is the lamp (R2), turning on. If the microcontroller outputs a 0 then the transistor Q1 turns off which disables the relay and therefore the lamp turns off.

What happens when you hit a button on a microcontroller?

Buttons are usually a piece of metal that make contact with some other metal when pressed but when buttons make contact they often bounce (albeit a tiny one). This bounce means that the button connects and disconnects several times before settling and the result is an output that briefly looks random.