Ремонт: Ноутбуков, Компьютеров
https://vlab.su/

Modification of the led VA meter on the HC32F003 chip (4 bit, 0-100V, 0-10A)
https://vlab.su/viewtopic.php?f=4&t=103733
Страница 1 из 1

qazxsw [ 12 июн 2020, 17:13 ]
Заголовок сообщения:  Modification of the led VA meter on the HC32F003 chip (4 bit, 0-100V, 0-10A)

Hello all.
Some time ago I bought a LED current and voltage meter on the Chinese side (4 bit, 0-100V, 0-10A). According to the description, he was to provide values ​​at a frequency of 3 times per second. It turned out differently, i.e. he gave them less than once a second, which was unacceptable to my uses.
The meter is constructed on the HC32F003 processor. On Chinese sites I found full documentation, SDK and utilities for this processor. I decided to play with him.
An attempt to connect using the SWD connector failed. This had to be done using the serial port. It worked, but the flash could not be read - it was protected. So one thing remained - erase the flash and write the software from the beginning, which I did. By the way, I modified the system to measure from 0-30V. Wiring diagram:
Изображение
What difficulties did I encounter? The dedicated program did not detect my processor on any usb adapter - serial (I tried on PL2303 and CH340). The FlyMcu program detected the system on PL2303 but I don't remember why I didn't use it to delete the system (didn't allow it?). Ultimately, I deleted the flash on a Linux computer using a Python program. Now I had full access to the processor. I programmed and debugged it through the already active SWD port using J-Link (how to make a Blue Pill J-Link adapter can be found on the network).
As a result of my scribble (I'm not a programmer) I have a meter that gives values ​​very quickly, and does it more accurately than on the original software. The measurement frequency can be modified by changing the byte in the flash.bin file under offset 0xbee (in the range 1-255).
Software and flash memory included.
Greetings to all.

Страница 1 из 1 Часовой пояс: UTC + 4 часа
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/