APM32F103Cx MCU Board - dimaatmelodromru/techdoc GitHub Wiki

APM32F103Cx MCU Board

APM32F103Cx MCU Board is an advanced version of our popular STM32F103CxT6 boards. It features a more advanced Apexmic APM32 microcontroller IC with a higher oscillator frequency and a built-in FPU. The FPU of APM32 is a coprocessor unit specially used for floating point operation, which is attached to AHB bus. It can efficiently handle complex floating point operation, such as decoding algorithm for scanning gun, closed-loop control for motor, PID algorithm, fast Fourier transform, etc., which accelerates the processing capacity of the system.

Similarity

  • Pin Definition: The pins with same packages have the same definitions, and the new added function is completed by Pin Reuse.
  • Memory Mapping: Memory and register have the same addresses, with new functions occupying the reserved address area.
  • Compiling Environment: They have the same compiling simulation tools for compiling by keil and downloading by JTAG.  Library Function and Sample Application: They apply the same library function and sample application, and the new functions can be achieved by adding the corresponding driver file.

Differences

System

M3 Core:

  • APM32 applies the latest version of the M3 core with a separate FPU unit added, which enables for single-precision floating-point operation.
  • The Sxx32 M3 core is an older version with higher power consumption and no FPU unit.

Clock

  • HSE dominant frequency:

    APM32 nominal frequency is up to 96MHz

    Sxx32 nominal frequency 72MHz

  • HSI dominant frequency:

    APM32 dominant frequency is up to 64MHz, clock accuracy is ±1%

    Sxx32 dominant frequency is up to 64MHz, clock accuracy is ±(1.1~1.8)%

Note: Please pay attention to the accuracy of HSI clock when using an High Speed Internal Clock at high or low temperature.

  • HSE run-up time:

    AAPM32 HSE Run-up time recommend to set 0x3200,maximum value is 0xFFFF

    Sxx32 Run-up time recommend to set 0x0500

Note: HSE run-up time: Under the standard crystal oscillator circuit, the measured values of SU(HSE) of APM32 and Sxx32 are both less than 2ms, but the oscillation starting can be easily affected by external circuit and crystal oscillator parameters. The oscillator cannot be started when the Timeout is set as 0x0500, which may concerns the external circuit and oscillator model. In order to ensure the normal starting of oscillation, the macro definition of HSE_STARTUP_TIMEOUT can be modified.The V3.x version library function, macro definition is in the XXX32F10x.h; the libraries before V3.0, macro definition is in the XXX32f10x_RCC.c.The crystal oscillator circuit is suggested to be: (the capacitance value should match the indicated crystal oscillator model):

#define HSE_STARTUP_TIMEOUT ((uint16_t)0x3200) (suggested 0x3200, maximum 0xffff)

Flash

  • Flash Erasing Speed:

    The 1KB pages erasing speed of APM32 Flash is about 90% faster than that of Sxx32.

  • Flash Programming speed:

    The 16bit programming speed of APM32 Flash is about 65% faster than that of Sxx32.

  • Flash Access Speed:

    The wait cycle to insert Flash in FLASH_ACT register is strictly set in accordance with the product specification.

  • Relation between APM32 system frequency and the wait time to access Flash (practical test, standard setting suggested by Sxx32):

    0 wait cycle, when 0<SYSCLK<24MHz

    1 wait cycle, when 24<SYSCLK<48MHz

    2 wait cycle, when 48<SYSCLK<72MHz

    3 wait cycle, when 72<SYSCLK<96MHz 

  • Relation between Sxx32 system frequency and the wait time to access Flash (the reliability is not guaranteed when Sxx32 using is out of specification):

    0 wait cycle, when 0<SYSCLK<56MHz

    1 wait cycle, when 56<SYSCLK<72MHz

Note: APM adopted the advanced eFlash technology, having faster speed in Flash erasing and programming. The Flash reading speed is different from that of Sxx32, and should be strictly set in accordance with the above parameters.

The Code Running Speed

The APM and Sxx32 have different speed in code running. The comparison for them is as following (dominant frequency 48MHz):

Delay Type i++ For Loop While Loop Calling function for loop Calling function while loop
APM32F103VB 79.68us 63.08us 63.12us 63.28us 63.28us
Sxx32F103VB 79.68us 52.8us 63.16us 63.36us 52.96us

Note: Please note that there will be error occurred in the accurate time for while & for loop delays.

Peripheral

  • QSPI Interface:

    QSPI was added to APM32E series, which supports Standard SPI mode and Quad SPI mode;

    Sxx32 has no QSPI

  • Use both USB and CAN

    USB and CAN of APM32 can be used simultaneously;

    USB and CAN of Sxx32 cannot be used simultaneously

  • WFE Event Interrupt

    As APM32F103 will fail to execute the first WFE instruction, only the second WFE instruction can work properly. It is because of the different version of M3 core.  Sxx32 executes WFE instruction only once.

  • SPI

    When APM32 SPI interface operates, changing parameter configuration without turning off SPI Enable will lead to SPI clock disorder. The normal steps in SPI parameter configuration are to firstly close SPI enable, modify SPI configuration, then turn on SPI enable.  SPI clock will be normal when Sxx32 SPI interface is operated as above steps.

  • GPIO

    The GPIO of APM32 needs to enable internal pull-up resistance by software or add external pull-up resistance when the output is at high power level, otherwise, the output voltage may be affected by the external environment and cannot output stable level.  The GPIO of Sxx32 is stable by default and does not need special configuration.

Electrical Characteristics

  • Power Consumption:

    The operating power consumption of APM32 is about 30% lower than that of Sxx32

    The sleep power consumption of APM32 is about 10% lower than that of Sxx32

    The shutdown power consumption of APM32 is similar to that of Sxx32

    The standby power consumption of APM32 is 23%~50% higher than that of Sxx32. This parameter will be optimized in the next version  The power consumption of APM32 backup battery is similar to that of Sxx32

  • ESD

    In the ESD MM (machine mode) mode of APM32, the voltage of PC13, PC14, and PC15 can only reach about 130V. During PCBA processing, if the equipment AC leaks over 130V, EOS may occur damage in APM32.

  • Radio Frequency Interference

    Please take the design of GND, power routing, and decoupling capacitor into consideration when planning the APM32 and RF chip Layout.

Software

There are a lot of useful resources available on the Apex Micro (apexmic.com) product page: tool chain, SDK, libraries, etc. in the Download Resources section.

⚠️ **GitHub.com Fallback** ⚠️