Which is more powerful, Arduino or STM32? Many electronics enthusiasts face a dilemma when choosing between Arduino and STM32, unsure of which to use. Arduino has always been popular, but STM32 has more interfaces, stronger performance, and faster speeds?
Features of Arduino and STM32
Arduino:
Arduino leans towards creativity, simplifying hardware operations. Its functions and syntax are very simple and user-friendly. Most Arduino controllers are based on AVR microcontrollers, and its advantages lie in high code encapsulation, fewer required statements, and reduced software development difficulty. Arduino is easy to get started with; anyone with a basic understanding of hardware and C++ can develop. Most of Arduino’s functionalities come with well-prepared libraries, making it simple to use, but for slightly more complex functionalities, its controllability is relatively poor. STM32:
For applications requiring computation or control, STM32 is the better choice. If you buy a development board for STM32, you need to start learning from the hardware level and master its various details. STM32 focuses more on practical engineering. In fact, many simple instruments in factories, such as temperature controllers, regular motor controllers, low-end PLCs, and some consumer toys, game controllers, wired keyboards, and mice, as well as POS machines in college canteens, are widely used. STM32 is primarily designed for professional developers who need certain expertise, but writing code to achieve functionalities is relatively complex. For example, outputting a simple string via serial communication might take 10 lines of code to implement in Arduino, but using STM32’s development tools like Keil may require hundreds of lines of code or more, as illustrated in the serial-related example: pressing a button sends data via serial.Comparison of Arduino and STM32
Arduino has many versions, and their features are not consistent. Taking the most common Arduino UNO R3 as an example, its controller is the AVR 138 microcontroller, which is not on the same performance level as STM32. This model is somewhat similar to Holtek’s STC12 series (only in terms of computation). The Arduino MEGA 2560 is considered the king among Arduino MCUs, with rich interfaces that should be comparable to the STM32F1 series, but it has higher power consumption and noticeable heat generation, while the STM32F1ZET6 in the same package only has slight warmth, and in low ambient temperatures, you may not even feel any heat. Based on the different characteristics of the two, we can compare them based on different applications: In terms of ease of learning: Arduino is much easier than STM32. Required basic programming concepts: Arduino uses object-oriented C++, Java-like syntax, while STM32 primarily uses standard C language for development. Knowledge gained after learning: Arduino is weaker than STM32. This is because Arduino encapsulates many low-level operations. Unless you attempt to write libraries for Arduino and its corresponding circuit modules yourself, you will only remain at the basic programming level.
In terms of open-source capabilities: Products created with STM32 can be open-sourced if desired, or nothing can be disclosed if not. Difficulty level of building peripheral circuits: Arduino is much easier than STM32. Expandability: Arduino and STM32 are comparable; Arduino essentially exposes most of the controller’s pins.
Cost: Assuming you create something with the same functionality, Arduino is more expensive than STM32.
If you are still unsure how to choose, here are some suggestions:
-
If you are an ordinary student without deep knowledge of programming languages, it is recommended to start with Arduino.
-
If your C foundation is weak and you jump straight into STM32, you will quickly feel like giving up.
-
If you are learning just for employment, go for STM32 microcontrollers decisively.
-
If you are learning just for fun, are not from an electronics background, and lack confidence, it is advisable to choose Arduino.
-
If you have a good programming foundation, it is recommended to choose STM32. Once you master it, you can see what the Arduino open-source community has created, and you can easily implement it with STM32.
-
Of course, if you have the ability, try both; generally, within a week, you can grasp the basic features of Arduino, and later, if needed, you can easily port Arduino code to STM32 or other MCU platforms.
In fact, these two platforms target slightly different directions; Arduino is generally chosen by electronics enthusiasts and DIYers, while STM32 is often used for actual product research and development. However, the Arduino series now also supports STM32 chips, allowing you to use the Arduino development environment for programming after downloading Arduino firmware. It is most important to choose what suits your project type and needs.
1. Artificial intelligence can also be implemented in resource-constrained embedded systems!
2. Use Edge Impulse for MCU machine learning, give it a try~
3. What are the differences between hex files, bin files, and axf files?
4. Why are global variables the norm in C language development for microcontrollers?
5. Visual Studio makes embedded development more appealing.
6. The first phase of the European processor project is completed: 29 RISC-V cores.
Disclaimer: This article is a network reprint, and the copyright belongs to the original author. If there are copyright issues, please contact us, and we will confirm the copyright based on the materials you provide and pay remuneration or delete the content.
Leave a Comment
Your email address will not be published. Required fields are marked *