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.

TivaWare APIs in detail - TivaC lauchpad

I'm just getting started on programming my new TivaC lauchpad and I have one question

I'm aware that the APIs and some initializations are in the TivaWare Peripheral Driver Library User's Guide. 

here's a prototype:

GPIOPinWrite(uint32_t ui32Port, uint8_t ui8Pins, uint8_t ui8Val)

And then, when I see some example code I get this:

GPIOPinWrite(GPIO_PORTF_BASE, GPIO_PIN_1|GPIO_PIN_2|GPIO_PIN_3, ui8PinData);

Where do I find a list or a document including all the commands such as the ones in blue (like GPIO_PIN_1 or GPIO_PORTF_BASE)?

  • Hello Allexandre,

    The API documentation can be found in the DriverLib user Guide which is in docs folder of the installed TivaWare software.
  • In the API document there's only the TYPES of the arguments, such as uint8_t ui8Pins, not the actual argument, wich is GPIO_PIN_1 (for example). I only found the actual arguments listed in the gpio.c and the gpio.h files. Is there a document containing the all arguments I can use in for the uint8_t ui8Pins type? I know I can use GPIO_PIN_1, GPIO_PIN_2, etc. But I wonder, for the sake of having a reference guide, if there is a list with all the possibilities
  • Hello Allexandre

    From the document

    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. The pin(s) are specified using a bit-packed byte, where each bit that is set identifies the pin to be accessed, and where bit 0 of the byte represents GPIO port pin 0, bit 1 represents GPIO port pin 1, and so on.

    This is followed by an example.

    Now if the expectation is that for 8 pins all 256 combinations be specified, then the driverlib document would be over-burdened as this is not the only place where such an API is available. That is one of the reasons where the E2E forum plays an important role.