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.

doubt in adc conversion result

Other Parts Discussed in Thread: RM48L952, HALCOGEN

Hello all,

I have a doubt in adc conversion of rm48l952.

1. If i am giving 3 Inputs to adc channel from 0 to 3 in adc1 group1 and i wanted to sample those signals 5 times and take mean of each channel.( I have used continuous conversion mode and fifo size as 15 ) Since in continuous mode conversion takes place untill fifo is full.  is it correct?

2. How do i store all These values? and Display using SCI.( in the example of rm48x they have used Little endian concept to Display the value) why do we have to do like that.

3. I am trying to implement this is c++ programming. if i use cout to Display the mean value, does the value will be in hexadecimal or decimal.

4. if in future if i want to Display the mean using SCI should i convert the hex to decimal before displaying it.

could anyone please provide a sample program SCI without using Little endian ?

Thanks in advance

  • Jasnaz,

    I have moved your post to the Hercules forum.

  • 1) No in continuous mode the converter will keep converting - over and over. It will overflow the FIFO unless you also have some software that reads out the FIFO. If you want exactly 15 conversions and no more, you can use a timer to or the ADEVT pin to trigger the A/D exactly 3 times.

    2) Not sure what you mean by how to store / display.

    3) in c++ the output will follow the format specifier just like in C. So you can output as you like.
    search for c++ format specifiers - I got a hit here: msdn.microsoft.com/.../75w45ekt.aspx

    4) this is really not related to SCI. You should format for the person or other software that is going to consume the data. The SCI or CIO can handle any format you select.

    See example_sci_uart_9600.c with HalCoGen for an example of SCI.
    Endian is not really a factor - it will work for RM42 or TMS570 as long as you select the correct device for your HalCoGen and CCS projects.