2022-08-17 04:53 AM
Hello,
I am using a p-Nucleo-wb55.
I would need to get data from vbat channel and the internal temperature channel.
I used the example for internal temperature and it works but I am not able to add the reading of vbat value.
Am I supposed to use one rank per channel?
How do I add a rank using the .ioc file ?
Thank you
Solved! Go to Solution.
2022-08-17 06:36 AM
Am I supposed to use one rank per channel? Yes
How do I add a rank using the .ioc file ? Add it to the initialization source code
Also - use a much larger sample time for temperature. Internal voltage signal sources have a high impedance.
Cheers, Hal
2022-08-17 06:36 AM
Am I supposed to use one rank per channel? Yes
How do I add a rank using the .ioc file ? Add it to the initialization source code
Also - use a much larger sample time for temperature. Internal voltage signal sources have a high impedance.
Cheers, Hal
2022-08-17 06:40 AM
Hello,
Thank you for your answer.
Just to be sure, I add the configuration of the rank 2 (for example) that enable my channel VBAT as shown in this picture ?
2022-08-17 06:59 AM
Yes, but if the initialization is sequenced like this, you don't have to repeat intialization of structure members that don't change from the last rank.
For internal channels, see the example internal channel projects available for recommended sample times. They are typically much higher than what you are using.
Find a DMA ADC example to follow for two or more ranks.
Cheers, Hal
2022-08-22 01:47 AM
Thank you very much for your help :)
2022-08-26 11:28 AM
You need to adjust the SamplingTime for Temperature and VBAT channels. They are quite long.
-WQ