Hey Robin,
We ended up fixing the issue, and it turned out it wasn't a hardware problem at all. When configuring port c pin 7 for emios 1 channel 7, s32 does not generate the correct settings. The generated code in the pin config shows inputBuffer as PORT_INPUT_BUFFER_NOT_AVAILABLE, which means the IMCR does not get set to the correct value during Siul2_Ip_PortInit()
{
.base = IP_SIUL2,
.pinPortIdx = 71u,
.mux = PORT_MUX_AS_GPIO,
.safeMode = PORT_SAFE_MODE_NOT_AVAILABLE,
.inputFilter = PORT_INPUT_FILTER_NOT_AVAILABLE,
.driveStrength = PORT_DRIVE_STRENTGTH_NOT_AVAILABLE,
.pullConfig = PORT_INTERNAL_PULL_NOT_ENABLED,
.pullKeep = PORT_PULL_KEEP_NOT_AVAILABLE,
.invert = PORT_INVERT_NOT_AVAILABLE,
.inputBuffer = PORT_INPUT_BUFFER_NOT_AVAILABLE,
.outputBuffer = PORT_OUTPUT_BUFFER_NOT_AVAILABLE,
.adcInterleaves = { MUX_MODE_NOT_AVAILABLE, MUX_MODE_NOT_AVAILABLE },
.inputMuxReg = {
87u
},
.inputMux = {
PORT_INPUT_MUX_ALT4,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT,
PORT_INPUT_MUX_NO_INIT
},
.initValue = 2u
},
If we manually change .inputBuffer = PORT_INPUT_ENABLED, this channel ends up working as intended. Is there an issue with the code generation that prevents some pins from not being configured correctly? My colleague saw the same thing for LPSPI1. We are using RTD4.