This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Bugs M0 M1 M4

Hi.
Sorry my English, "google" style :)
Found bugs in the Cortex M0, M3, M4 series controllers STMicroelectronics brand. I’m a hobbyist, so far I’m only using chips from this company.
I ask the question here because the bug appears in the handler mode, not in thread mode, and because I have already asked the question of the st-community and received such an answer:"What is wrong about it? What should it do instead, and why?" :) :)
For STM32VLDISCOVERY board with stm32f100RB chip assembler code is:

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;STM32VLDISCOVERY board
;Clock: HSI 8MHz
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
GET ../inc/stm32f100x.asm
Stack_Size * 0x00000400
AREA Stack,NOINIT,READWRITE
Stack_Mem % Stack_Size
__initial_sp
AREA Reset,CODE,READONLY
EXPORT __Vectors
__Vectors
& __initial_sp
& Reset_Handler
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

In the tread mode code block:

Fullscreen
1
2
3
4
mov32 r2,#0x7A1200 ; LED on pin C9 is lit
ledC9_ON ;
subs r2,#1 ; withing 3 seconds
BNE ledC9_ON ; *****************
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

runs in 3 sec. USART does not have abnormal behavior.

In handler mode, external interrupt EXTI0, also it's ok if APB2 prescaler is 0 or 2. BUT if APB2 prescaler is 4 or higher the mentioned above code runs in 6 sec and USART, in one byte mode, sents byte TWICE.
I found these bugs on chip stm32f100RB rev Z, stm32f030f4 rev A, stm32f051C8 rev B. But two last chips, cortex-M0 arc run code for 4 second in thread mode.

Chip stm32f303VC rev Y (STM32F3DISCOVERY board) has little different behavior. It's bugs appear for all value APB2 prescaler.

СПС

0