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.

CC2650 ADC Semi "Parallel" Sampling?

Other Parts Discussed in Thread: CC2650

Hi,

Not using the SCE.

I have a question about achieivng a semi parallel sampling sequence on the CC2650.

My constraints are that I have to sample 2 analog lines at a 50KHz (20us) rate and

that the 2 lines should be sampled aprox together, with atmost a 0.5us interval between them 

I will need a limited amount of  samples 64 to 100 and then stop.

My problem is that the ADC can handle only one input at a time and I have to mux the lines after each sample.

I understand that a GPTimer and the ADC triggered by this timer might do the job.

I would set the timer to trigger in 0.5us?, or less?, since it requires changing the mux as well in the ISR via AUXADCSelectInput, after each interrupt. 

In order to achieve 50KHz(20us) rate in this setup(Timerr set to 0.5us) I would only capture the relevant samples in the ISR (every 40th, 41st

interrupt)?, since the ISR gets called every 0.5us and 40th, 41th ISR call would be 20us, 20.5us(50 KHz rate)

Given these constraints Is it doable at all?.

Is there a better way of doing this?.

Would appreciate advise if this can be done in another way. Maybe two timers. Or maybe setting a 20us timer and sampling twice?.

What mechanisims should I use so the ADC ISR has the highest priority, i.e. it isnt interrupted by other interrupts which can ruin the 64-100 samples at 50KHz sampling rate?.

Please note will be running the BLE stack as well, all the sampling time, will it interfere or be delayed?.

Thx

Tamir

  • Hello Tamir,
    It is not possible to get sampling of two different IO pins that close in time (less than 0.5 us). If you only need to sample a single pin this might be doable. In the next sensor controller studio release (version 1.2.0) which will be out next week I hope, there will be added an ADC Data Streamer example which might be suitable for this.
  • Hi,

    Thanks.

    The ADC Data Streamer example you mentioned in the upcoming release.

    Do you mean it will be suitable to handle more than one ADC input in the 0.5us timeframe?. Or were you refering to only one input.

    Thx,

    Tamir

  • Hi,

    No matter M3 or SCE is used, it is impossible to have two ADC samples (from two inputs) as close as 0.5us. So, I have a crazy idea: how about adding a phase shifter to one of the input signal? If the phase delay time is equal to 10us then we can use a timer with fixed period to trigger ADC.

    Just a crazy idea.
  • Thanks

    I will go talk to the Hardware Team.
    Hope they wont tell me im crazy again ;).

    Tamir