Gustfu
Posts: 3
Joined: Fri Feb 28, 2020 3:48 pm

Is it safe to build circuit after boot?

Fri Feb 28, 2020 3:53 pm

Hello, I'm a beginner. I'm wondering about the order in which pi operates. I know I shouldn't connect sd card after boot.

My question is it ok to build/modify the circuit after the boot and also is it safe to plug in mouse, keyboard, monitor, ethernet after the boot?

Please explain why I should do it this way also. Maybe there's an order I need to learn about?

Cheers,

W. H. Heydt
Posts: 13636
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 4:26 pm

Gustfu wrote:
Fri Feb 28, 2020 3:53 pm
Hello, I'm a beginner. I'm wondering about the order in which pi operates. I know I shouldn't connect sd card after boot.

My question is it ok to build/modify the circuit after the boot and also is it safe to plug in mouse, keyboard, monitor, ethernet after the boot?

Please explain why I should do it this way also. Maybe there's an order I need to learn about?
If the SD card is not inserted when the Pi is powered up, it won't boot. That SD card is the equivalent of a PC HDD.

You should not connect or disconnect anything to the GPIO header while the Pi has power. It's far too easy to make a mistake and either brush a pin or connect the wrong things together and destroy the Pis SoC. And this points up the need to double-check all GPIO connections before applying power to a Pi.

Part of the specification for USB is "hot swap". That is, you can plug or unplug USB devices to a powered up, running system. This also applies to Ethernet cables and HDMI cables. Mind you, connecting the HDMI cable(s) after boot may not get you a working display image as it is--at that point--too late for the VC6 to read the EDID data. However, if you set force HDMI and specify the correct display parameters (width, height, and frame rate at a minimum), doing so will work.

What you *should* do is connect everything else to the Pi before you connect power. That way, the Pi can boot with the intended peripherals and GPIO connections. Do this routinely and it will become a habit and your experiences with Pis will be much more pleasant than if you don't. Note that some or all of these connections do not apply if you are going to run the Pi "headless". Also, if you set your Pi up with ssh and/or VNC active, you can, with just a WiFi or Ethernet connection you can login in remotely and change anything that needs changing up to and including shutting down or rebooting a Pi.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13395
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 5:43 pm

Only the Pi1 and the zero's do NOT have "hot plugin" capability on their USB ports!
The 5V power on these PI's can actually sink below the operating voltage of the 3V3 regulator when plugging in some USB devices, due to "in rush current", later PI's have protection against in rush current, so their USB ports are "hot pluggable".

On the PI1, and zero's it is expected of you to plug in USB devices BEFORE you power up the RPI.

https://en.wikipedia.org/wiki/Inrush_current

User avatar
PeterO
Posts: 5974
Joined: Sun Jul 22, 2012 4:14 pm

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 6:15 pm

mahjongg wrote:
Fri Feb 28, 2020 5:43 pm
The Pi1 and the zero's do NOT have "hot plugin" capability on their USB ports!
The 5V power on these PI's can actually sink below the operating voltage of the 3V3 regulator when plugging in some USB devices, due to "in rush current", later PI's have protection against in rush current, so their USB ports are "hot pluggable".
I'm not sure that's the whole story.
In my experince If you try to plug in something like a hard disk the "in rush protection" can cause the device to not spin up and cause already plugged in devices to disconnect.
Because all the PI's USB ports share a single 5V supply which is not really beefy enough I wouldn't consider it to be "hot plugable" for anything other than low power devices like USB sticks/keyboards/mice.

On the PI1, and zero's it is expected of you to plug in USB devices BEFORE you power up the RPI.
https://en.wikipedia.org/wiki/Inrush_current
PeterO
Discoverer of the PI2 XENON DEATH FLASH!
Interests: C,Python,PIC,Electronics,Ham Radio (G0DZB),1960s British Computers.
"The primary requirement (as we've always seen in your examples) is that the code is readable. " Dougie Lawson

ejolson
Posts: 6039
Joined: Tue Mar 18, 2014 11:47 am

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 8:02 pm

Gustfu wrote:
Fri Feb 28, 2020 3:53 pm
My question is it ok to build/modify the circuit after the boot
If you are building a circuit connected to the GPIO it is better to build it with the power disconnected and triple check it for correctness before applying power. The reason is that one wire connected wrong will often burn out the Pi and result in the need for a replacement.

