Author Topic: Oak won't connect when a pin is high at start.  (Read 2249 times)

mab299108

  • Newbie
  • *
  • Posts: 6
Oak won't connect when a pin is high at start.
« on: November 24, 2016, 08:46:02 am »
I have a couple of projects where an external sensor may be high or low at any given time. I notice that if I reboot my Oak while one of the input pins is high it won't connect to the particle cloud. In one case, I have reed switches (door sensors) on pin 3, 4, and 7. In another, I have a digital light sensor on pin 6. If I powerup when all the doors are closed, or it is daylight outside (both cases the pins are Low to ground.) everything works great. If I power up with any one door open, or at night in the second case, then the board lights up normally, but it never connects to the particle cloud. I am using the default particle connection, do I need to connect manually? Is there a way to make it ignore those pins until after the connection is made?

PeterF

  • Hero Member
  • *****
  • Posts: 881
Re: Oak won't connect when a pin is high at start.
« Reply #1 on: November 24, 2016, 05:00:45 pm »
I don't think the particle connection is the problem in this case - certain pins are 'hardwired' in the ESP8266 (Oak MCU) to have certain functions, so triggering those states on power-up is to be avoided.

Have a look at the pin notes on the wiki to see, but basically, don't pull  0, 1, 2 and 4 low at boot/poweron, and don't pull 6 high on boot/poweron. AFAIK, 0, 2, 4 and 6 are set in stone. P1 is a feature of the Oak firmware, so you could disable that, but that mean you don't have the safe mode.

If you're having problems with other pins, I'd like to know, so I can see if there is an undocumented issue with some other pin combinations.