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.

SYSBIOS HWI dispatcher and targeting user-defined trap : C28xx

Other Parts Discussed in Thread: SYSBIOS

CCS v5.40
ControlSuite v3.21
Compiler version TI 6.1.3
SYSBIOS v6.35.3.47
XDCTools v3.25.2.70

Device : TMS320F28069

Attempting to create a HWI targeting one of the User-Defined Traps.  In particular, I am targeting USER1 which has a vector ID = 20.  The SYSBIOS configuration tool gives me the following error when attempting to do this.

Error (2 items)
  intNum = 20 can't be assigned to the dispatcher
  Vector ID = 20 is not a valid vector ID

The reason I want to create a HWI for this user-defined trap is to use a methodology described in this app note for creating a hybrid system.  I have a need (my customer) for a very low latency interrupt processing, but yet still utilize the scheduler and other services of SYSBIOS.

I plan to plug a hardware interrupt service routine directly, using Hwi_plug(), for the low latency processing.  Within this hardware ISR, it will then determine communication is required to the rest of the SYSBIOS system.  Since SYSBIOS calls can not be made via hardware ISRs using Hwi_plug(), my intention was to signal a user-defined trap.  The intention was for this user-defined trap to utilize the HWI dispatcher and therefore can post a semaphore to a task for continued processing.

However, it appears the XCONF will not allow me to target a vector ID 16 < x <31.  I see the code in the Hwi.xs that performs this check.

I would like to not cannibalize a PIE vector for this purpose, however, if this is the only work-around, I will.

  • As a quick workaround, for demonstration purposes, I targeted vector ID = 34, or INT1.3, in the PIE as this is currently not used by any hardware.

    In my example, I then signaled a HWI, connected to vector ID=34, from the hardware ISR.  The HWI then has the ability to post a semaphore for a task to actually perform further processing.

    I would still like to know if there is a possibility of using the User-defined traps for this purpose.

  • SYS/BIOS currently does not support configuring dispatched interrupts for intNums in the range from 16-31.

    The approach you've taken seems to be the suggested method in the appnote you sited.

    I'm not familiar with C28 user traps. Are these invoked programatically? Once triggered, do they need to be acknowledged somehow?

    Alan