how to get right AD value in 9s12zvc

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how to get right AD value in 9s12zvc

420 Views
hebangjie123
Contributor I

hello.

i hope read AD value from PL1.this input voltage range is from 5.5 V to 28 V.  i download VLG-MC9S12ZVC-DEMOSW.zip from NXP. and add my code in main.c

in

then we can read AD value from PL1.But sometimes we will read err AD value.

normal we can read right AD value ( 235).but sometimes the err  AD value is 08.  so i am confused.how to get right AD value. thank you very much.

Labels (1)
0 Kudos
1 Reply

345 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello,

It is hard to say what could be wrong, I haven't seen your code.

You can refer to this example:

High Voltage Input (HVI) SW examples for MagniV devices 

The HVI pin requires an external 10k resistor:

pastedImage_2.png

BR, Daniel

0 Kudos