Hello there,
i´m invoking the TMU´s ARCTAN function and wanted to clarify my understanding of what the the input / output ranges reflect.I have read the document spruhs1a "TMS320C28x Extended Instruction Sets"
and found on page 400 the example for the ARCTAN (see below).
Question 1: if i get the red marked lines right, the TMU´s input range applies to +/- 45degree on the unity circle?
For example for __atanpuf32(1.0) i get the 0.125 | if i do the multiplication from the red marked lines i get 0.7853 radians | A radian is around 57.296 degree. So 0.7853*57.293 is around 45°.
Question 2: Does that mean, i can only deal with arguments, that "end up" between +/-45 degree, or is there a workaround?
best regards!
Example ;; Calculate ATAN and generate Per Unit value and
;; convert to Radians:
MOV32 R0H,@AtanValue ; R0H = Atan Value
ATANPUF32 R1H,R0H ; R1H = ATANPU(R0H)
NOP ; pipeline delay
NOP ; pipeline delay
NOP ; pipeline delay
MPY2PIF32 R2H,R1H ; R2H = R1H * 2pi
; = Radian value
NOP ; pipeline delay
MOV @RadianValue,R2H ; Store result