logo elektroda
logo elektroda
X
logo elektroda
Dostępna jest polska wersja

Czy wolisz polską wersję strony elektroda?

Nie, dziękuję Przekieruj mnie tam

HK32F030M - Chinese ARM for 15 cents

piotr_go 17940 60

TL;DR

  • HK32F030M is a Cortex-M0 Chinese microcontroller with an STM8S-like pinout, not an STM32F030 clone.
  • It provides 16kB Flash, 2kB RAM, 448B EEPROM, SPI/I2C/USART/ADC, three 16-bit timers, and a 32MHz HSI.
  • Compared with STM32F030, it lacks DMA, PLL, and external quartz support, while adding a BEEPER peripheral.
  • J-Link needs manual JLinkDevices.xml entries plus attached .FLM loaders because HK32F030M is not supported out of the box.
  • A hello-world and LED-blink demo worked, with LED1–4 on PC4–PC7 and UART TX on PA3 at 9600 baud.
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
📢 Listen (AI):
  • #61 20602976
    dabyd64
    Level 10  
    Final board :)

    Quote:


    Rest are common parts easily sourced anywhere, 0402 resistors / capacitors, pin headers, 25xx/24xx memories...

    Edit: Fix PCB
    - Missing GND trace for CH340E.
    - CH340E RTS/DTR not working as expected, remove them.
    Attachments:
    • HK32F030M - Chinese ARM for 15 cents IMG_20230630_202656_1_1280x960.jpg (322.81 KB) You must be logged in to download this attachment.
    • HK32F030M - Chinese ARM for 15 cents IMG_20230630_202624_1_1280x960.jpg (219.1 KB) You must be logged in to download this attachment.
    • HK32F030MF4P6_GERBER_6x2_PANEL.7z (2.41 MB) You must be logged in to download this attachment.
    • HK32F030M - Chinese ARM for 15 cents Untitled_Combined_Top.png (442.07 KB) You must be logged in to download this attachment.
    • HK32F030M - Chinese ARM for 15 cents Untitled_Combined_Bottom.png (412.69 KB) You must be logged in to download this attachment.
    • HK32F030MF4P6_GERBER_SINGLE.zip (100.8 KB) You must be logged in to download this attachment.
    • HK32F030M - Chinese ARM for 15 cents HK32F030MF4P6_3D.png (289.98 KB) You must be logged in to download this attachment.
    • HK32F030M - Chinese ARM for 15 cents HK32F030MF4P6_SCH.png (114.44 KB) You must be logged in to download this attachment.
  • ADVERTISEMENT
📢 Listen (AI):

Topic summary

✨ The HK32F030M is a low-cost Chinese ARM Cortex M0 microcontroller priced at 15 cents, featuring a pinout similar to STM8S microcontrollers. It includes 16kB Flash, 2kB RAM, and 448B EEPROM, with SPI, I2C, USART, and ADC interfaces, but lacks DMA, PLL, and external quartz support. Users discuss the licensing of ARM technology, the competitive pricing of Chinese microcontrollers compared to Western counterparts, and the availability of programming resources. Some users have successfully tested the HK32F030M, noting differences in GPIO functionality and power consumption. The discussion also touches on the potential for Arduino compatibility and the challenges of finding adequate documentation and libraries for development.

FAQ

TL;DR: HK32F030M MCUs ship for $0.15 per 1 000 units and run a 32 MHz Cortex-M0 core; “there is no competition” [Elektroda, piotr_go, post #18941722] Boards kept blinking up to 7 V before failure [Elektroda, piotr_go, post #19358946]

Why it matters: Ultra-low pricing plus ARM IP make these chips tempting drop-in upgrades for 8-bit designs.

Quick Facts

• Core: ARM Cortex-M0, 32 MHz internal HSI [Elektroda, piotr_go, post #18941722] • Memory: 16 kB Flash, 4 kB RAM, 448 B EEPROM (newer silicon) [Elektroda, BlueDraco, post #19167018] • Price: USD 0.15 @ 1 k pcs; recent lots ≈ 0.20 USD [Elektroda, piotr_go, post #19007720] • Typical active current: 3.06 mA @ 32 MHz, 3.3 V [Elektroda, piotr_go, post #19374070] • Package quirks: early SO-8 had NRST on pin 6, later on pin 7 [Elektroda, piotr_go, post #19171083]

What makes HK32F030M different from STM32F030?

HK32F030M keeps the same Cortex-M0 core but drops DMA, PLL and external crystal support, adds a beeper like STM8S, and limits timers to three 16-bit units [Elektroda, piotr_go, post #18941722]

Will STM32F0 firmware run unmodified?

Peripheral base addresses match, yet register bitfields differ; expect to patch code and headers before it boots correctly [Elektroda, piotr_go, post #18941722]

How do I flash and debug the chip with J-Link?

  1. Add the XML snippet posted in the thread to JLinkDevices.xml.
  2. Place the three .FLM loaders in Devices/HK32F030M/.
  3. Connect SWD and power, then program via J-Link commander [Elektroda, piotr_go, post #18941722]

Can I power it from 5 V?

Yes. One unit survived an hour at 5 V and only mis-behaved above 7 V, though this exceeds absolute-max ratings and risks latent damage [Elektroda, piotr_go, post #19358946]

What about Arduino Core support?

No vendor core exists yet. Porting is feasible because register sets resemble STM32F030; UART bootloaders work, but USB DFU is absent [Elektroda, khoam, post #18948238]

How accurate is the 32 MHz HSI?

Datasheet gives ±1 % (typ.); developers have overclocked to 48 MHz without wait-states and even 96 MHz with one wait-state via HSICAL tweaks [Elektroda, dabyd64, post #20598122]

Is on-chip EEPROM reliable?

Users report erase/write works, but page 0xC000000 maps over Flash in the current reference manual, so test thoroughly before field use [Elektroda, BlueDraco, post #19168967]

How do I generate a minimal UART bootloader?

  1. Enable clock to USART and GPIO.
  2. Map PA3 (TX) and PA2 (RX) to AF.
  3. Implement XMODEM receive and write 128-byte frames to Flash pages (128 B each) [Elektroda, piotr_go, post #18941722]

Edge case: what fails first under stress?

At 7 V supply, code execution glitches before any thermal rise; FLASH content remained intact after the test [Elektroda, piotr_go, post #19358946]

Can I buy them today and where?

LCSC lists HK32F030MF4P6 for CNY 0.80 (≈ USD 0.12) but recent demand raised quotes to USD 0.20 [Elektroda, victoriii, #18943068; piotr_go, #19007720].

Are there 5 V-tolerant or larger-RAM siblings?

Yes: HK32F0301M offers 48 MHz core and 4 kB RAM at the same price, while HC32F005 adds full 5 V operation for slightly more [Elektroda, piotr_go, post #19007720]

What’s a safe development workflow?

“Use Keil with patched .pdsc files; J-Link clones based on BluePill debug fine,” an adopter confirms [Elektroda, dabyd64, post #20598122]
ADVERTISEMENT