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.

LP-AM243: CCS Timer Interrupt Example or Clock Output

Part Number: LP-AM243

Is there an example in the MC+SDK files that contains a simple timer interrupt routine? I read through timerP.h and could not find a way to attach a function to the interrupt.

Alternatively a way to setup a clock at a specific frequency on a pin would be most useful.

  • Hi Dylan,

    The example benchmark_demo_am64x-evm_r5fss0-1_nortos_ti-arm-clang in ccs_ws_1040_8136\benchmark_demo_am64x-evm_r5fss0-1_nortos_ti-arm-clang has the timer CONFIG_TIMER_BENCHMARKDEMO (DMTIMER2) defined and used. The callback function for DMTIMER2 interrupt is App_timerCallback(). See details in example.syscfg.

    Best regards,

    Ming 

  • While that example provided great insight in how it works, I could not run the example on my board. I tried putting a DebugP_log("tick\r\n"); line to see if it is reaching that callback function and roughly what frequency it is at but the message never comes out. It could have to do with it using IPC or maybe the fact that it is meant for the r5ss0-1 core? I tried running it from that core and it still did not console log anything. 

  • Hi Dylan,

    By default, the benchmark_demo_am64x-evm_r5fss0-1_nortos_ti-arm-clang Debug_log goes to memory log (not UART, check example.syscfg -> "Debug Log"), so that is why you cannot see the print out. Simply check the "Debug Log" ->  "Enable UART Log" to add UART log. keep in mind the timer interrupt happens every 1ms, you may want to reduce the Debug_log frequency to match the UART baud rate.

    Best regards,

    Ming