Can the Raspberry Pi be used as a MCU?

Posted by Hugh S.
2
Jan 6, 2022
301 Views
Image
1 Basic Definition
Raspberry Pi is actually a tiny embedded computer. It uses ARM microcontroller chip, and linux operating system or windows. It can regard as a small desktop computer when connects with a monitor, keyboard, and network (network port or wifi). With the release of Windows 10 IoT, Raspberry Pi can also run Windows.
The single-chip microcomputer refers to the central processing unit core with some peripheral interface circuits on it, which is also called the microcontroller unit (MCU), or system-on-chip (SoC). 8051 chips, avr chips, arm chips, etc. are all called single-chip microcontrollers, while Intel’s 80x86 series are central processing units (CPUs) and cannot be called MCU.
It uses very large-scale integrated circuit technology to integrate the central processing unit CPU with data processing capabilities, RAM, ROM, multiple I/O ports and interrupt systems, timers/counters and other functions (may also include display driving circuits, pulse width modulation circuits, analog multiplexers, A/D converters and other circuits) are integrated on a silicon chip to form a small and complete microcomputer system. It is widely used in the field of industrial control.
Raspberry Pi 2 Model B
Raspberry Pi 2 Model B

2 Raspberry Pi vs MCU
Next, let's take a look at the difference between the Raspberry Pi and the MCU and introduce in detail what can we do with the Raspberry Pi?
The single-chip microcomputer is an microcontroller, and the Raspberry Pi is a single-board computer with arm-architecture processor. Early MCUs were peripherals for ROM and IO with slow speed, and it could not run time-sharing operating systems such as Linux or Windows. But the Raspberry Pi can run an operating system like Linux, or deploy servers or cloud computing. That is, the Raspberry Pi can perform many operations that cannot be done by a single-chip microcomputer.
The size of the single-chip microcomputer is relatively small, and the internal chip is used as a computer system. Its structure is simple, but the function is perfect, it is very convenient to use, and it can be modularized. The most important thing is that although the development cycle of the single-chip microcomputer is relatively short, it is basically based on a specific task and the code must be re-programmed every time, which is very troublesome.
The Raspberry Pi is actually a computer motherboard. It can be programmed, compiled, and run directly locally. If you want to add or delete functions to the original program, or switch from the current task to a different new task, you do not need to burn programs like a single-chip microcomputer according to different tasks or updates. Use Raspberry Pi to control peripherals by operating GPIO basically through various libraries, and if you connect it to the Internet, you can operate it remotely.
In general, each has its own advantages. The MCU is cheap and suitable for general consumer products. After all, the Raspberry Pi is a card-type computer with an embedded operating system running on it. That is, a low-power general-purpose computer. For electronic geeks, the back-end data processing and GUI for complex control systems are still very good for satisfying embedded learning.

