how to support the fine resolution for STM32 + UCOSII

how to support the fine resolution for STM32 + UCOSII

Home Forums Real-Time Kernels how to support the fine resolution for STM32 + UCOSII

This topic contains 3 replies, has 3 voices, and was last updated by  Farukh Chaudhry 1 year, 7 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #23709

    shpra18@gmail.com
    Participant

    Hi,

    I need to support nano seconds resolution for the PWM on my STM32 custom board,

    how it can be done in uCOSII , Can someone point to an example perhaps? which functions to use and how to aupport from the BSP/port side(uC-CPU)

    Thanks in advance

    #23998

    Janos Magasrevy
    Keymaster

    The finest resolution you’ll get with uCOS-II is milliseconds. For nanoseconds, you will have to resort to a hardware timer.

    #24006

    shpra18@gmail.com
    Participant

    thanks,

    suppose I use stm32 with ucosii running, can you please tell me how to implement a hardware timer
    for 1 ns resolution

    should that HW timer be provided to the OS just like how we provide a HW timer for the Tick timer?

    Can you please share an example , I need this timer for outputting a PWM signal at 100 MHZ

    #24150

    Farukh Chaudhry
    Participant

    Hello,

    Which STM32 family are you using? In order to generate a 100MHz PWM signal, the timer channel will need a clock frequency of 100MHz with no prescaler. Setting up the PWM is easy using STM32CubeMX, but you must make sure to setup the timer clock for 100Mhz.

    Regards,

    Farukh

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

View the complete site map

x
Loading...