MSPM0G3507: Single-wire communication in safety

Part Number: MSPM0G3507

Dear TI Forum,

 

I have a question whether the MSPM0G3507 supports a GPIO pin configured as open drain output, while being able to read the digital value back that is on that pin? So having it configured as an output but with the ability to read it back.

Is it advised to switch the pin settings runtime like from output to being an input and the other way around to implement single wire communication (assuming data is put on the line using open-drain outputs)? Is it advised for safety application to use your MCU like this?

 

Thanks in advance for your support!

 

  • If you set the INENA bit in the IOMUX, you can see the current state of that (input or output) GPIO.

    Driverlib doesn't make it easy, but after configuring the pin you can do something like:

    IOMUX->SECCFG.PINCM[pincmIndex] |IOMUX_PINCM_INENA_ENABLE;