当前位置:网站首页>Is it meaningful for 8-bit MCU to run RTOS?
Is it meaningful for 8-bit MCU to run RTOS?
2022-07-06 17:50:00 【Embedded Linux,】
I believe most people are learning SCM , All from the most basic 8 position MCU At the beginning . Generally speaking ,8 The most common three series of bit microcontrollers are :51 series 、AVR series 、PIC series .
And some time ago , The group discussed a problem : stay 51 Running on the single chip computer RTOS Does it make sense ?
On this question , Everyone has their own opinions . below , We'll focus on 51 and RTOS Let's talk about it in detail .
About 8 Bit MCU and its performance and resources
8 Bit MCU can be said to be a classic of our generation , Because it doesn't have so many resources , And it's relatively simple , It's a must for many beginners .
1、8 Type of single chip microcomputer
8 There are many kinds of bit microcontrollers , What we know most is 8 Bit MCU , Here is a general term , Generally refers to 8 position MCU.
For example, Intel's is common in the early market 80C51 series 、 Etmer's AT89C51 series 、 Domestic macro crystal STC89C51 series 、STM8 series , And NXP 、 Microchips, etc , These companies have 51 Single chip microcomputer .
Actually , In the early days, many of them were general purpose MCU The semiconductor company of , We all have it at home 51 MCU series , Just with 32 The emergence of single chip microcomputer , A lot of previous 51 SCM has gradually left everyone's field of vision .
2、8 The performance of single chip microcomputer
Besides, under the 8 The performance of single chip microcomputer , The main performance is the main frequency ( Or clock frequency ), Of course, there are other factors that determine performance , For example, the bus bit width .
at present 8 The dominant frequency of a single-chip microcomputer usually ranges from a few megabytes to tens of megabytes , such as STC89C51 The dominant frequency can be as high as 48M:
48M The speed of , Logically speaking, it's not too low . This speed if 32 position MCU, run GUI It's almost OK .
however , This is in 8 Bit 51 On single chip microcomputer , Because of the limitation of bus data bit width 、 No preprocessing, etc , Its performance is relative 32 It's still a lot lower .
Let me put it this way , Run the same program , With 48M Running 51 Single chip microcomputer , It can't run on the same frequency (48M) Of 32 It's a plane ( such as STM32).
Of course ,51 If the single-chip microcomputer uses The highest 48M Main frequency operation , Its performance runs RTOS More than enough .
3、 Storage resources
What we usually call resources , In fact, it also includes peripheral resources , such as ADC、I2C etc. . Because what we're talking about here is RTOS, This is mainly about Flash( For code storage ) and RAM( Run storage ) Resources for .
In the early 51 Single chip microcomputer , Because of the limitations of storage technology ( production Flash and RAM Cost is very high ), Its resources are relatively small . Like the classic AT89C51 There is only :128Bit Of RAM,4K Of Falsh.
however , With the maturity of storage technology , Now? 51 The storage capacity of single chip microcomputer has generally increased , For example, the popular ones on the market STC Single chip microcomputer , Its interior is as high as 8K Of RAM, as well as 64k Of Flash.
Apply to 8 Bit MCU RTOS What are they? ?
It says 8 Bit performance and resources , Now let's talk about what RTOS Can be in 8 Bit single chip microcomputer running .
In the early RTOS, A lot of them are about the popular 8 Bit single-chip microcomputer is adapted ( Bottom drive , routine ), Even if there's no adaptation , Also made some common driver interface , For more people to choose from .
Because now the chip manufacturing technology is mature , And then as demand increases ( More software resources 、 More demanding ), quite a lot RTOS Are generally inclined to 32 Bit MCU, There are some RTOS Yes 8 Bit MCU is not so friendly .
Of course , Now it can be used for 8 Bit MCU RTOS There are still many , It's just that there are some relatively small groups , You don't know that well .
image Small RTOS、Keil Self contained RTX51 Tiny、 Familiar uCOS etc. , These can run in 51 On the single chip microcomputer RTOS.
in addition , image AtomThreads、 Chibios、 CMX-Tiny+、 embOS these RTOS All the 8 Bit single-chip microcomputer is adapted .
I studied before 8 When a , Run over high cut uCOS, It's not a big problem to simply run two tasks .
stay 8 position MCU Run up RTOS Does it make sense ?
Maybe a lot of people think : Now it is 32 The world of single chip microcomputer , Plus 8 The performance and resources of bit MCU are very few , run RTOS Very laborious , So in 8 Bit MCU runs RTOS It doesn't make sense .
Yes , There are such problems . however , In my submission Whether it makes sense depends on the situation , In some cases , stay 8 Bit MCU runs RTOS It still makes sense .
1、 A situation of little significance
Because it's true at the moment 32 position MCU There are advantages in all aspects ,8 Bit microcontroller has acquired shortcomings , In many cases at the moment , stay 51 Running on the single chip computer RTOS It really doesn't mean that much .
such as , One contains various peripheral modules , Dealing with all kinds of business logic, large system , It's not suitable in this case 8 Bit MCU and running on it RTOS.
And so on , A very simple system , Like collecting a temperature value , Unit system transmitted through serial port . Because simple projects use RTOS It adds extra complexity to the system .
2、 Meaningful situations
In my submission , The existence of a thing must have its significance .
Like for learning , I think it's more significant , After all RTOS There is a big difference between programming thinking and bare metal thinking .
Maybe some beginners have mastered 51 Knowledge of single chip microcomputer , Want to learn RTOS, At this time in 51 Running on the single chip computer RTOS It makes sense .
Also like , A relatively less complex project , Its peripheral modules ( Or resources ) It's used a lot , meanwhile , The overall business logic is not that complicated , It's not required to deal with too many events . Like collecting temperature 、 Humidity transmission 、 Key detection and other small items , adopt RTOS Each task runs in a modular way , I think it's more meaningful .
Last , Or that sentence , Does it make sense , It's also about your actual situation .
END
source :strongerHuang
The copyright belongs to the original author , If there is any infringement , Please contact to delete .
▍ Recommended reading
边栏推荐
- 当前系统缺少NTFS格式转换器(convert.exe)
- Kali2021 installation and basic configuration
- Flink parsing (V): state and state backend
- 虚拟机启动提示Probing EDD (edd=off to disable)错误
- C # nanoframework lighting and key esp32
- C WinForm series button easy to use
- OliveTin能在网页上安全运行shell命令(上)
- Nodejs 开发者路线图 2022 零基础学习指南
- The solution to the left-right sliding conflict caused by nesting Baidu MapView in the fragment of viewpager
- Automatic operation and maintenance sharp weapon ansible Foundation
猜你喜欢
Flink analysis (II): analysis of backpressure mechanism
分布式(一致性协议)之领导人选举( DotNext.Net.Cluster 实现Raft 选举 )
Basic configuration and use of spark
Automatic operation and maintenance sharp weapon ansible Foundation
Summary of Android interview questions of Dachang in 2022 (I) (including answers)
传统家装有落差,VR全景家装让你体验新房落成效果
[getting started with MySQL] fourth, explore operators in MySQL with Kiko
C version selenium operation chrome full screen mode display (F11)
Easy introduction to SQL (1): addition, deletion, modification and simple query
【MySQL入门】第一话 · 初入“数据库”大陆
随机推荐
scratch疫情隔离和核酸检测模拟 电子学会图形化编程scratch等级考试三级真题和答案解析2022年6月
Solution qui ne peut pas être retournée après la mise à jour du navigateur Web flutter
After entering Alibaba for the interview and returning with a salary of 35K, I summarized an interview question of Alibaba test engineer
MySQL stored procedure
虚拟机启动提示Probing EDD (edd=off to disable)错误
The solution to the left-right sliding conflict caused by nesting Baidu MapView in the fragment of viewpager
远程代码执行渗透测试——B模块测试
Interpretation of Flink source code (I): Interpretation of streamgraph source code
JMeter interface test response data garbled
[ASM] introduction and use of bytecode operation classwriter class
MySQL error reporting solution
Awk command exercise
Chrome prompts the solution of "your company management" (the startup page is bound to the company's official website and cannot be modified)
Summary of Android interview questions of Dachang in 2022 (II) (including answers)
[translation] principle analysis of X Window Manager (I)
酷雷曼多种AI数字人形象,打造科技感VR虚拟展厅
Xin'an Second Edition: Chapter 25 mobile application security requirements analysis and security protection engineering learning notes
Vscode matches and replaces the brackets
[getting started with MySQL] fourth, explore operators in MySQL with Kiko
Interview shock 62: what are the precautions for group by?