3 What Can We Do with Raspberry Pi?
After reading the above, since Raspberry Pi has the features of a computer, this means you’re able to do most things a desktop computer can do such as document editing, playing HD video, playing games, coding and much more.Obviously it won’t have as much power as a desktop PC but since it is a lot cheaper they make for great little computers you can play around with.
Here lists some items you can do:
1) Wireless Hotspot
Using the Internet cable and USB wireless network card, after configuration, it can be used as a wireless hotspot.
2) Mechanical Prostheses
MIT Media Lab researchers use it as a controller for mechanical prostheses.
3) Easy Homemade Notebook
Connect the Raspberry Pi to the LCD panel, add the mouse, keyboard and power supply, and find a beautiful case and put it on, finally it becomes a simple homemade notebook.
4) WiFi Car
An IBM engineer installed it on a model car, and then used WiFi signals to control the car’s actions.
5) Send Dynamics Remotely
Weather enthusiasts tied it to a detection balloon and used it to send a tweet in the stratosphere.
6) Control Door Switch
There are also people who use the Raspberry Pi to control the garage door and combine it with Siri to remotely control the garage switch.
7) Surveillance Shooting
A camera is connected as a small shooting device, which is small in size and easy to hide.
8) Back Up Emails
One of the most important functions of my Raspberry Pi is to back up emails. Use a software called getmail to check every mail using POP or IMAP protocol, and check the mail of each account regularly. Then save the email to an mbox file, which can be copied to another computer at any time for long-term email archiving.
9) Build a RSS Reader
Miniflux, a self-hosted web-based RSS client that can be installed on the Raspberry Pi. Like many people, when Google announced that it would close Google Reader on July 1st, I also started to migrate personal data. I used rss2email for a while and let it send every item of RSS to my mailbox. But in fact, I don't like this method very much, so I spent some time looking for alternatives to Google Reader and tried rss2email and found miniflux finally. Installing miniflux on the Raspberry Pi is very simple, you only need to install PHP and a web server software in advance, such as nginx or Apache.
10) Build a Website
One obvious use of Raspberry Pi is as a backend server for websites. Because it has enough capacity to handle static websites, some web frameworks are not a problem. I built a Flask framework on it, and I even heard that some people built a Wordpress directly on the Raspberry Pi.
11) Home network storage
Only consumes very low power, Raspberry Pi can become a perfect NAS (Network Attached Storage). Before I connected a 500GB laptop hard drive to the Raspberry Pi and installed an operating system on it. I can store many files on it that need to be transferred between different computers. Then connect via SFTP, you can access it on any machine at home (even if you are not at home, it will not be a problem as long as the routing settings are correct). You can also install Samba on your Pi so that both Mac and PC can access it more easily.
12) Site Monitoring
Use Raspberry Pi is to detect websites that are important to me. I wrote a Python script and ran it regularly to make sure that these websites responded with a 200 status code (which means everything is normal). If the script determines that there is a problem with the website or cannot be accessed, it will email me the overall situation of the incident. The Python module I use is Requests, and the email module is smtplib.
13) Event Reminder
Use Raspberry Pi to email me important events that I need to remember. I used Google Calendar before, but I only use it for simple events. So I replaced it with a Raspberry Pi, and a Python script for timed tasks is enough. I set the date, time, and message to remember. These parameters will be passed to my Python script, and on that day it will send the message to my mailbox to remind me of the day’s events.
14) Family Album
My Raspberry Pi also supports a private website that contains all my family photos. I set up verification information so only people I want them to see can enter the site. This is much more reliable than your Facebook photo album, because your account on Facebook may be deleted, and the photos will be seen by strangers by chance. Here is a method, just use PHP to get the photos in a folder on the Raspberry Pi.
15) Jukebox
I mentioned above that I use Pi as a network storage, so all my music is also on it. I connected a stereo speaker to my Pi and used mpg123 to play music on the command line of the Raspberry Pi. Although there are many other mp3 players and graphical interfaces, I still choose mpg123 because it is easy to install and use.

4 Where do I start to Learn Raspberry Pi?
If you are really interested in it and want to get started. How, and what do you need? 
1) A Raspberry Pi. So, obviously you’ll need he actual board. If you don’t have it, you cant really do what you want. So find a website or store and buy one. Depending on the type and model you get, they can range from as low as 10$ to 50$. Pretty affordable.
2) A monitor. So, you don’t actually need a monitor. But it is going to be so much easier. You can actually buy displays the Pi company has made specifically made for the Pi. These however are a little more expensive.
You could also use your TV as a monitor, providing both the TV and the Pi can be hooked up via HDMI. VGA to HDMI would work too. Many different solutions can be used when it comes to the cable you use for a monitor, or all around screen. Adapters come in all shapes, sizes and forms. 
3) A power source. You’ll need to power the Pi to use it. Most of the time, you will get a little charger to use with the Pi. Using this specific charger will probably be the best, as it will always pull enough power from the wall into your Pi.
4) A mouse, and keyboard. You will need a mouse and keyboard. This is pretty much mandatory. Well, only for the actual screen portion of the Pi. Models 3 B+ and up have built in Bluetooth, so you can have cordless mouse and keyboard if you would like. That’s pretty cool.
5) Depending on the model, you will need an Ethernet cable to have internet. Models 3 B+ and up have a built in WiFi chip. So you can have a wireless internet connection if you so please.
6) A microSD card with the image you want to use. When you buy the Pi, you will need to have an SD card. The newer models use microSD cards. Putting the SD card into the Pi without anything on it wont do anything though, you'll need an image. Images for the Pi can be found along the internet for downloads. The standard image used for the Pi right now is NOOBS Debian.
7) Time, patience and dedication. These are very important when working with the Pi. Why? Because the Pi is powerful, yet it can be confusing at times, especially for a “noob”.
Comments
avatar
Please sign in to add comment.