Questions and discussions about the software that runs on the TD RF module itself.
uzhtbq
 
Posts: 2
Joined: Mon Jun 29, 2015 12:11 pm

ADC0 single voltage measurement

by uzhtbq Wed Nov 18, 2015 8:09 am

Hi,
I'm trying to pick up single voltage measures from ADC0 pin
I already viewed the following posts :
- http://community.td-next.com/viewtopic.php?f=3&t=60
- http://community.td-next.com/viewtopic.php?f=3&t=102

I also made a manual measurement on the ADC0 pin when the module is OFF and my input voltage arrives well into the ADC0 pin (2V for example). But when I power the module, the manual measure is giving 0V on the pin.
I tried to use the function with following parameters : TD_MEASURE_SingleVoltage(adcSingleInpCh6, adcRef2V5) but having returns between 0mv and 5mv ...
I tried also to write my own function and changing init variables but with no success ...

Can anyone please show me how to get the right measure out of the ADC0 ?

Thanks in advance for your help
User avatar
lcheminade
 
Posts: 146
Joined: Mon May 11, 2015 7:47 am

Re: ADC0 single voltage measurement

by lcheminade Wed Nov 18, 2015 8:30 am

Hi,

Could you please share your schematics with us? Where does the voltage applied to the TD12xx come from?

You could try to set the pin as input beforehand: GPIO_PinModeSet(gpioPortC,0,gpioModeInput,0);
uzhtbq
 
Posts: 2
Joined: Mon Jun 29, 2015 12:11 pm

Re: ADC0 single voltage measurement

by uzhtbq Fri Nov 20, 2015 5:28 pm

Many thanks, it worked for me ...
Return to Firmware

Who is online

Users browsing this forum: No registered users and 26 guests