This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/TM4C1294NCPDT: How to create 1 second delay and interfacing with drv8308 inquiry

Part Number: TM4C1294NCPDT
Other Parts Discussed in Thread: DRV8308

Tool/software: Code Composer Studio

Hi Team,

We have a customer inquiry regarding his application with TM4C1294NCPDT and interfacing to drv8308 below:

1. How to create 1-second delay with TM4C1294NCPDT 
2. The customer needs manual rpm set for drv8308 using tm4c1294ncpdt and also needs CCS program for manual rpm set.

Please let me know if you have any questions with the customer.

Thanks!

Jonathan 

  • Hi Jonathan,

      Is this a one time 1-second delay? If you want a 1-second delay using software you can use SysCtlDelay(). Below is an example. Of course you can also use the hardware timer (e.g. GPTM module) to create a 1-second delay. The disadvantage of using software delay is that the function may be interrupted and cause the delay to be less accurate. If your application does not need to worry about interruption while the software delay is being executed then you should be fine. 

      

    g_ui32SysClock = MAP_SysCtlClockFreqSet((SYSCTL_XTAL_25MHZ |
    SYSCTL_OSC_MAIN | SYSCTL_USE_PLL |
    SYSCTL_CFG_VCO_480), 120000000);

    SysCtlDelay(g_ui32SysClock / 3); // This will create a 1 second delay. A SysCtlDelay(g_ui32SysClock / 1) will give 3 seconds. 

    [Edit]

     Sorry, I didn't see your second question. I don't understand the second question about setting RPM using CCS. If this is some feature offered through CCS then I don't know about it.You might want to post your question to CCS.  If this is specific to the DRV8308 then please your question to https://e2e.ti.com/support/motor-drivers/f/38. I can only answer question for the TM4C129 MCU. 

  • Hi Charles,

    Thank you for your support.

    I will share your answer in the 1st question to the customer.
    For the second question, I will create a separate thread for this.

    I will let you know if this will resolve the customer inquiry.

    Regards,

    Jonathan