Hello,
I was trying to get familiar with MBDT for Simulink.
The board I use is the s32k144.
The objective was to read the potentiometer value and graph it in PIL simulation.
I can actually read when it is at the minimum or the maximum value as if it were a boolean.
My Simulink diagram is as follows:
in fact, you can see how Simulink suggests that at the GPI Read block output, there is a boolean.
I can graph it via scope bl during the simulationock, but I can only see 0 or 1.
any suggestions for reading the entire set of values associated with the potentiometer?
Thanks in advance for the help.
Solved! Go to Solution.
Hello @pierpaolo_dini ,
The GPIO blocks are digital so they can only read/write logic values (0 and 1). If you want to use the potentiometer, you have to use the ADC (Analog To Digital Converter) blocks. You can check adc examples to see how to use them.
Best regards,
Bancila Sorin
Hello @pierpaolo_dini ,
The GPIO blocks are digital so they can only read/write logic values (0 and 1). If you want to use the potentiometer, you have to use the ADC (Analog To Digital Converter) blocks. You can check adc examples to see how to use them.
Best regards,
Bancila Sorin