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.

GPIO volt after reset give 1.1 volt without any configuration for any GPIO ??

using TIVA TM123g
I tested by a code included while {1} only 

All pins give 1.1 v except F1,F2,F3 give zero , why ??

In Data Sheet VIL max = .35*VDD = 1.1 v , so I think Tiva consider GPIO have VIL (max) after reset, but how to change it??

application depends on it:
when I wrote anther code using  GPIO Interrupt (high level) in pin and configured this pin to pull down , the Interrupt occurred in first time only after reset then don't occur waiting high level for this pin , why this happened ??

  • Hello Ibrahem,

    The rating is for the pin to detected a valid 0. The output when driven 0 would be ~0V.

    Regards
    Amit
  • I have Tiva C Series TM123G LaunchPad Evaluation Kit
    If you have one , Kindly build and burn this code and see the GPIO volt , it will be 1,1v !
    ::::::::::::::::::::::::::::::::::::::::::::
    #include <stdint.h>
    #include <stdbool.h>
    #include "inc/hw_types.h"
    #include "inc/hw_memmap.h"
    #include "driverlib/sysctl.h"
    #include "driverlib/gpio.h"
    int main(void)
    {

    SysCtlClockSet(SYSCTL_SYSDIV_5|SYSCTL_USE_PLL|SYSCTL_XTAL_16MHZ|SYSCTL_OSC_MAIN);

    while(1)
    {
    }
    }
  • ibrahem mostafa said:
    burn this code and see the GPIO volt , it will be 1,1v !

    Do not most all MCU GPIO pins - from all vendors - by custom and for safety - default to Inputs?

    Code shown does not alter this GPIO pin default value (as inputs) - thus those readings have less impact than you seem to suspect.

    If you configure several GPIO pins - instead - as outputs - almost certainly you will note a near 3V3 "swing" between output "high" & output "low."

  • there is a strange thing ,
    I tested the same code again and the GPIOs volt are 0.3 volt !
  • Again - those readings may depend upon whether default, GPIO input state, includes pull-up/down (internal) resistors - and to some degree your measurement instrument & method.

    Configuring GPIO as outputs will remove your issue...

  • Hello Ibrahem,

    Input pins without a Pull Up or Pull Down can catch static and may take discharge time. Suggest enabling the Pull Up or Pull down when using the GPIOs

    Regards
    Amit
  • Due to your vacation - it appears that our "Sync'ed Clocks" have drifted apart by 1 minute. (suspect that's on your end...)
  • the problem appeared when waiting for Interrupt high level , in first time after reset only go to the ISR although interrupt pin = 0 !!, then work correctly
    
    /*************************************/
    volatile uint8_t ui8LED = 2;
    //I confirmed it at startup code
    void GPIOAIntHandler(void) { GPIOIntClear (GPIO_PORTA_BASE, GPIO_INT_PIN_6 ); GPIOPinWrite(GPIO_PORTF_BASE, GPIO_PIN_1 | GPIO_PIN_2 | GPIO_PIN_3, ui8LED); if (ui8LED == 8) { ui8LED = 2 ; } else { ui8LED = ui8LED * 2; } }
    int main(void)
    { SysCtlClockSet(SYSCTL_SYSDIV_4|SYSCTL_USE_PLL|SYSCTL_XTAL_16MHZ|SYSCTL_OSC_MAIN);
    //3led SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOF); GPIOPinTypeGPIOOutput(GPIO_PORTF_BASE, GPIO_PIN_1|GPIO_PIN_2|GPIO_PIN_3);
    //Interrupt GPIO PA6 SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOA); GPIOPadConfigSet (GPIO_PORTA_BASE,GPIO_PIN_6 , GPIO_STRENGTH_2MA , GPIO_PIN_TYPE_STD_WPD); IntMasterEnable(); GPIOIntEnable ( GPIO_PORTA_BASE , GPIO_INT_PIN_6); GPIOIntTypeSet (GPIO_PORTA_BASE , GPIO_INT_PIN_6, GPIO_HIGH_LEVEL ); IntEnable(INT_GPIOA);
    while (1) { }
    }
  • the problem is solved when make :
    GPIOIntTypeSet (GPIO_PORTA_BASE , GPIO_INT_PIN_6, GPIO_HIGH_LEVEL );
    before :
    GPIOIntEnable ( GPIO_PORTA_BASE , GPIO_INT_PIN_6);
  • May I report that your (strange) measures of pins not configured as GPIO Outputs was - not only well answered - but served, "Upon silver platter!"
    Your post wandered from, "Failed repeat interrupt" to that of measurement of default state GPIO - which was answered in detail...
  • Hello cb1

    I agree, the change of track from measured GPIO voltage to Interrupt does not bear any connection. Also while the step is correct the issue could be still a bigger problem, as HIGH LEVEL would imply that as long as the GPIO is held high, the interrupt shall always trigger, starving other peripherals.

    Regards
    Amit