imx7d read ADC in uboot early board init

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

imx7d read ADC in uboot early board init

ソリューションへジャンプ
790件の閲覧回数
ronhume
Contributor I

Hello,

 

I am looking for bare metal example to read ADC on imx7d.  I am hoping there is example that is simple like:

use software mode

auto calibrate

start conversion

wait for conversion

read result

}

I have found example for imx6 which is similar but ADC registers appear to be quite different on imx7d.

Is there good (small) example that could be used in uboot early board init?  That does not use interrupts for example.

Thank you.

Ron.

 

0 件の賞賛
1 解決策
778件の閲覧回数
IvanRuiz
NXP Employee
NXP Employee

Hello,

In the following FreeRTOS BSP you can find an ADC example available in: C:\nxp\FreeRTOS_BSP_1.0.1_iMX7D\examples\imx7d_sdb_m4\driver_examples\adc_imx7d after installing it.

Please download it from the following link: https://www.nxp.com/webapp/Download?colCode=FreeRTOS_iMX7D_1.0.1_WIN&appType=license

 

Hope it helps!

 

BR,

Ivan.

元の投稿で解決策を見る

0 件の賞賛
3 返答(返信)
774件の閲覧回数
ronhume
Contributor I

Ivan - thank you so much for your response.  

I have looked at that one - however it uses an interrupt handler, etc.  I was about to start using it as a base and adapting it for my use in a polling model - when I decided to ask here in the forum if anyone had a simple 10 line ADC read example that might be simpler.  I was really hoping to find a 'start conversion, wait for result, read result' type thing.

If none are out there then I will definitely use this one and try to adapt.

I basically need to read one voltage in early board init so that I can toggle a control line once one of my rails comes up.

Again - thank you for your suggestion.

Ron.

 

0 件の賞賛
760件の閲覧回数
IvanRuiz
NXP Employee
NXP Employee

Hello,

 

You are very welcome my friend. Unfortunately, this is the only example available for ADC so far which you may take as a reference for your custom implementation.

 

Have a nice weekend!

 

BR,

Ivan.

0 件の賞賛
779件の閲覧回数
IvanRuiz
NXP Employee
NXP Employee

Hello,

In the following FreeRTOS BSP you can find an ADC example available in: C:\nxp\FreeRTOS_BSP_1.0.1_iMX7D\examples\imx7d_sdb_m4\driver_examples\adc_imx7d after installing it.

Please download it from the following link: https://www.nxp.com/webapp/Download?colCode=FreeRTOS_iMX7D_1.0.1_WIN&appType=license

 

Hope it helps!

 

BR,

Ivan.

0 件の賞賛