error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post here all questions related to STM32 core if you can't find a relevant section!
Post Reply
divner
Posts: 3
Joined: Fri Feb 07, 2020 4:44 am

error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post by divner »

Hi,

I am endeavoring to upgrade an existing project which uses hardware timer interrupts from version 1.4.0 arduino_stm32_core to version
2.0.0 of the core.
The attached sketch is an abbreviated example sketch which compiles ok with version 1.4.0 core and compiler but fails with the 2.0.0 core.
I have also attached a working build log and a failing build log in the attached zip file.

The problem seems to be the "static stimer_t TimHandle;" and seems to with the upgrade to version 2.0.0.

Appreciate some help in what changes are required to the sketch to correct the problem.

Thanks and Best regards,

Noel Diviney
Attachments
DinRDuino2.zip
(21.15 KiB) Downloaded 172 times
by ABOSTM » Wed Dec 08, 2021 8:37 am
Hi @divner,
Yes, things have changed around timer since version 1.8.0
We now have a more complete HardwareTimer driver available.
Have a look to wiki: https://github.com/stm32duino/wiki/wiki ... er-library
and especially the example section https://github.com/stm32duino/wiki/wiki ... 4-examples
As you only need interrupt callback, example "Timebase_callback.ino" should match your needs.
Go to full post
ABOSTM
Posts: 60
Joined: Wed Jan 08, 2020 8:40 am
Answers: 7

Re: error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post by ABOSTM »

Hi @divner,
Yes, things have changed around timer since version 1.8.0
We now have a more complete HardwareTimer driver available.
Have a look to wiki: https://github.com/stm32duino/wiki/wiki ... er-library
and especially the example section https://github.com/stm32duino/wiki/wiki ... 4-examples
As you only need interrupt callback, example "Timebase_callback.ino" should match your needs.
divner
Posts: 3
Joined: Fri Feb 07, 2020 4:44 am

Re: error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post by divner »

Hello ABOSTM,

Thank you for the advice and the links to the examples.
I will report back on my progress.

Best regards Noel Diviney.
divner
Posts: 3
Joined: Fri Feb 07, 2020 4:44 am

Re: error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post by divner »

Hello @ABOSTM

Good news. I have been able to get the Timebase_Callback.ino example on my custom STM32 F427ZIT6 board working thanks to your much appreciated help and guidance. I had a minor issue in thinking that I needed to install a Library until I realised that it is all part of the core now. Yes, al lot of water under the bridge since version 1.4.0.
I am now migrating my DinRDuino sketch to use the new Timer functionality.
DinRDuino is our Din Rail Factory automation product using Arduino. Pinmapping is being rejigged to folow the DinRail Pinouts.

I am a big fan of ST's offerings.

Many thanks once again.
Best regards Noel Diviney
ABOSTM
Posts: 60
Joined: Wed Jan 08, 2020 8:40 am
Answers: 7

Re: error: 'stimer_t' does not name a type; did you mean 'timer_t'?

Post by ABOSTM »

Great !!
Thanks for the feedback
Post Reply

Return to “General discussion”