Welcome, Guest

Author Topic: RT5350F GPIO as Outputs - Toggling at Boot  (Read 2263 times)

t35tB0t

  • Newbie
  • *
  • Posts: 10
  • Karma: +0/-0
RT5350F GPIO as Outputs - Toggling at Boot
« on: September 28, 2015, 10:21:22 AM »
I'm trying to use GPIOs as outputs but they are toggling high at boot.  I'm exporting GPIOs 11 & 13 after boot.  But they go high before it gets that far into boot.  This also happens with export the JTAG pins so I'm thinking its a Device Tree gaff.  What am I doing wrong here?

     pinctrl {
             state_default: pinctrl0 {
                  gpio {
                        ralink,group = "jtag";
                        ralink,function = "gpio";
             };
             };
             uartf_pins: uartf {
        uartf {
         ralink,group = "uartf";
         ralink,function = "gpio uartf";
            };
            };
     };


Daniel

  • Newbie
  • *
  • Posts: 10
  • Karma: +1/-0
Re: RT5350F GPIO as Outputs - Toggling at Boot
« Reply #1 on: September 28, 2015, 09:39:38 PM »
Hi!

You need a 10kohm pull down resistor (to gnd).

Best regards,

Daniel

t35tB0t

  • Newbie
  • *
  • Posts: 10
  • Karma: +0/-0
Re: RT5350F GPIO as Outputs - Toggling at Boot
« Reply #2 on: September 30, 2015, 09:58:12 AM »
Thanks Daniel - I connected the GPIO to the Relay 1 input (cut and jump on EVB).  It didn't toggle before when it was connected to the RI_as_GPIO signal.  But, now that the UARTF is operating as a UART with GPIO, I'm getting GPIOs going active/high during boot as the device tree settings are processed.  The 10K resistor pull down makes sense - but look at the Relay1 input circuit - it has a 10K pull down.  So, I am getting these GPIOs going high.  This is also true for the JTAG GPIOs.  I have tested the device tree with all gpio assignments deleted and the ports still end up high after the "pin-ctrl" stanza in the device tree is processed.  I have to export the GPIOs and actively set them up as outputs in order to make them go low.  This isn't how things should work. I'm stumped here.