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.

TMS320F28379D: CLB HLC register to counter write problem

Part Number: TMS320F28379D


Hi all!

I'm trying to create receiver for XY2-100 protocol (short description is in attached pdf) using CLB. I have faced problem with transferring data from one of HLC's register to counter using MOV instruction. It simply doesn't write value to counter. It seems to me to be somehow connected with counter's EVENT settings: when it set to shift left, write fails, but when it set to do nothing, write succeed.

To reproduce this problem in-vitro I've made simple counters and HLC setup:

1. Set COUNTER_1 and COUNTER_2 all inputs to constant zero, COUNTER_1 event to none and COUNTER_2 event to shift left:

2. Set HLC register R3 value to 1, event 0 input is boundary.in1 and program 0 is simply two mov's - R3 to C1 and R3 to C2.

3. Compile and run this test program. Feed step to corresponding microcontroller input, then suspend program in CCS and examine CLB debug registers:

COUNTER_1 value now is set to 1, but COUNTER_2 value is still 0.

So I suppose this problem is associated with counter's event setting. Am I right? Is there some workaround for this problem?

Anyway, my main question is: is it possible to create shift register with carry-in input in CLB?

P.S. Why I wish to use CLB for XY2-100 receiver is because there could be many identical data packets in series. I want to compare them using CLB and push only new data packets to CPU. Furthermore, there is parity field in packet and I want to check it in CLB too.

Documents_TD_XY2-100_R0703.pdf