Search found 33 matches
Re: STM8
i'm a big fan of those little beasts: stm8s003 and stm32f030. but the 8s has limited utility as an arduino clone - as the space is quite limited, especially if you compile with a free compiler. under iar, they work wonders.
- Wed Jan 06, 2021 12:47 am
- Forum: General discussion
- Topic: Compensate for LSE error
- Replies: 10
- Views: 557
Re: Compensate for LSE error
i would first make sure that the hardware works - the right crystal is used, and the LSE oscillates in run mode correctly, ... I would then try to find out if the code is wrong -> it would be unthinkable if this is a (chip) hardware problem. all else fails, I would try to correct the problem. the si...
- Fri Dec 25, 2020 2:18 am
- Forum: General discussion
- Topic: Compensate for LSE error
- Replies: 10
- Views: 557
Re: Compensate for LSE error
unless you are using something truly bad, those crystals are spec'd to 20ppm and usually within 5ppm. so 5% is a little extraordinary. I would first verify the cause. if it is indeed in the crystal, the hardware does allow LSE compensation - look to the reference manual. but unlikely to the extent o...
- Fri Nov 27, 2020 11:53 pm
- Forum: General discussion
- Topic: incorrect micros() value for stm32f411re
- Replies: 18
- Views: 1574
Re: incorrect micros() value for stm32f411re
those chips have DWT and you can get timing resolution down to ns -> at 72Mhz, you get 13.9nsstm32f1
- Thu Nov 26, 2020 9:00 pm
- Forum: STM8 Core
- Topic: How to use Interrupts on STM8 with sduino
- Replies: 3
- Views: 1514
Re: How to use Interrupts on STM8 with sduino
or you can set the CR2 bits. CR1 bits enable pull-up.GPIO_Init (an STM8-specific API function) to actually enable interrupts for a particular pin.
- Thu Nov 26, 2020 8:53 pm
- Forum: General discussion
- Topic: how to PWM Frequency stm32duino and resolution
- Replies: 10
- Views: 7058
Re: how to PWM Frequency stm32duino and resolution
it might be simpler to just check the 1k-page reference manual. most of those bits are in CCER but there should be a section on the right bits for all of that.I know all the registers to use, I get bit arithmetics, but what is the syntax?
beats out going through the HAL functions.
- Thu Nov 26, 2020 12:52 am
- Forum: Ideas & suggestions
- Topic: Bare metal STM32 programming
- Replies: 23
- Views: 6783
Re: Bare metal STM32 programming
you can always code assembly. or even hand-generate binary.Bare Metal is the closest you can get to the processor,
I usually code to cmsis. it has the most portability.A potential problem about Bare Metal is how portable your code will be.
- Thu Nov 26, 2020 12:48 am
- Forum: General discussion
- Topic: incorrect micros() value for stm32f411re
- Replies: 18
- Views: 1574
Re: incorrect micros() value for stm32f411re
you will notice that your reading changes a little bit, partly because of the sequence of reading the timer can differ based on if you are trying to read the leading edge or the trailing edge.result
one way to do that is to always read the timer first in the isr
- Mon Sep 21, 2020 12:15 am
- Forum: General discussion
- Topic: analogRead showing a digital behaviour
- Replies: 6
- Views: 906
Re: analogRead showing a digital behaviour
analogwrite() produces a digital output whose duty cycle carries the analog information.
what you observed is expected.
what you observed is expected.
- Sat Sep 19, 2020 5:55 pm
- Forum: Ideas & suggestions
- Topic: Bare metal STM32 programming
- Replies: 23
- Views: 6783
Re: Bare metal STM32 programming
most of the code you find will be developed against CMSIS and a set of vendor header files. so I would encourage you to at least try to align there.