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.

Software blocked in the b dataEntry line of the sys_intvecs.asm file.

Other Parts Discussed in Thread: HALCOGEN

Hello all,

Is there someone to explain me why I am blocked in the b dataEntry line ?

I work on the TMX570 HDK with halcogen. I inittialize an interruption whit the RTI on ADC 1 group1, get the adc values and excute a function.

my Fifosize is 1000 and my ADC array is 1000 size.

The problem is when I run the in debug mode and hold the soft after a while I realise that I am locked in the sys_intvecs.asm file.

It run fine when I disable a loop which copy the 1000 datas in another array.

Is it a problem of memory management or interruption ?

Thank you all,

regards.

Brice

 

  • Brice,

    If your code ends up in the intvecs b dataEntry that means an illegal data access as been performed.

    On DATA abort, the CPU saves in the link register (R14) the address of the instruction responsible for this abort.
    Once you reach the abort, copy the value of LR in PC. You should be able to debug and see what is going on.

    If you can share your code, I can have a look.

  • Hello Jean-Marc,

     

    Thank you very much for your quick answer,

    I provided my code in option,

    I am looking forward to you answer.

    Regards,

    Brice

  • Brice,

    Sorry for this late answer, but I was out these last 2 week.

    In your last post, you mentioned attaching your code. There is no attachment. Can you resend it?

  • Hello Jean-Marc,

    Don't worry,

    I finally manage to fix this problem,

    -> I had an overun of the interrupt handler, so what i did to fix it  is :

    in rtiNotification : 

    rtiDisableNotification(...);

    code;

    rtiEnableNotification;

    But there is something I still don't understand with the adc (sorry I am a bit unexperiment on this subject) :

    In Halcogen(03.03.01) I enable the ADC1 group 1 on pin 0 and 1, to get the signals from an EncoderAB. Initially, I put a the Fifo Size to 1000 to fill a 1000 arrays of adc values, and put the adc1 memory to 64 on my adc1 group1.

    -> I enable a discharge of 100 ns, and the total time is 3.2625 ns (I guess it is to get the 2 adc values on pin 0 and 1)

    -> so I put the rti compare0 to 3.263 ms (= 3.2625 ns x 1000 values) in order to get 1000 values of adc at each interrupts.

    when I run my program, I can see that 64 values are well produced (Vpin0 ; pin1; pin0; pin1... pin0;pin1) but after this 64 values I hvae got some erroned value.

    I guess that the Fifo size here is not 1000 but 64 (?)

    To test this I add this test in the adcGetValue inside the "for" loop     

    for (i = 0; i < count; i++)

    uint32_t fifofull = adcIsFifoFull(adc, group); 

    uint32_t tst = adc->G1SR & 0x00000008;

    if (tst == 0)

    {

    WHAT THE LOOP DID BEFORE

    }

    else

    {

    /*WHEN I = 64  I REACH THIS BRANCH*/

    ptr->value = 0;

    ptr->id    = 99;

    }

    I verify this way that the ADC Group1 Status Register (ADG1SR) doesn't contain valid conversion values after 64

    Can you help on this ? 

    (I use the RTI compare zero to perform an interrupt  )

     

    DualADC.zip