alphanumeric
Posts: 2675
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 8:12 pm

I've had Pi Zero's reboot when plugging a USB device into an adapter, Micro USB to USB. Sometimes just plugging my HUB will do it. Which is the equivalent or plugging right into the Pi's data USB port. Doesn't happen if I use a Hub and remeber to plug it in before I power up. Not for things like Keyboard dongles and thumb drives.
HDMI has been hit or miss for me. More to do with the monitor though I think. I have one that won't see the Pi if the monitor isn't turned on before the Pi is.
I never ever mess with the GPIO while the Pi is powered up. As far as plugging and unplugging devices go.

LTolledo
Posts: 4163
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Is it safe to build circuit after boot?

Fri Feb 28, 2020 9:32 pm

The safe way:
Plug everything first... check and re-check connections as second......power on and boot as third.....

Safety first!
or
Regret later.....

take your pick. :)
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

W. H. Heydt
Posts: 13636
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: Is it safe to build circuit after boot?

Sat Feb 29, 2020 3:38 am

mahjongg wrote:
Fri Feb 28, 2020 5:43 pm
The Pi1 and the zero's do NOT have "hot plugin" capability on their USB ports!
The 5V power on these PI's can actually sink below the operating voltage of the 3V3 regulator when plugging in some USB devices, due to "in rush current", later PI's have protection against in rush current, so their USB ports are "hot pluggable".

On the PI1, and zero's it is expected of you to plug in USB devices BEFORE you power up the RPI.

https://en.wikipedia.org/wiki/Inrush_current
As I recall, one of the big features of the B+ was that it could handle hot plugging USB devices. The other big change being the move from 2 USB ports to 4 of them.

User avatar
Imperf3kt
Posts: 4052
Joined: Tue Jun 20, 2017 12:16 am
Location: Australia

Re: Is it safe to build circuit after boot?

Sat Feb 29, 2020 7:23 am

Don't forget that plugging wires in after power has been applied can cause the same effect as switch bouncing, and can potentially damage sensitive electronics or give false readings (keyboards and mice suffer from this so incorporate something called debounce)
55:55:44:44:4C
52:4C:52:42:41

Rose tinted glasses are difficult to see through.

User avatar
Burngate
Posts: 6374
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: Is it safe to build circuit after boot?

Sat Feb 29, 2020 12:08 pm

My take on this: powering down before changing things is a good habit to get into, like wearing a helmet when riding a bike. You may never be hit by a double-decker bus, but if it does happen, it'll happen when you forget your helmet.

If you get into the habit of powering down, you'll still make mistakes that can kill your Pi, but hopefully that extra time spent powering down then up will give you enough thinking time to catch some of those mistakes.

pcmanbob
Posts: 10173
Joined: Fri May 31, 2013 9:28 pm
Location: Mansfield UK

Re: Is it safe to build circuit after boot?

Sat Feb 29, 2020 12:48 pm

No only is it a good idea to power your pi down when connecting/disconnecting external circuits ,

but when you are starting out its a good idea to test your circuit before connecting it to the pi using an external psu and a digital voltmeter ,
so make sure you are not going to put more that 3.3v on to a gpio pin.

This is especially important when using external circuits that might be operating at 5,12 or even high voltages.

I still do this check when using external circuits operating at more than 3.3v , its saved my pi's more than once.
We want information… information… information........................no information no help
The use of crystal balls & mind reading are not supported

boyoh
Posts: 1531
Joined: Fri Nov 23, 2012 3:30 pm
Location: Selby. North Yorkshire .UK

Re: Is it safe to build circuit after boot?

Sun Mar 01, 2020 11:31 am

The answerer to this post is use some common sense Put your Raspberry Pi back in it's box before you damage it

Learn the basics of working with electricity at all VOLTAGE LEVELS , Working on powered up circuits is not fore the NOVICE

There are men working on the Supper Grid 400k volts Live but after years of training

Regards BoyOh Retired Electrical / Electronics Technician

,
BoyOh ( Selby, North Yorkshire.UK)
Some Times Right Some Times Wrong

alphanumeric
Posts: 2675
Joined: Tue Jan 19, 2016 2:17 pm
Location: Sydney, Nova Scotia, Canada

