【Project inspiration】
Based on the video of station b’s UP master @日出东水Studio . AIDA64extreme is used as the host computer, the STM32F103C8T6 core board is used as the controller, and the project program is rewritten based on Arduino.
Original author's project link: https://www.bilibili.com/video/BV1jL4y1x7gx?spm_id_from=333.999.0.0
Original author project GitHub: github.com/ShaderFallback/CpuRamGet
[Project improvement content]
1. Using AIDA64extreme as the host computer software, you can obtain more parameter information including CPU, memory, GPU, battery voltage, hard disk usage, etc. You can modify the program DIY yourself to create more possibilities.
2. It uses serial communication and is connected to the computer through the USB port. It can also be used on desktop computers without wifi network cards.
3. The STM32F103C8T6 core board serves as the controller.
(1) Because the USB port output voltage of each computer is different, it is not necessarily the standard 5V output. When using PWM to simulate the DAC output, it will affect the output accuracy. Therefore, the Arduino NANO or UNO based on the 5v microcontroller is not selected. controller. (Of course, a stable reference voltage can also be provided externally to NANO and UNO, which is relatively troublesome). The STM32F103C8T6 core board has a built-in 3.3v voltage regulator chip, which can ensure that the DAC output is relatively accurate and is not affected by the computer USB voltage.
(2) Due to the increase in the price of ATmega328P microcontroller, the price of domestic Arduino NANO is close to 30 yuan, and the price of STM32F103C8T6 core board stays at around 20 yuan, which is relatively economical.
4. Use Arduino IDE to write programs, there is no complicated register configuration, and the program is easy to modify. (Actually, keil and cubemx cannot be used well o(︶︿︶)o Alas)
5. Support program calibration and fine-tuning voltmeter to improve adaptability.
[Required devices and tools]
1. Tools needed
(1) Electric soldering iron (for soldering pin headers)
(2) Duban line
(3) Any USB serial port downloader, CH340 is recommended
(4) Micro USB data cable (the old Android data cable needs to be equipped with output transmission, but some power banks do not provide data transmission)
2. Device
(1) One STM32F103C8T6 core board. (You cannot buy the domestic chip version, it must be STM32. When buying, you need to pay attention to the model. Don’t buy it as C6T6. Because BOOTLOADER is not compatible)
(2) Two 91C4 model voltmeters, you need to purchase the 3V range version.
【Production process】
1. Set up the Arduino development environment for STM32
You can refer to the tutorial set up at https://blog.csdn.net/xatsoft/article/details/90687016 .
There are several things to note during the construction process that are easily overlooked:
(1) When flashing the bootloader, the core board needs to insert boot0 to the 1 position and boot1 to the 0 position. After the flash is successful, it needs to be restored to the state where both are connected to 0.
(2) After installing the Arduino_STM32 package and installing the driver, you need to install support for Arduino SAM Boards in the Arduino development board manager.
(3) To download the program, you need to select the microcontroller model and serial port as follows (after successfully installing the driver and connecting the development board to the computer through the onboard micro USB, the serial port of Maple Mini can be recognized)
2. Program flashing
Open "CPURAMGET.ino" in the "Program" folder in the project attachment, and follow the instructions in point 1 to download the program.
3. Dial production
(1) You can use the original author’s PHOTOSHOP file to replace the background and create your favorite watch face.
(2) Friends who do not have a color printer can also use a black and white printer to print. If the printed image is too light, you can adjust the contrast and brightness appropriately. The effect is not bad.
(3) If you don’t have a color printer and want to make a color dial, it is recommended to search for “photo printing” service on a certain website. The free shipping price for 8-inch (6R, 15.2*20.3cm) printing is more than 2 yuan, which is quite economical. An 8-inch photo can fit more than 10 dials. You can use the photo printing template in the project attachment to directly replace the made dial, and the size has been adjusted.
4. Dial cutting and production
Disassemble the 91C4 voltmeter and take out the original metal dial. Use scissors to cut the printed dial picture according to the shape of the dial. Use glue to paste the cut dial picture on the surface of the original metal dial. Put the voltmeter back and adjust it. Installation position ensures that the pointer is aligned with 0 o'clock and the dial will not interfere with the movement of the pointer.
5. According to the connection diagram, connect the PA9 and PA10 pins of the STM32 core board to the positive pole of the voltmeter that displays the CPU usage and memory usage. The negative poles of the two voltmeters are connected in parallel and connected to the core board GND.
6. Download the AIDA64extreme software (download from Baidu) and make the following settings:
(1) Connect the STM32 core board to the computer via MICRO USB, and confirm the connected serial number through Arduino IDE.
(2) Open the AIDA64extreme software, open "File" - "Settings"
(3) Select LCD and select the screen as POS
4. Click "LCD Project" on the left and set the screen output parameters according to the following parameters. Or by importing the configuration file provided in the project file.
5. Observe whether the voltmeter pointer position matches the computer's memory and CPU usage.
It can be fine-tuned through the "voltmeter range" and "power supply voltage" in the program. 3.30v is the voltage of the 3.3v output pin of the STM32 core board measured by the multimeter.
6. Use the 3D model of the original author of Station B to 3D print the shell, or use KT board or acrylic board to make the shell yourself.
(1) Currently, according to the original author's annotations, the 3D shell is converted into STL and the size is enlarged to the actual size. It has not yet been printed and tested. It will be shared after subsequent printing and testing (see engineering information for STL files).
[Finished product renderings]
[Write at the end]
1. First of all, thank you to the original author for the creative ideas~
2. This project cannot be used for commercial purposes.
3. The project is some personal production experience and sharing. I don’t know how to use GitHub, so I will share it here.
4. I wish you all have fun. If you have any questions, please leave them in the comments and let’s communicate and learn together~
【Updated on 2022.02.27】
1. Test printed the 3D shell STL file in the engineering attachment, and updated the renderings after installing the 3D printed shell. (The STL in the project attachment can be printed directly, and there is no problem after testing)
2. The STM32F103C6T6 core board was tested and the Arduino32 BootLoader was able to be flashed. However, the micro USB port that comes with the board cannot be recognized as a virtual serial port. If you want to use it, you still need to connect the USB to serial port cable. Not recommended.
All reference designs on this site are sourced from major semiconductor manufacturers or collected online for learning and research. The copyright belongs to the semiconductor manufacturer or the original author. If you believe that the reference design of this site infringes upon your relevant rights and interests, please send us a rights notice. As a neutral platform service provider, we will take measures to delete the relevant content in accordance with relevant laws after receiving the relevant notice from the rights holder. Please send relevant notifications to email: bbs_service@eeworld.com.cn.
It is your responsibility to test the circuit yourself and determine its suitability for you. EEWorld will not be liable for direct, indirect, special, incidental, consequential or punitive damages arising from any cause or anything connected to any reference design used.
Supported by EEWorld Datasheet