This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Tiva 129 EK software contradicts SPMU363 ROM User guide for input GPIO pins

From SPMU363:

13.2.1.50 ROM_GPIOPinWrite

Description:
Writes the corresponding bit values to the output pin(s) specified by ui8Pins. Writing to a pin
configured as an input pin has no effect. (emphasis added)

-----------------------------------------------------------------------------------------------------------------

From pinout.c in the Tivaware driver code:

    //
    // PJ0 and J1 are used for user buttons
    //
    ROM_GPIOPinTypeGPIOInput(GPIO_PORTJ_BASE, GPIO_PIN_0 | GPIO_PIN_1);
    ROM_GPIOPinWrite(GPIO_PORTJ_BASE, GPIO_PIN_0 | GPIO_PIN_1, 0);
-------------------------------------------------------------------------------------------------------------------------------

Is there some undocumented reason for trying to set a register on an input pin, or is this just a cut and paste error?  Why does the library code have a line of code that should do nothing?

Thanks.

Ray

  • Correction to last post: pinout.c is in the driver directory of the EK example code.

  • Hello Raymond,

    Got it. Seems to be an error as in input mode ports cannot be written and the end value seen on the pad.

    Regards

    Amit

  • Thamks, Amil.  We have some weird happenings that are probably due to our hardware.   We get into a state where the XDS200 will not connect through JTAG.  I am going through the manuals and making sure we have not done anything out of order or anything stupid in software.  Just making sure our code matches the reference documents.Thanks again for confirming.


    The code in question doesn't hurt since it does nothing, but it added confusion to an already perplexing process.

    Thanks again.

  • Hello Raymond,

    Few of the reasons for JTAG to disconnect are

    1. The System Frequency is less than 10x of the JTAG frequency

    2. JTAG IO's are getting reprogrammed

    3. Or the crystal may be flaky causing clock changes to occur and debugger to disconnect

    4. Also do check the RESC to make sure some unwanted Reset is not occurring like BOR, WDT. etc

    Regards

    Amit