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.

TMS320C5515: C5515 GPAIN not linear and doesn't reach 0x3FF

Part Number: TMS320C5515

I'm using the GPAIN inputs on the C5515 to measure voltage and I am finding the results odd. Using an adjustable power supply, I tried measuring various voltages primarily in the 0-1V range on the C5515ezDsp v2 USB stick and the results are very non-linear.

Here is where I altered various settings to get the measurements...

    SAR_CTRL = 0x2000;        // select channel, normal mode, continuous conversion
    SAR_CTRL = SAR_CTRL|0x0800;     // enable multi channel mode - more time to sampling input
//    SAR_CTRL = SAR_CTRL|0x0400;     // enable single conversion mode

    SAR_CLKCTRL = 0x000B;     // set clock divisor

    SAR_PINCTRL = 0x3600;     // bandgap 1v ref
//    SAR_PINCTRL = 0x3400;       // bandgap 0.8v ref
//    SAR_PINCTRL = 0x3100;     // VDD_ANA ref
//    SAR_PINCTRL=SAR_PINCTRL|0x0008;    // AVDD measure on channel 3
//    SAR_PINCTRL=SAR_PINCTRL|0x0001;    // divide input voltage by half
    SAR_PINCTRL=SAR_PINCTRL|0x0004;     // reserved bit must be set to read channel 2
//    SAR_PINCTRL=SAR_PINCTRL|0x0002;     // ground voltage divider for channel 1 or ch 0 cal measure

    SAR_GPOCTRL = 0x0000;     // turn off all GPOs

Here is the final graph..

As you can see, most settings start to saturate at about 0.8V and I can never saturate the A to D to 0x3FF or 1023 on the graph.

There are spots where the reading doesn't change and then suddenly steps to the next reading. The best performance was with VDD_ANA reference and not dividing reading by half.

Any insight into why the analogue inputs are so non-linear and regardless of reference never reach digital saturation or is that just the way it is?

Thanks,

Cam

  • Oops, the graph didn't attach. Try this way..

  • Hi,

    We do not have any collateral or resource beyond what you see in the product folder. You may search the E2E forum for archived posts of previous discussions which may help address your questions. For more info on TMS320C5515 support, please see the FAQ in 

        https://e2e.ti.com/support/processors/f/791/t/818771

    Regret the inconvenience and lack of guidance on this.

    Rex

  • Hi Rex,

    Thanks. I did do some searching and didn't find anything specifically with respect to linearity or saturation. I'll keep looking or maybe someone will chime in.

    Cheers.

  • Hi,

    Thanks. I'll keep the thread open.

    Rex

  • Rex,

    Can you find any performance documentation at TI that will shed some light on this issue? It should be documented somewhere there.

    Thanks,

    Cam

  • Hi, Cam,

    We don't have documents other than what's in the product folder. Sorry for the inconvenience.

    Rex

  • OK, thanks anyway Rex. I pictured a big engineering department at TI with lots of lab tests and performance docs in huge archives. I guess it is actually more like the rest of us :)

    Here is something from the Errata that I found. It could be relevant.

    3.15SARADC

    ❏SAR ADC has better absolute accuracy when accurate external voltage reference(1.3 V) used instead of internal refs from Bandgap (0.8 V or 1.0 V)

    ❏Set REFAVDDSEL bit in SARPINCTRL register to 1: Reference Voltage set to Analog Voltage (VDDA_ANA supply)

    ❏Design GPAIN inputs so they are in the range of VDDA_ANA voltage(0 V - 1.3 V)

    ❏GPAIN pin input impedance= 1MΩ

    ❏Voltage measurements are less accurate if impedance on pin approaches the input impedance of the device

    My graphs do show better performance with the external VDDA_ANA so maybe this confirms the bandgap references can lead to nonlinear results.

    My supply impedance was low, so that shouldn't be a problem.

    It is stated that the voltage range should be up to 1.3V with the VDDA_ANA reference but this isn't the case that I can see.

    Hopefully this info is useful to someone in the future.

    Maybe someone will show up to confirm my observations.

    Cheers.

  • Hi Cam,

    Aside external reference and low impedance drive - reducing sample rate and overall clocking jitter and EMI might help.

    Using an integtrated 10 Bit SAR at maximum speed with internal reference - I would assume to get not more than 8 useful bits.

    I would assume proper operation with 10 bits (peak performance) @20khz using external reference...

    Its always a trade-off - and if you need a certain resolution - there should be a design margin - at least with integrated SARs...

    rgds.

    Wolfgang

  • Thanks Wolfgang.

    I did find it was working a bit better when I increased the divider and reduced the clock frequency to about 1MHz or lower.

    Cheers,

    Cam