Hi , In my project , i can use the battery service in my project. But if i want to use the another four ADC channels , how to add it ?
my project is working at SDK 9 & s110.
Thanks.
Hi , In my project , i can use the battery service in my project. But if i want to use the another four ADC channels , how to add it ?
my project is working at SDK 9 & s110.
Thanks.
Hi Greed
I dont think we have a direct example that shows how to do this, but there is an old example here that shows an example on how you can sample on multiple pins with the nRF51 ADC. There is also a ADC example here with softdevice for SDK 9.
Seems that you are mixing a littlebit manual configuration and driver configuration here, not sure how that would mix. I would recommend to either write directly to the ADC registers or always use the driver to configure the ADC.
When you send a message from the phone via NUS service, the NUS handler should be called, which is the nus_data_handler in the ADC-UART example. What happens in the NUS handler? Is any error returned, or why does it not work? Try to debug through it. Debugging is somewhat described here and here
Seems that you are mixing a littlebit manual configuration and driver configuration here, not sure how that would mix. I would recommend to either write directly to the ADC registers or always use the driver to configure the ADC.
When you send a message from the phone via NUS service, the NUS handler should be called, which is the nus_data_handler in the ADC-UART example. What happens in the NUS handler? Is any error returned, or why does it not work? Try to debug through it. Debugging is somewhat described here and here