Hello,
I am currently trying to make the S32K144 board to recognize an external analog signal in addition to multiple analog signals. (multiple sensors application)
I am running a 5-0V signal from a power supply to the NXP analog pins + potentiometer reading to see if my model can recognize multiple analog signals. However, I only obtain 2 readings of the NXP potentiometer and everything else is 0.
The algorithm should work as two independent readings of the potentiometer (analog) are working fine (with 2 separate memory slots in ADC).
I have attached the model below, including a FreeMaster file.
Thank you
Solved! Go to Solution.
Hello ba2nguye@uwaterloo.ca,
My advice would be to check out the ftm_pdb_adc_chaining_s32k14x example - it comes with our toolbox, you can find it in S32_Examples/common/adc folder. There you have an example of how to synchronize ADC0 and ADC1 measurements with PWM commands issued by FTM via PDB. These 2 synchronized measurements are used to get the potentiometer value and the VDD LV value. You can read more about such techniques in Module 6: Current Sensing (Part 1/2) article (quick references - figures 9, 10 and 11).
I have also attached an adc example in which the measurements are triggered by the PDB, like this:
- PDB is software triggered
- PDB triggers subsystem in which ADC measurements are made (on pins A0 and A1).
Hope this helps!
Razvan.
Hello ba2nguye@uwaterloo.ca,
My advice would be to check out the ftm_pdb_adc_chaining_s32k14x example - it comes with our toolbox, you can find it in S32_Examples/common/adc folder. There you have an example of how to synchronize ADC0 and ADC1 measurements with PWM commands issued by FTM via PDB. These 2 synchronized measurements are used to get the potentiometer value and the VDD LV value. You can read more about such techniques in Module 6: Current Sensing (Part 1/2) article (quick references - figures 9, 10 and 11).
I have also attached an adc example in which the measurements are triggered by the PDB, like this:
- PDB is software triggered
- PDB triggers subsystem in which ADC measurements are made (on pins A0 and A1).
Hope this helps!
Razvan.
Hello Sir,
I have Performed an ADC test on pin number PTB6 and PTB7 on NXP S32K144 Evaluation Board.
After the test the PinPTB7 works fine and the voltage varies from 0 to 5 volt as required. But, when the same test was performed on pin PTB6 the values of the Pin do not vary.
Please let me know the reason if you face the same and solution to avaoid the problem
Regards
Gopal Rathi.
Hello @rathi_tg ,
On the S32K144EVB, the PTB6 and PTB7 are used as XTAL PINS, connected to an *Mhz oscillator.
The pins on the J3 connectors are not connected to the processor, you can see those resister R81 and R90.
Hope this helps,
Marius
Hello Marius
I have mistaken with the pins.
The Experiment was conducted on pins number PTC7 and PTC6 and abrupt Behavior was absorbed on PTC6.
I am sorry for the error
Regards
Gopal Rathi.
Hello @rathi_tg ,
Unfortunately with the PTC6 and PTC7 is the same situation as above. Both pins are shared on the S32K144EVB with the UART serial connected to the OpenSDA. You can not use them in the same time both for ADC and UART communication, unless if you change the serial. But on this design, the pins are connected to the OpenSDA so this might be the reason why the PTC6 is kept low.
I strongly suggest to have a look on the schematics before starting using the board pins. The schematics and be found here. https://www.nxp.com/webapp/Download?colCode=S32K144EVB-SCH-29248-RB1
Hope this helps,
Marius