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™ TM4C123GH6PM Microcontroller - GPIO DATA register

Other Parts Discussed in Thread: TM4C123GH6PM

Hi all,


First of all I have to say that I am new in that area. I use the Tica C series Launchpad. I try to turn on the LED in that launchpad. I use the header file lm4f120h5qr.h

and then i see that in the "GPIO_PORTF_DATA_R   (*((volatile unsigned long *)0x400253FC))" there is an offset of 3FC. When i check the datasheet the register is 0x40025000 and offset is 000.

Can you explain me why we must use the offset 3FC, and where is this info inside the datasheet?

Kind Regards

  • Hello Gtse,

    First of if you are using the Tiva C series Launchpad then the header file to use is tm4c123gh6pm.h

    As for the offset information and how it is formed please go through the GPIO chapter of the data sheet, section Functional Description, sub-section Data Control

    Regards
    Amit
  • Beyond using the (correct) header file you may consider use of the API code and study of the Peripheral Driver Library Manual.

    That offset you note does require several reads - and thought - to fully comprehend. The API absorbs all of the that - buffers you from such detail - and, "Speeds, Eases & Enhances" your ability to make progress with your MCU exploration...