Re: Is it safe to build circuit after boot?

Sun Mar 01, 2020 12:44 pm

I'm of an opposite opinion. Just my opinion but most people learn my doing. And asking questions before doing.
Find a tutorial on something that interests you and have at it. There are lods of things you can do with just a Raspberry Pi. And other stuff that can be done with a few extra bits.
If your new to electronics stick to low voltage DC stuff. Thats mostly what the Pi interfaces with anyway.
https://projects.raspberrypi.org/en
https://www.raspberrypi.org/education/

User avatar
PeterO
Posts: 5974
Joined: Sun Jul 22, 2012 4:14 pm

Re: Is it safe to build circuit after boot?

Sun Mar 01, 2020 1:43 pm

Welcome to the forums Gustfu.

In some respects the Arduino platform is better suited to making first steps with learning about electronics and interfacing.
In my experience they are more robust (though I've witnessed Teensy's with badly soldered USB connectors that fall off the boards) and since they don't have a complex O/S and file system they are quite happy to be turned on and off by just pulling the power (or unplugging USB).

Learning to write Arduino (C++) code is a good first step and the skills learned will be easily transferred to the Pi either in C/C++ or in Python.

And you can use your PI to host the Arduino IDE, so getting experience of using Linux applications along the way for free 8-)

But telling inquisitive beginners to put their Pi back into it's box until they have " learn[ed] the basics of working with electricity at all voltages" (my de-emphasis) is some of the most inappropriate advice I've seen and is completely against the learning by doing ethos of the Pi Foundation ! :roll:

PeterO
Last edited by PeterO on Sun Mar 01, 2020 7:12 pm, edited 1 time in total.
Discoverer of the PI2 XENON DEATH FLASH!
Interests: C,Python,PIC,Electronics,Ham Radio (G0DZB),1960s British Computers.
"The primary requirement (as we've always seen in your examples) is that the code is readable. " Dougie Lawson

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13395
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Is it safe to build circuit after boot?

Sun Mar 01, 2020 7:10 pm

PeterO wrote:
Sun Mar 01, 2020 1:43 pm

But telling inquisitive beginners to put their Pi back into it's box until they have " learn[ed] the basics if working with electricity at all voltages" (my de-emphasis) is some of the most inappropriate advice I've seen and is completely against the learning by doing ethos of the Pi Foundation ! :roll:

PeterO
agreed.... The RPI is designed for learning, and is cheap enough so that if something goes wrong it doesn't break the bank to replace it.
and yes, problems do happen, falling and standing up is part of learning.

There is one primary rule, class one, lesson 1, rule 1

The raspberry PI's GPIO's are NOT 5V tolerant, even a very short application of 5V to a GPIO can have disastrous consequences.
And no, its not an Arduino in that respect. Arduino's have older 5V technology, and are much much simpler.

User avatar
PeterO
Posts: 5974
Joined: Sun Jul 22, 2012 4:14 pm

Re: Is it safe to build circuit after boot?

Sun Mar 01, 2020 8:47 pm

mahjongg wrote:
Sun Mar 01, 2020 7:10 pm
. Arduino's have older 5V technology,
Things have moved on since you last used an Arduino ;)
https://www.arduino.cc/en/products/compare
There are other boards like the Teensy that are 3V3/5V tollerant.
PeterO
Discoverer of the PI2 XENON DEATH FLASH!
Interests: C,Python,PIC,Electronics,Ham Radio (G0DZB),1960s British Computers.
"The primary requirement (as we've always seen in your examples) is that the code is readable. " Dougie Lawson

JohnsUPS
Posts: 189
Joined: Fri Jul 06, 2018 2:13 am
Location: USA

Re: Is it safe to build circuit after boot?

Mon Mar 02, 2020 11:56 am

My philosophy has always been to power down first, [make changes] and power up last. Be sure to observe the proper power down procedures - don't just pull the connector or flip the switch. This will become a habit after a while, and your Pi (and SD card) will appreciate it.

The advice about checking your circuitry with a meter before connecting it is sound.

For the most part, any circuit that is powered with 5v should not be connected to the Pi's GPIOs without a level shifter. One exception is an open drain device where the pullup can be to a 3.3v rail, therefore the output won't exceed that voltage.

Return to “Beginners”