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.

TMS570 NHET INTENAC/INTENAS

Other Parts Discussed in Thread: HALCOGEN

Hello,

i'm using the TMS570 and i'm writing a PWM Module.

Therefore, I need to know how the INTENAC/INTENAS Control Registers work. In the User Guide, it says that writing a 1 to bit x enables intterupts of NHET instructions at NHET adresses x+0,x+32,x+64.

Would this be (one instruction is 16 bytes) instruction x, x+2,x+4? Or is it instruction x, x+32, x+64?

I have generated a Code with the HalCoGen tool, but none of these two possibilities would have made sense in the generated instructions..

Thx for your help

  • Hello R. K.

      Let's say you have written a piece of HET code with 64 instructions in it. In this case, instruction 0 and instruction 32 will share the same interrupt flag bit and likewise the same INTENAC/INTENAS bit. Instruction 31 and 63 will share the same interrupt bit in the same concept.

     Please let me know if this answers your question.

    TI Forum Support

     

  • Thx for the reply! This answers my question, but i still have some problems.

    1. I have a PWM, which contains following instructions: PWCNT (Duty Cycle), DJZ (Period), MOV64(update Duty Cycle), MOV64(Update Period)

    So i should for example put the PWCNT as L01 and the DJZ as L33, to have the same bit enabling interrupts for those two instructions?

    2. I'm not sure how to use the MOV64 correctly in order to update duty cycle/period.

    Can you give me an example for either Duty Cycle update or Period update?

    Thx for your help

  • Hello R. K.

      1. Due to the hardware limitation, L01 and L33 will share the same interrupt line. However, this is by no mean to suggest that you create your code, in your example, to have PWCNT and DJZ at L01 and L33 intentionally.

      2.  MOV64 instruction is used to modify both the control field and the data field of a remote address. In your case, you just want to modify the data field of the PWCNT and the DJZ. You can use instructions like MOV32 which modifies only data field of a remote address.

    TI Forum Support