Electronics notes/Electricity and humans: Difference between revisions

From Helpful
Jump to navigation Jump to search
(15 intermediate revisions by the same user not shown)
Line 5: Line 5:
==Sensing==
==Sensing==
<!--
<!--
These are high-impedance low-current/low-voltage sources,
 
Most are high-impedance low-current/low-voltage sources,
you'll probably get better results if you care about one or more of  
you'll probably get better results if you care about one or more of  
clean amplification, and higher-resolution DAC, leakage/guarding, shielding against coupling of other signals  
clean amplification, and higher-resolution DAC, leakage/guarding, shielding against coupling of other signals  
Line 38: Line 39:
sympathetic skin response (SSR), and skin conductance level (SCL).
sympathetic skin response (SSR), and skin conductance level (SCL).


All are fancy names for 'how much electricity do your skin conduct'.
{{comment|(Because of the varied names accumulated over time, EDA is intended as a new standard name, but some fields haven't moved yet, so many existing documents will use old terms.)}}
 
 
 
All are fancy names for 'how much electricity does your skin conduct'.


Some just that. Some with the implied measurement of mental state.
Some check just that.  


{{comment|(Because of the varied names accumulated over time, EDA is intended as a new standard name, but some fields haven't moved yet, and existing documents use old terms.)}}
Some suggest indirect measurement of mental state.




Line 53: Line 58:
'''Mental state?'''
'''Mental state?'''


The idea is that ''if'' you can control for physics and health with some calibration,
The idea is that  
you can measure the last few, making skin conductance one measure of emotional and sympathetic responses.
: ''if'' you can control for most of that last list - physics of the moment, and health, and further calibration,
: then sweating could indicate the last few on that list, making skin conductance one measure of emotional and sympathetic responses.


Criticism includes:  
Criticism includes:  
* that's a fairly large 'if'
* that's a lot of ifs
* hydration level affects the response regardless
* hydration level affects the response regardless
* response varies by location, being driven by somewhat different responses
* response varies by location, being driven by somewhat different responses
Line 63: Line 69:




It's impossible to avoid mentioning the polygraph-style lie detector,
 
which measures not only GSR, but also heart rate, breating rate, and blood pressure.
 
It's impossible to avoid mentioning the [[polygraph]]-style lie detector,
which measures not only GSR,  
but also heart rate,  
breathing rate,  
and blood pressure.


The idea idea is that these are all controlled by the [[sympathetic nervous system]] rather than consciously,
The idea idea is that these are all controlled by the [[sympathetic nervous system]] rather than consciously,
so you can't voluntarily change them, which is the entire reason they're sold as lie detectors.  
so you can't voluntarily change them, which is the entire reason they're sold as lie detectors.


But there are reasons that they are no longer admissible in most courts,
But there are reasons that they are no longer admissible in most courts,
for many detailed reasons - that all amount to that they are unreliable at best.
for many detailed reasons - that all amount to that they are unreliable at best.
Even its inventor has spoken out their frustration by the the ways is misused.
 
Even its ''inventor'' has spoken out their frustration by the the ways is regularly misused.




Line 81: Line 93:
** startle response -  
** startle response -  
** sexual arousal - maybe you just have a thing for authority figures
** sexual arousal - maybe you just have a thing for authority figures
: none of which have ''anything'' to do with lies, ''much less'' guilt
:: none of which have ''anything'' to do with lies, let alone guilt


* it cannot distinguish between such responses being involuntary, and such responses being triggered intentionally
* it cannot distinguish between such responses being involuntary, and such responses being triggered intentionally
Line 127: Line 139:
{{stub}}
{{stub}}


Measuring activity in the '''brain''' ([https://en.wiktionary.org/wiki/encephalo- -encephalo-]) - which (outside) is on the scale of microvolts to at most millivolts {{verify}}
Measuring activity in the '''brain''' ([https://en.wiktionary.org/wiki/encephalo- -encephalo-]) - which (outside) is on the scale of dozen microvolts (to at most millivolts {{verify}})


See http://en.wikipedia.org/wiki/EEG
At a low level, you measure a tiny fluctuating voltage change at a spot on the ''surface'' of the scalp,
comparing that voltage to other such spots for reference, using metal electrodes and conductive paste for better contact.


Muscles nearer the surface are much stronger signal - a clenched jaw or blinking your eye is ''very'' visible in data (in very different ways - jaw is high frequency, blink low).
In fact some of the electrodes are only there to measure those in isolation, so that we have a chance to remove them later


Common (but approximate) EEG wave categorization


'''delta''', &delta;
Comparing the voltage to other such voltages can (only) tell you things like
* 0.1–4 Hz
* that an area broadly became more or less active
* associations: deep sleep (3 and 4 NREM), unconscious
* ''when'' you started reacting
* http://en.wikipedia.org/wiki/Delta_wave
* differences between things like "makes sense" and "that's weird and I'm processing why".
* broadly, which areas of the brain engaged more than others


'''theta''', &theta;
* 4–7 Hz
* associations: (drowsiness, deep relaxation) / (motor behaviour? learning, memory?)
* http://en.wikipedia.org/wiki/Theta_wave


'''alpha''' &alpha;
<!--
* 8–12 Hz at the visual cortex
Any signal has to go through the layers of the meninges, the skull, and the scalp.  
* associations: (wakeful) relaxation, meditation
* http://en.wikipedia.org/wiki/Alpha_wave


'''mu''' &mu;
The random alignment of most neurons would cancel each other out,
* 8–13 Hz at the motor cortex
The only reason we can read out things electrodes at a much larger scale than neurons is that some areas have [pyramidal neurons],
* associations: voluntary movement
which happen to align well, so if there are tens of thousands of those near and aligned towards the surface,
* http://en.wikipedia.org/wiki/Mu_wave
and a lot of them were working at the same time.  


'''beta''', &beta;
{{comment|(...so no, EEG will not read minds. It is fundamentally ''way'' too clunky.)}}
* 12–30 Hz
* associations: general waking consciousness - focus and attention, being busy or anxious
* http://en.wikipedia.org/wiki/Beta_wave


'''gamma''', &gamma;
Even if we ''could'' localize to neurons better (say, if the brain were not protected),
* 25–100 Hz
this would still make it challenging to measure more than "area was active".
* associations: some relation to senses, memory?
* http://en.wikipedia.org/wiki/Gamma_wave


<!--
Merely doing that at the surface does not give up all that much,
EEG sample rate
and being able to do so non-invasively happens to be something people under study, uh, like.
1000 or 200Hz
Through those layers, what is left is microvolts, but that is still manageable - with some moderately fine hardware engineering.


is generally taken to be
but


-->


=====Electrocorticography (ECoG)=====
When you use EEG as a measurement tool, you probably design your experiment to have
[[Event-Related Potentials]] i.e. "aligned to something you reacted to", so you can treat them as timing relative to a specific event.
Probably each is a second or so worth of data, starting precisely after an event.


Electrocorticography (ECoG), or intracranial electroencephalography (iEEG),
is like EEG but sensing directly on the brain itself, rather than from outside the skull and skin.


https://en.wikipedia.org/wiki/Electrocorticography
Even then, EEG data records a mess of things happening at once, most of which are probably not even interesting to you.
The delta/theta/alpha waves are pretty broad, and not strong indicators of anything much.




=====Magnetic resonance imaging (MRI)=====
When you do studies with EEG to support a hypothesis, you often count on the fact that noise is random,
which (skipping a bunch of steps that are important to the math and statistics) means that if you have consistent evidence,
you can sum them up (in ERP form), strengthening any pattern and weakening random noise.


<!--


Most fMRI research uses Blood-oxygen-level-dependent (BOLD) contrast
People theorize e.g. about specific types of language parsing showing as different reactions at different times,
which you can isolate somewhat e.g. by making sentences that are wrong in specific ways.
Say,
: a trace for a correct sentence will on average look different than one for an incorrect sentence
: a wrongly inflected word (syntax) shows up at a different delay than a sentence that is correct but makes no semantic/pragmatic senses.




Specific literature names specific types of responses (see things like P600, N400)
''but'' these can be overstated.






See http://en.wikipedia.org/wiki/EEG
-->
-->


=====Magnetoencephalography (MEG)=====
<!--
<!--
Fancier EEG tends to sample 2000 times or so per second,
though moer than 500 isn't necessary for almost anything people measure.


Both an 'of what' and 'how': sensing the brain's magnetic fields, non-invasively (it's like a helmet, classicaly a huge device held above you), and silently.


Difference from EEG
Common (but approximate) EEG wave categorization
* MEG senses neuron's electric fields, EEG senses electrical potentials still present at the skin


Difference to MRI
'''delta''', &delta;
* MEG is passive, MRI is active (adds a magnet){{verify}}
* 0.1–4 Hz
* MEG tends to do more general images the brain itself, MRI images activity in it.
* associations: deep sleep (3 and 4 NREM), unconscious
* MEG has a higher temporal resolution than (f)MRI, but poorer detail{{verify}}
* http://en.wikipedia.org/wiki/Delta_wave
* Note: MSI (magnetic source imaging) combines MEG and MRI results


-->
'''theta''', &theta;
* 4–7 Hz
* associations: (drowsiness, deep relaxation) / (motor behaviour? learning, memory?)
* http://en.wikipedia.org/wiki/Theta_wave


=====Functional Near-Infrared Spectroscopy (fNIRS)=====
'''alpha''' &alpha;
* 8–12 Hz at the visual cortex
* associations: (wakeful) relaxation, meditation
* http://en.wikipedia.org/wiki/Alpha_wave


Functional near-infrared spectroscopy (sometimes Optical Topography (OT))
'''mu''' &mu;
uses near-infrared spectroscopy to estimates the concentration of hemoglobin to estimate activity, so is useful for basic functional neuroimaging.
* 8–13 Hz at the motor cortex
* associations: voluntary movement
* http://en.wikipedia.org/wiki/Mu_wave


It is noninvasive and has high temporal resolution,  
'''beta''', &beta;
but low spatial resolution and only works near the surface.
* 12–30 Hz
* associations: general waking consciousness - focus and attention, being busy or anxious
* http://en.wikipedia.org/wiki/Beta_wave


(it's not electronic and doesn't really belong on this page, but it mostly does belong in this list of measuring humans)
'''gamma''', &gamma;
* 25–100 Hz
* associations: some relation to senses, memory?
* http://en.wikipedia.org/wiki/Gamma_wave
-->


=====Electrocorticography (ECoG)=====


<!--
Electrocorticography (ECoG), or intracranial electroencephalography (iEEG),
=====Transcranial direct current stimulation (tDCS)=====
is like EEG but sensing directly on the brain itself, rather than from outside the skull and skin.


https://en.wikipedia.org/wiki/Transcranial_direct-current_stimulation
Is surgically invasive, so generally only seen around things like epilepsy treatment.
-->


====Electrooculography (EOG)====


Electrooculography (EOG), a.k.a. retinal Electrooculography, basically helps record eye movements.
https://en.wikipedia.org/wiki/Electrocorticography


https://en.wikipedia.org/wiki/Electrooculography
=====Magnetic resonance imaging (MRI)=====


<!--


====Electroglottography (EGG)====
Most fMRI research uses Blood-oxygen-level-dependent (BOLD) contrast
{{stub}}


Measures the how closed the vocal folds are, via the resistance of two electrodes around the neck.




=====Electronics side=====
<!--
Like any technique that wants to measure millivolts or less - ECG, EEG, EMG, and more, we have multiple things working against it.


Amplifying that signal is relatively easy, but ''isolating'' it is harder.


-->




For one, there are a lot of tiny interactions around
=====Magnetoencephalography (MEG)=====
: you to the ground physically,
<!--
: EM (mainly mains) you to capacitively
: EM (mainly mains) to the wiring capacitively
: EM (mainly mains) to the recorder


Both an 'of what' and 'how': sensing the brain's magnetic fields, non-invasively (it's like a helmet, classicaly a huge device held above you), and silently.


Difference from EEG
* MEG senses neuron's electric fields, EEG senses electrical potentials still present at the skin


The body is a decent antenna for things like 50Hz / 60Hz hum, and other EM.
Difference to MRI
* MEG is passive, MRI is active (adds a magnet){{verify}}
* MEG tends to do more general images the brain itself, MRI images activity in it.
* MEG has a higher temporal resolution than (f)MRI, but poorer detail{{verify}}
* Note: MSI (magnetic source imaging) combines MEG and MRI results


Roughly speaking, 'driven right leg' is a way to reference a circuit to the body's potential by making you part of a feedback loop.
-->
This is a good way to significantly reduce the effect of environmental EM.


=====Functional Near-Infrared Spectroscopy (fNIRS)=====


Functional near-infrared spectroscopy (sometimes Optical Topography (OT))
uses near-infrared spectroscopy to estimates the concentration of hemoglobin to estimate activity, so is useful for basic functional neuroimaging.


https://en.wikipedia.org/wiki/Driven_right_leg_circuit
It is noninvasive and has high temporal resolution,
but low spatial resolution and only works near the surface.


https://www.ti.com/lit/an/sbaa188/sbaa188.pdf
(it's not electronic and doesn't really belong on this page, but it mostly does belong in this list of measuring humans)


-->


<!--
=====Transcranial direct current stimulation (tDCS)=====


====Electropalatography (EPG)====
https://en.wikipedia.org/wiki/Transcranial_direct-current_stimulation
-->


https://en.wikipedia.org/wiki/Electropalatography
====Electrooculography (EOG)====


====Electromagnetic articulography (EMA)====
Electrooculography (EOG), a.k.a. retinal Electrooculography, basically helps record eye movements.


a.k.a. Electromagnetic Midsagittal Articulography (EMMA)
https://en.wikipedia.org/wiki/Electrooculography




Positioning the tongue, using sensor coils in EM field, receiving signals from multiple fixed transmitters (chunky thing above head).
====Electroglottography (EGG)====
{{stub}}
 
Measures the how closed the vocal folds are, via the resistance of two electrodes around the neck.




=====Electronics side=====
<!--
<!--
Like any technique that wants to measure millivolts or less - ECG, EEG, EMG, and more, we have multiple things working against it.


https://en.wikipedia.org/wiki/Electromagnetic_articulography
Amplifying that signal is relatively easy, but ''isolating'' it is harder.


https://www.articulograph.de/articulograph-head-menue/about-artciulography/


-->


==Stimulating==
For one, there are a lot of tiny interactions around
: you to the ground physically,
: EM (mainly mains) you to capacitively
: EM (mainly mains) to the wiring capacitively
: EM (mainly mains) to the recorder


====Conductive====


=====TENS, Transcutaneous Electrical Nerve Stimulation=====


Aims to desensitive nerves, so is used for short-term pain relief.
The body is a decent antenna for things like 50Hz / 60Hz hum, and other EM.


Higher frequency (and less strength?) than EMS, only enough to feel.  
Roughly speaking, 'driven right leg' is a way to reference a circuit to the body's potential by making you part of a feedback loop.
This is a good way to significantly reduce the effect of environmental EM.


Electric massage is closer to TENS than EMS{{verify}}


See also:
* http://en.wikipedia.org/wiki/Transcutaneous_electrical_nerve_stimulation
* http://www.bbc.co.uk/health/physical_health/conditions/tens1.shtml


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


=====EMS, Electrical Muscle Stimulation=====
https://www.ti.com/lit/an/sbaa188/sbaa188.pdf


Also known as NMES (neuromuscular electrical stimulation) and electro''myo''stimulation.
-->


Used to help muscle training, such as that to avoid atrophy.


It uses pulses that are strong and long enough to trigger muscle contraction,
====Electropalatography (EPG)====
and helps engage more of an muscle that you consciously engage.
It's not that effective without your help, though.


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


====Electromagnetic articulography (EMA)====


See also:
a.k.a. Electromagnetic Midsagittal Articulography (EMMA)
* http://en.wikipedia.org/wiki/Electrical_muscle_stimulation




=====Massage=====
Positioning the tongue, using sensor coils in EM field, receiving signals from multiple fixed transmitters (chunky thing above head).
<!--
Partially marketing, both EMS and TENS can be argued to have massage-like results.




-->
<!--


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


====High frequency====
https://www.articulograph.de/articulograph-head-menue/about-artciulography/
=====Purple wand=====
<!--


-->
-->


==Static electricity, ESD, and humans==
====Events====
{{stub}}
{{stub}}


<!--
<!--
Terms like '''evoked potentials''' or '''Event Related Potentials''' suggest people are doing scientific experiments.


Static electricity builds up and discharges all the time, in people, and a bunch of objects where movement happens.


But often not very much, not very quickly, and there often is some reason it gets discharged (e.g. moisture in the air already helps),  
'''Event Related Potentials'''
so you rarely notice it.  
: often means "aligned to a point in time, e.g. the time a stimulus was presented, so you can treat them as timing relative to a specific event".
: this is not about the frequencies, and ''ideally'' about identical timing between many independent such signals




ESD (electrostatic discharge) usually describes cases where static electricity discharges more quickly - which happens much more easily when the charge can be larger.


'''Evoked Potentials''' are electrical responses that follow stimulation, from sources like auditory, somatosensory, visual, motor/muscle, or other nerves, or other modalities.
Most experiments will record exactly when those stimuli happened.


Even just people walking around can generate a few dozen to a few hundred volts.


If you're really trying - add a carpet and some aggressive shuffling - and we can hold up up to maybe ~30kV or so.
We usually use a more specific term describing what we are doing, and then often a specific way of measuring them as well.
...except when generalizing over them.


If over perhaps 3kV is very suddenly grounded quite well, you may feel that zap.


If it's over perhaps 20+kV, it may hurt a little.  
Unsorted:
Visual evoked response (VER) test.
Brainstem auditory evoked response (BAER) test.
Somatosensory evoked response (SSER) test.  


While that voltage is high, will often be surprising and sometimes slightly painful,
there is an upper limit to the total static ''charge'' behind it.


A a human can be seen as an at-most-200pF capacitor, meaning the charge and thereby our our current capacity is tiny.
You'll store a few dozen milliJoules at most.


This is why charge built up by you is never dangerous to you.
-->


==Stimulating==


====Conductive====


There's enough energy in this discharge to be able to ignite liquids {{comment|(particularly those already above their [[fire point]], and see also [[dust explosions]])}}, which is why static electricity is a thing industrial environments specifically worry about. {{comment|(Say, a big metal tank may be a few nanoFarads, and store a few Joules, which is why there are regulations that say that when they contain something flammable, ''you ground them''.  This is also related to airplane refueling involving a ground wire.)}}
=====TENS, Transcutaneous Electrical Nerve Stimulation=====


Aims to desensitive nerves, so is used for short-term pain relief.


Higher frequency (and less strength?) than EMS, only enough to feel.


Static electricity in weather would usually be called a lightning storm,
Electric massage is closer to TENS than EMS{{verify}}
and carries much more serious current capacity.


See also:
* http://en.wikipedia.org/wiki/Transcutaneous_electrical_nerve_stimulation
* http://www.bbc.co.uk/health/physical_health/conditions/tens1.shtml




=====EMS, Electrical Muscle Stimulation=====


https://www.staticelectricity.com.au/truth-vs-fact
Also known as NMES (neuromuscular electrical stimulation) and electro''myo''stimulation.


https://www.sciencedirect.com/topics/engineering/static-electricity
Used to help muscle training, such as that to avoid atrophy.
-->


===ESD and electronics===
It uses pulses that are strong and long enough to trigger muscle contraction,
<!--
and helps engage more of an muscle that you consciously engage.
It's not that effective without your help, though.




A small amount of static electricity is generated and stored by people - and its the discharge would be called ESD.


It often won't build up, but if you get zapped a lot, then you probably have well-isolating shoes.
See also:
* http://en.wikipedia.org/wiki/Electrical_muscle_stimulation




A reasonable sting that you feel will mean on the order of ~2000V,
=====Massage=====
while 200V may already damage a few electronic components (not many, particularly when they have been designed with some ESD protection as e.g. IO pins generally have, but you generally don't know exactly what's on a board, so it pays to be careful).
<!--
Partially marketing, both EMS and TENS can be argued to have massage-like results.




-->




A potentially larger amount of ESD is generated by some machines,
====High frequency====
though the ones that will have grounded plugs, and in industrial settings tend to have clear "please ground me" labeling.
=====Purple wand=====
<!--


-->


==Static electricity, ESD, and humans==
{{stub}}


In electronics, the term ESD comes up when it has the potential to damage electronics during discharge.
<!--


This is often separated into:
Static electricity builds up and discharges all the time, in people, and a bunch of objects where movement happens.
* a Human-body model (HBM)
: exists because people handling electronics is expected - and a case that has limited charge that you could more easily protect against
: modeled by a 100 pF capacitor and a 1500 ohm discharging resistance
:: and charged to a few different voltages, in the bunch-of-kilovolt range
: https://en.wikipedia.org/wiki/Human-body_model


* a Charged-device model (CDM), per ANSI/ESDA/JEDEC JS-002
But often not very much, not very quickly, and there often is some reason it gets discharged (e.g. moisture in the air already helps),  
: because most devices have predictable voltages
so you rarely notice it.  
: https://en.wikipedia.org/wiki/Charged-device_model


And also a
* Machine Model (MM).


ESD (electrostatic discharge) usually describes cases where static electricity discharges more quickly - which happens much more easily when the charge can be larger.




ESD from things not touching anything is generally not modeled,
Even just people walking around can generate a few dozen to a few hundred volts.
as air isolates on the order of tens of kilovolts per centimeter.


If you're really trying - add a carpet and some aggressive shuffling - and we can hold up up to maybe ~30kV or so.


If over perhaps 3kV is very suddenly grounded quite well, you may feel that zap.


There is further distinction between
If it's over perhaps 20+kV, it may hurt a little.  
* Corona discharge[https://en.wikipedia.org/wiki/Corona_discharge]
: into the air
: for sharp objects (<1mm, generally)


* brush discharge[https://en.wikipedia.org/wiki/Brush_discharge]
While that voltage is high, will often be surprising and sometimes slightly painful,
: into the air
there is an upper limit to the total static ''charge'' behind it.
: named for the many-streamer look
: practically 5..50mm; above that it'll practically almost have to be...


* arc discarge
A a human can be seen as an at-most-200pF capacitor, meaning the charge and thereby our our current capacity is tiny.
: between two electrodes
You'll store a few dozen milliJoules at most.


This is why charge built up by you is never dangerous to you.


* propagating brush discharge


* Cone discharge (a.l.a. bulking brush discharges)


The above is somewhat specific to man-made objects.  
There's enough energy in this discharge to be able to ignite liquids {{comment|(particularly those already above their [[fire point]], and see also [[dust explosions]])}}, which is why static electricity is a thing industrial environments specifically worry about. {{comment|(Say, a big metal tank may be a few nanoFarads, and store a few Joules, which is why there are regulations that say that when they contain something flammable, ''you ground them''.  This is also related to airplane refueling involving a ground wire.)}}
Lightning is a bit of a case of its own, though could be explained in the same terms.
 
 
 
Static electricity in weather would usually be called a lightning storm,
and carries much more serious current capacity.
 




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


https://www.staticelectricity.com.au/truth-vs-fact
https://www.staticelectricity.com.au/truth-vs-fact


https://www.sciencedirect.com/topics/engineering/static-electricity
-->
-->
===Avoiding ESD===
 
===ESD and electronics===
<!--
<!--


Around electronics you can think about
* not allowing ESD buildup to go very high
: by ensuring it's discharged


* protecting entire devices's insides
A small amount of static electricity is generated and stored by people - and its the discharge would be called ESD.
: e.g. shielding
 
It often won't build up, but if you get zapped a lot, then you probably have well-isolating shoes.


* specifically care to protect inputs (and outputs) that will have to be exposed - see also [[Electronics_notes_/_Inputs_and_outputs#Transient_voltage_and_ESD_protection.2C_snubbers]]


A reasonable sting that you feel will mean on the order of ~2000V,
while 200V may already damage a few electronic components (not many, particularly when they have been designed with some ESD protection as e.g. IO pins generally have, but you generally don't know exactly what's on a board, so it pays to be careful).




Say, foams and bags can be:
* '''Anti-static''' - will not cause electrostatic buildup itself
:: which doesn't necessarily say nothing about whether it will block or dissipate charge


* '''static dissipative''' - will try to lose electrostatic charge to its environment (air or ground)
:: dissipative to the air is often done via [[surfectants]]{{verify}}
:: dissipative to device, or to ground, can be done just by being conductive
::: sometimes specifically with moderate resistance, to limit discharge current
: "esd wrist straps" are just one big resistor to the device you're working on (or to ground)
:: ...generally around 1MOhm, so that even if you touch 240V AC this path would be less than 0.5mA.


A potentially larger amount of ESD is generated by some machines,
though the ones that will have grounded plugs, and in industrial settings tend to have clear "please ground me" labeling.


* '''static shielding''' - will protect against electrostatic discharge that happens nearby it
:: e.g. by being an easier path for the discharge (so lower resistance than dissipative)
:: needs to encompass the entire thing
::: in shipping often with bags, though can be done sandwiched between two layers of conductive foam.




Some things will do all of the above, some only some.
In electronics, the term ESD comes up when it has the potential to damage electronics during discharge.
It's all in the requirements and specs.


And, more practically, often in the combination of material, and shape.
This is often separated into:
* a Human-body model (HBM)
: exists because people handling electronics is expected - and a case that has limited charge that you could more easily protect against
: modeled by a 100 pF capacitor and a 1500 ohm discharging resistance
:: and charged to a few different voltages, in the bunch-of-kilovolt range
: https://en.wikipedia.org/wiki/Human-body_model


* a Charged-device model (CDM), per ANSI/ESDA/JEDEC JS-002
: because most devices have predictable voltages
: https://en.wikipedia.org/wiki/Charged-device_model


[[ESD foam]] usually refers to foam that is
And also a
: antistatic, in the sense of won't ''generate'' static charges
* Machine Model (MM).
: static-disspative (conductive with moderate resistance)




Conductive foam, which dissipates any charge if grounded (and, yes, allows static charges to pass through them


Static dissipative foam is conductive foam with a moderate resistance, meaning discharge isn't very fast or high current
ESD from things not touching anything is generally not modeled,  
as air isolates on the order of tens of kilovolts per centimeter.




However, they will allow static charges to pass through them. When using this foam in shipping to fully protect static-sensitive devices, make sure the item is placed in a silver conducive bag that will shield it from outside electrostatic charges.


There is further distinction between
* Corona discharge[https://en.wikipedia.org/wiki/Corona_discharge]
: into the air
: for sharp objects (<1mm, generally)


* brush discharge[https://en.wikipedia.org/wiki/Brush_discharge]
: into the air
: named for the many-streamer look
: practically 5..50mm; above that it'll practically almost have to be...


* arc discarge
: between two electrodes


Telling them apart:
* bags that do any of the above may have an ESD symbol{{verify}} - that doesn't really help


* some of these have a signature look, but it's not a 1:1 indicator
* propagating brush discharge
: They can be clear, pink, gray, silvery or whatnot.


* pink bags/foam is often air-dissipative.
* Cone discharge (a.l.a. bulking brush discharges)


* silvery bags are often ESD (but is not a guarantee)
The above is somewhat specific to man-made objects.
Lightning is a bit of a case of its own, though could be explained in the same terms.




* black is usually due to carbon content, so points to being conductive, and ''possibly'' shielding.
https://en.wikipedia.org/wiki/Electrostatic_discharge


https://www.staticelectricity.com.au/truth-vs-fact


* {{imagesearch|IC tubes}} are often somewhat static dissipative.  Just because it's a good idea.
-->


-->


===Avoiding ESD===
{{stub}}
<!--
<!--
: often black (conductive)
Around electronics you can think about
: sometimes pink (dissipative)
* not allowing ESD buildup to go very high voltage
: by ensuring it's discharged


* protecting entire devices's insides from discharge that ''will'' happen
: e.g. shielding


Both types are basically just conductive,
* specifically care to protect inputs (and outputs) because by their nature they ''have'' to be exposed - see also [[Electronics_notes_/_Inputs_and_outputs#Transient_voltage_and_ESD_protection.2C_snubbers]]
in that e.g. black IC foam is conductive to be dissipative,
and e.g. ESD bags are conductive to be like a faraday cage.






Say, foams and bags can be:
* '''Anti-static''' - will not cause electrostatic buildup itself
:: which does '''not''' necessarily say nothing about whether it will dissipate charge from other things, or whether it will block discharge


The two are distinct not only in design but also in possible guarantees.
* '''static dissipative''' - will try to lose electrostatic charge to its environment (air or ground)
:: dissipative to the air is often done via [[surfectants]]{{verify}}
:: dissipative to device, or to ground, can be done just by being conductive
::: sometimes specifically with moderate resistance, to limit discharge current
:::: "esd wrist straps" that should ensure ''you'' are not charged are just one big resistor to the device you're working on (or to ground - the difference matters!)
:::: ...generally around 1MOhm, so that even if you touch 240V AC this path would be less than 0.5mA.




* '''static shielding''' - will protect against electrostatic discharge that happens nearby it
:: e.g. by being an easier path for the discharge (so lower resistance than dissipative)
:: needs to encompass the entire thing
::: in shipping often with bags, though can be done sandwiched between two layers of conductive foam.




The gray bags can be either.
Some things will do all of the above, some only some.  
They'll be ESD
It's all in the requirements and specs.


And, more practically, often in the combination of material, and shape.
The gray foam to stick ICs is static dissipative (by merit of being conductive)


TODO: eevblog link


'''[[ESD foam]]''' usually refers to foam that is
: antistatic, in the sense of won't ''generate'' static charges
: static-disspative (conductive with moderate resistance)


'''Conductive foam''' dissipates any charge ''if grounded'' (and, yes, allows static (dis)charges to pass through them


https://en.wikipedia.org/wiki/Antistatic_bag
'''Static dissipative foam''' is conductive foam with a moderate resistance, meaning discharge isn't very fast or high current


https://electronics.stackexchange.com/questions/103797/anti-static-vs-conductive-vs-dissipative-foam


-->
However, they will allow static charges to pass through them. When using this foam in shipping to fully protect static-sensitive devices, make sure the item is placed in a silver conducive bag that will shield it from outside electrostatic charges.


===Lightning===
<!--


Lightning is it is the sudden discharge of electrostatic energy built up between clouds and earth.


Which is ESD on a larger scale than you'd normally consider ESD.


Telling them apart:
* bags that do any of the above may have an ESD symbol{{verify}}
: but doesn't quite tell you what, so it doesn't really help


Depending on where it strikes, you may have one of several problems.
* some of these have a signature look, but it's not a 1:1 indicator
: They can be clear, pink, gray, silvery or whatnot.


* pink bags/foam is often air-dissipative.


For one, if it strikes electric power lines, the conductors involved make it easy to put this higher voltage into a lot of devices.
* silvery bags are often ESD (but is not a guarantee)


Such a strike is unlikely within cities, where powerlines are (depending on your country) low or underground, so there are better targets, but it's still a reason why there are


* '''surge arresters''' e.g. at distribution stations - inline with the power transmission, and basically a [[varistor]] of specific design
* black is usually due to carbon content, so points to being conductive, and ''possibly'' shielding.
: https://en.wikipedia.org/wiki/Surge_arrester


* '''lightning arrester''' sits between line and earth, which only conduct overly high voltages, and do not affect normal voltage levels. They in many ways are similar to spark gaps.
: https://en.wikipedia.org/wiki/Spark_gap#Protective_devices
: https://circuitglobe.com/types-of-lightning-arresters.html


* a '''lightning rod''' (or the more modern lightning protection system, which is basically just more of them) is something you'd put on a building
* {{imagesearch|IC tubes}} are often somewhat static dissipative.  Just because it's a good idea.


-->


<!--
: often black (conductive)
: sometimes pink (dissipative)


Before addressing some lightning myths, let's get a feel of how lightning connects - not why as much as how.


Look for videos not just slow motion but ''very'' slow motion of lightning, it'll help. Also looks cool.
Both types are basically just conductive,  
in that e.g. black IC foam is conductive to be dissipative,
and e.g. ESD bags are conductive to be like a faraday cage.


You can imagine a feeler that makes its way down, around which you can see continuously small discharges forking off in many directions.
You can consider it being in a place, around which there is a few few-dozen-meter sphere, in which it is prepared to immediately jump to a conductor (a conductor better than the air it's traveling in).  If there's no such thing, it will keep doing the same while going pretty-randomly downwards.


There's a pretty neat diagram at [https://what-if.xkcd.com/16/ xkcd what-if] that also illustrates how much tallness does and doesn't matter.


And depends a little on the conductivity.
It might have similar reason to connect with a tall lightning rod half a dozen meters away, or a wooden post one meter away.


But that distance is distance away from the point that it would have struck ''anyway'', and you can't really influence the path it takes downwards from objects on the ground more than a little - because that imaginary sphere has a fairly small radius.
The two are distinct not only in design but also in possible guarantees.


So nothing really attracts lightning over more than twenty-or-so meters.
It'll be preferential within that, but not beyond.






Lightning myths
The gray bags can be either.
* lightning rods attract lightning
They'll be ESD
* lightning only strikes good conductors
* wearing metal increases likelines
* lightning only strikes the tallest thing


* lightning rods avoid lightning happening nearby
: the thought is that it would continuously discharges small static buildup before it can be large, so a larger strike will only happen elsewhere.
The gray foam to stick ICs is static dissipative (by merit of being conductive)
: This is a pretty good thought in itself, as you can e.g. sometimes see corona discharge on lightning rods
: the largest reason it turns out not to be true is probably the sheer size charge involved, the effective height it's at, and the area it's spread over. The discharge would be much too local and the discharge current much too small compared to storms.


* lightning never strikes the same place twice.
TODO: eevblog link
: there's reasons that make it less likely - given the size of a storm, it's just likely to spread it around, it's not likely to immediately have enough charge at the same spot to strike again, and the storm may move.
: but if it's a preferential thing, like a tall building with lightning rods, it absolutely will.


* surge protectors protect my devices well
: only if it was largely dissipated already. A closeby strike is way out of spec of most surge protectors
: also, keep in mind that they may have protected you once and are broken because of it, and you have no indication




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


https://electronics.stackexchange.com/questions/103797/anti-static-vs-conductive-vs-dissipative-foam


More interesting ones:
-->


* Lying flat on the ground
===Lightning===
: is a ''slightly'' worse idea than not, in that if there's a close strike, potential differences along the ground (ground current) would make it through to better if you're lying down.
<!--


Lightning is it is the sudden discharge of electrostatic energy built up between clouds and earth.


* sitting in a car does protect you, not because the tires isolate, but because if it has a metal frame, that frame is the preferential path.
Which is ESD on a larger scale than you'd normally consider ESD.
: does a car hold charge for a little bit (that may connect via people-resistors once you get out?){{verify}}




* you're safer inside a house
Depending on where it strikes, you may have one of several problems.
: largely true, though with the footnotes that when the strike is basically on the house (and no ligtning rod), there may be side flashes around any good conductors, so if you're worried, stay away from radiators, pipes, and electronics.


* "don't stand under a tree" / "do actually"
: Trees are slightly preferential to strike within a handful of meters - which might be argued is a good thing in that that's not you, but there are a few reasons it works out differently:
: side flashes also apply directly around the tree
: branches and bark can explode off (because of water)
: ground current of the discharge


* "Open field is better / worse"
For one, if it strikes electric power lines, the conductors involved make it easy to put this higher voltage into a lot of devices.
: you are preferred within a meter or two, so most of the time it makes no difference, except when it does
: the same goes for your back yard


* "It's bad to be in a lake / pool"
Such a strike is unlikely within cities, where powerlines are (depending on your country) low or underground, so there are better targets, but it's still a reason why there are
: if you're swimming, your head is too tiny a target to matter
: water is conductive enough, which might've made you safer because of drain in all directions, except electricity likes to flow over surfaces, so if it strikes relatively nearby, the dissipation in all directions is going to pass some of it through you. There's an inverse-square thing going on there
: Pools will be too small for that inverse-square thing to help much
: net effect is that yes, it's somewhat worse to be in water


* '''surge arresters''' e.g. at distribution stations - inline with the power transmission, and basically a [[varistor]] of specific design
: https://en.wikipedia.org/wiki/Surge_arrester


* "ships are unsafe"
* '''lightning arrester''' sits between line and earth, which only conduct overly high voltages, and do not affect normal voltage levels. They in many ways are similar to spark gaps.
: depends a lot. A boat is often a little preferential over the water around it
: https://en.wikipedia.org/wiki/Spark_gap#Protective_devices
: a metal ship with a cabin is pretty safe for the same reasons cars are
: https://circuitglobe.com/types-of-lightning-arresters.html
: a wooden ship without a cabin will have issues
: ships will often have lightning protection systems on the masts, because that's cheaper than replacing a significant part of the ship


* a '''lightning rod''' (or the more modern lightning protection system, which is basically just more of them) is something you'd put on a building






Before addressing some lightning myths, let's get a feel of how lightning connects - not why as much as how.


Look for videos not just slow motion but ''very'' slow motion of lightning, it'll help.  Also looks cool.


So in the (relatively unlikely) case your house ''is'' the preferred path,
You can imagine a feeler that makes its way down, around which you can see continuously small discharges forking off in many directions.
a lightning rod keeps the discharge away from your powerlines, and from things that might set a fire.  
You can consider it being in a place, around which there is a few few-dozen-meter sphere, in which it is prepared to immediately jump to a conductor (a conductor better than the air it's traveling in). If there's no such thing, it will keep doing the same while going pretty-randomly downwards.  
A ''lightning protection system'' is a good idea when you have important pricy things.


There's a pretty neat diagram at [https://what-if.xkcd.com/16/ xkcd what-if] that also illustrates how much tallness does and doesn't matter.


And depends a little on the conductivity.
It might have similar reason to connect with a tall lightning rod half a dozen meters away, or a wooden post one meter away.


Note that the fact that each house has an earthing rod helps protect houses from all but really closeby strikes.{{verify}}
But that distance is distance away from the point that it would have struck ''anyway'', and you can't really influence the path it takes downwards from objects on the ground more than a little - because that imaginary sphere has a fairly small radius.


So nothing really attracts lightning over more than twenty-or-so meters.
It'll be preferential within that, but not beyond.


https://www.weather.gov/safety/lightning-struck


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


https://en.wikipedia.org/wiki/Lightning_arrester
Lightning myths
* lightning rods attract lightning
* lightning only strikes good conductors
* wearing metal increases likelines
* lightning only strikes the tallest thing


http://www.lightningsafety.noaa.gov/
* lightning rods avoid lightning happening nearby
: the thought is that it would continuously discharges small static buildup before it can be large, so a larger strike will only happen elsewhere.
: This is a pretty good thought in itself, as you can e.g. sometimes see corona discharge on lightning rods
: the largest reason it turns out not to be true is probably the sheer size charge involved, the effective height it's at, and the area it's spread over. The discharge would be much too local and the discharge current much too small compared to storms.


https://www.pbs.org/wgbh/nova/article/dwyer-lightning/
* lightning never strikes the same place twice.
-->
: there's reasons that make it less likely - given the size of a storm, it's just likely to spread it around, it's not likely to immediately have enough charge at the same spot to strike again, and the storm may move.
: but if it's a preferential thing, like a tall building with lightning rods, it absolutely will.


* surge protectors protect my devices well
: only if it was largely dissipated already. A closeby strike is way out of spec of most surge protectors
: also, keep in mind that they may have protected you once and are broken because of it, and you have no indication


===Unsorted===


<!--
'''Triboelectric effect''' is the main thing that causes static electricity buildup.


This electrical charging is often assumed to be about movement or friction - it isn't.


More interesting ones:


It's about having and breaking contact from a different material - often repeatedly for it to have everyday-scale effects.
* Lying flat on the ground
: is a ''slightly'' worse idea than not, in that if there's a close strike, potential differences along the ground (ground current) would make it through to better if you're lying down.


Rubbing does however make the effect stronger, mostly because it forces more surface area to be involved.


* sitting in a car does protect you, not because the tires isolate, but because if it has a metal frame, that frame is the preferential path.
: does a car hold charge for a little bit (that may connect via people-resistors once you get out?){{verify}}


Materials, roughness, temperature, strain, and other properties
will determine
the strength of the charge, and which side becomes positive or negative


* you're safer inside a house
: largely true, though with the footnotes that when the strike is basically on the house (and no ligtning rod), there may be side flashes around any good conductors, so if you're worried, stay away from radiators, pipes, and electronics.


* "don't stand under a tree" / "do actually"
: Trees are slightly preferential to strike within a handful of meters - which might be argued is a good thing in that that's not you, but there are a few reasons it works out differently:
: side flashes also apply directly around the tree
: branches and bark can explode off (because of water)
: ground current of the discharge


* "Open field is better / worse"
: you are preferred within a meter or two, so most of the time it makes no difference, except when it does
: the same goes for your back yard


* "It's bad to be in a lake / pool"
: if you're swimming, your head is too tiny a target to matter
: water is conductive enough, which might've made you safer because of drain in all directions, except electricity likes to flow over surfaces, so if it strikes relatively nearby, the dissipation in all directions is going to pass some of it through you. There's an inverse-square thing going on there
: Pools will be too small for that inverse-square thing to help much
: net effect is that yes, it's somewhat worse to be in water


'''Static electricity''' refers to carrying charge ''regardless'' of reason -- but yeah,
most everyday static electricity is triboelectric.


* "ships are unsafe"
: depends a lot. A boat is often a little preferential over the water around it
: a metal ship with a cabin is pretty safe for the same reasons cars are
: a wooden ship without a cabin will have issues
: ships will often have lightning protection systems on the masts, because that's cheaper than replacing a significant part of the ship




Charge tends to build up less in wet climates and areas,
because it is easier for small discharges to happen.




Antistatic shoes are specifically conductive so that it eases discharge.
Note this is the ''opposite'' of isolating.




So in the (relatively unlikely) case your house ''is'' the preferred path,
a lightning rod keeps the discharge away from your powerlines, and from things that might set a fire.
A ''lightning protection system'' is a good idea when you have important pricy things.




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


Note that the fact that each house has an earthing rod helps protect houses from all but really closeby strikes.{{verify}}




https://www.weather.gov/safety/lightning-struck


Triboelectric
https://en.wikipedia.org/wiki/Lightning_rod


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


https://www.scientificamerican.com/article/static-science-how-well-do-different-materials-make-static-electricity/
http://www.lightningsafety.noaa.gov/


https://www.pbs.org/wgbh/nova/article/dwyer-lightning/
-->




https://www.quora.com/Why-do-our-bed-sheets-spark-My-girlfriend-and-I-noticed-bright-sparks-when-we-just-move-our-hands-across-the-fabric-weve-never-seen-static-electricity-like-this
===Unsorted===


https://www.quora.com/What-are-the-best-materials-to-create-static-electricity
<!--
'''Triboelectric effect''' is the main thing that causes static electricity buildup.


This electrical charging is often assumed to be about movement or friction - it isn't.


https://jh399.k12.sd.us/dailyassign/physics/ch7materialstaticelec.pdf


It's about having and breaking contact from a different material - often repeatedly for it to have everyday-scale effects.


https://www.quora.com/Do-helicopter-blades-create-static-electricity
Rubbing does however make the effect stronger, mostly because it forces more surface area to be involved.




-->
Materials, roughness, temperature, strain, and other properties
will determine
the strength of the charge, and which side becomes positive or negative


==On (not) causing tingling==


===Laptop tingle / zap===
{{stub}}






'''Static electricity''' refers to carrying charge ''regardless'' of reason -- but yeah,
most everyday static electricity is triboelectric.


Symptoms:
* continuous tingling on exposed metal (sockets, screws, metal bodies, e.g. in your hands, on your lap)


* felt only when the adapter is connected


* Felt more clearly when
Charge tends to build up less in wet climates and areas,
:: the contact area is small <!--{{comment|(similar current focused through fewer of your neurons)}}-->
because it is easier for small discharges to happen.
:: you have good contact with the device (e.g. sweaty hands/legs)
:: you have good contact with the floor (e.g. no shoes or socks, moist concrete)


: When measured, this is AC, and up to a few dozen volts, and usually not more than a milliAmp or two


<!--
Antistatic shoes are specifically conductive so that it eases discharge.
tl;dr:
Note this is the ''opposite'' of isolating.
* not dangerous or harmful to you or the laptop
: even though (from one of the causes) the voltage might in a few cases even be up to half of line voltage, the [[current capacity]] behind the most likely cause is necessarily tiny


* most likely a non-grounded adapter
: laptops with non-grounded adapters may tingle  (but avoid ground loops)
: laptops with grounded adapters will not tingle (but ''may'' introduce ground loops)
:: which is is often most relevant when you connect sound to an amp (with a 3.5mm plug; consider using HDMI audio)


* workarounds:
** pull the thing to ground somehow (...exactly once)
** buy a grounded adapter (if it exists)




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


First, '''we need some background''' to be sure we're on the same page on some concepts:




'''AC ground for the brick'''


Mains-plug grounding is often for compliance reasons
Triboelectric
: to make that black block itself comply with [[Class I]] which roughly says "if it has metal that might become exposed at all, that must be safety-earthed").
: also, in some places, electrical code says "''everything'' delivering more than some amount of Watts of power ''must'' be grounded"
: also ground may be helpful to shield the brick's EM ''emission'', for EMI compliance
: also, companies that design for many countries may comply with many at once, meaning they're sometimes redundant beyond necessity




Adapters can also choose comply with [[Class II]], which roughly says "insulated with enough layers that you can never really touch anything".
https://www.scientificamerican.com/article/static-science-how-well-do-different-materials-make-static-electricity/
Which is not very hard to meet. In some devices it's more convenient than Class I, in others less.




Whether adapters are Class I or Class II  is not ''directly'' relevant,
as that applies mainly to the black block's dealing with wall voltage, rather than its output. However...


https://www.quora.com/Why-do-our-bed-sheets-spark-My-girlfriend-and-I-noticed-bright-sparks-when-we-just-move-our-hands-across-the-fabric-weve-never-seen-static-electricity-like-this


https://www.quora.com/What-are-the-best-materials-to-create-static-electricity


'''Connecting AC-side ground to DC-side negative output'''


As isolated components not yet in a nice consumer-compatible box, transformers and switch-mode units typically do ''not'' tie the AC-side ground to their output-side.  
https://jh399.k12.sd.us/dailyassign/physics/ch7materialstaticelec.pdf


Largely because engineers want this as an ''option''.


(There are specific categories of ''products'' where it is required, but in general it's not,
https://www.quora.com/Do-helicopter-blades-create-static-electricity
and there are upsides to not doing so, e.g. avoidance of ground loops)




Wallwart adapters often don't do tie ground to their output.
-->
Since most don't use grounded plugs, they can't, but that's not the point - they ''could'' all have been designed that way.


As it is, wallarts are implicitly floating/isolated outputs.
==On (not) causing tingling==
''If'' they meet relevant safety specs while doing so, there's not much benefit to adding safety ground (...but this is a more complex discussion).


===Laptop tingle / zap===
{{stub}}


Laptop adapters regularly ''do'' connect AC-side ground to DC-side negative.
If it's there on the main-side in the first place, of course.
: a 2-pin on the mains side means there's no earth to be connected.
: a 3-pin on the mains side, it is relatively likely (but not guaranteed) that AC ground is tied to DC output ground.






'''Sooo... Is grounding of the laptop (via the DC ground) a good idea or not?'''
Symptoms:
* continuous tingling on exposed metal (sockets, screws, metal bodies, e.g. in your hands, on your lap)


Any serious product will be meeting other certification that ensures safety, regardless of whether you do or don't.
* felt only when the adapter is connected


* Felt more clearly when
:: the contact area is small <!--{{comment|(similar current focused through fewer of your neurons)}}-->
:: you have good contact with the device (e.g. sweaty hands/legs)
:: you have good contact with the floor (e.g. no shoes or socks, moist concrete)


Beyond that, the best choice depends on which problem you are most interested in solving.
: When measured, this is AC, and up to a few dozen volts, and usually not more than a milliAmp or two


''Not grounding the laptop'' (2-wallplug-pin adapters, and a few 3-pin that don't)
<!--
: ''in theory'' this gives completely floating output
tl;dr:
: In practice, capacitances in and around the power supply means it's still pulled to at most roughly half-line-voltage away (often with some line-frequency waveform on top).
* not dangerous or harmful to you or the laptop
:: Often specifically due to decoupling capacitors in the design (which you need).
: even though (from one of the causes) the voltage might in a few cases even be up to half of line voltage, the [[current capacity]] behind the most likely cause is necessarily tiny
:: The amount will varying with capacitor size,
::: if compliant to e.g. UL will necessarily be at a current capacity that cannot be harmful
::: but will often be enough to feel.
: upside: avoids ground loop when you connect with common-mode interconnects
: downside: can have this tingle issue


''Grounding the laptop'' (most 3-wallplug-pin) avoids the tingle effect, by being able to siphon off this small AC current
* most likely a non-grounded adapter
: However, it is much easier to create a conductive [[ground loop]] when you add cabling
: laptops with non-grounded adapters may tingle  (but avoid ground loops)
:: specifically, when you connect to another grounded device, with a cable that connects ground to another ground-referenced device
: laptops with grounded adapters will not tingle (but ''may'' introduce ground loops)
::: e.g. analog audio
:: which is is often most relevant when you connect sound to an amp (with a 3.5mm plug; consider using HDMI audio)
::: a lot of data cabling avoids this
::: data-and-power, like USB, often does not
: upside: avoids the tingle
: downside: makes it easier to get (ground loop) interference issues on baseband interconnects - like consumer audio cables between laptop and amplifier
:: In more pathological cases (powered, similarly-grounded devices, including some DIY) it could even mean damage


* workarounds:
** pull the thing to ground somehow (...exactly once)
** buy a grounded adapter (if it exists)






First, '''we need some background''' to be sure we're on the same page on some concepts:


In laptops, it is additionally ''possible'' that the further voltage conversion within the laptop may be inadequately filtered (often due to size constraints) and also help introduce some tingle{{verify}}, but this would only be relevant when grounded via something else.{{verify}}


'''AC ground for the brick'''


Mains-plug grounding is often for compliance reasons
: to make that black block itself comply with [[Class I]] which roughly says "if it has metal that might become exposed at all, that must be safety-earthed").
: also, in some places, electrical code says "''everything'' delivering more than some amount of Watts of power ''must'' be grounded"
: also ground may be helpful to shield the brick's EM ''emission'', for EMI compliance
: also, companies that design for many countries may comply with many at once, meaning they're sometimes redundant beyond necessity


There are sometimes specific workarounds, e.g. if you have exactly one common mode audio connector you could isolate it (to avoid a conductive ground loop).


Adapters can also choose comply with [[Class II]], which roughly says "insulated with enough layers that you can never really touch anything".
Which is not very hard to meet. In some devices it's more convenient than Class I, in others less.




Side note:
Whether adapters are Class I or Class II  is not ''directly'' relevant,
* some laptop connectors have a third pin on the laptop-side connector
as that applies mainly to the black block's dealing with wall voltage, rather than its output. However...
:: this is will rarely (assume never) be a separate ground
:: That's typically communication, e.g. identifying the power capacity of the adapter, and sometimes DRM-style verification to make knockoff adapters harder to make






'''Connecting AC-side ground to DC-side negative output'''


http://www.unitechelectronics.com/sparks.htm
As isolated components not yet in a nice consumer-compatible box, transformers and switch-mode units typically do ''not'' tie the AC-side ground to their output-side.  


https://www.google.com/search?q=tingle+unearthed+devices
Largely because engineers want this as an ''option''.


http://www.thailandguru.com/grounding-earthing-electrical.html
(There are specific categories of ''products'' where it is required, but in general it's not,
and there are upsides to not doing so, e.g. avoidance of ground loops)


https://www.aptsources.com/wp-content/uploads/pdfs/Floating-Output.pdf


-->
Wallwart adapters often don't do tie ground to their output.
Since most don't use grounded plugs, they can't, but that's not the point - they ''could'' all have been designed that way.


===Phone zap / tingle===
As it is, wallarts are implicitly floating/isolated outputs.
''If'' they meet relevant safety specs while doing so, there's not much benefit to adding safety ground (...but this is a more complex discussion).


Mostly similar to the laptop example above.


Many of these chargers are ungrounded wallwart-style, making this a likely thing.
Laptop adapters regularly ''do'' connect AC-side ground to DC-side negative.


If it's there on the main-side in the first place, of course.
: a 2-pin on the mains side means there's no earth to be connected.
: a 3-pin on the mains side, it is relatively likely (but not guaranteed) that AC ground is tied to DC output ground.


One difference to the laptop case is that there are a lot more cheap-and-particularly-''crappy'' phone chargers out there (than there are low-grade laptop adapters).


Some of them just low quality output, a few actually unsafe.


See e.g. [http://www.righto.com/2012/10/a-dozen-usb-chargers-in-lab-apple-is.html] [http://www.righto.com/2012/03/inside-cheap-phone-charger-and-why-you.html]
'''Sooo... Is grounding of the laptop (via the DC ground) a good idea or not?'''


Any serious product will be meeting other certification that ensures safety, regardless of whether you do or don't.


It the touchscreen doesn't work as well, or at all (interferes with the way capacitive touch works) whenever it's on a charge cable, it's probably just a low-quality charger and you can fix that by buying a better one. It can be hard to tell quality from looks.
Reputable brands are a decent though not sure-fire way, and there ''are'' some decent cheaper-brand ones.


Beyond that, the best choice depends on which problem you are most interested in solving.


<!--
''Not grounding the laptop'' (2-wallplug-pin adapters, and a few 3-pin that don't)
There are other things that particularly cheap phone chargers skimp on or violate, such as
: ''in theory'' this gives completely floating output
* the clearance between high-voltage and low-voltage parts(safety)
: In practice, capacitances in and around the power supply means it's still pulled to at most roughly half-line-voltage away (often with some line-frequency waveform on top).
* amount of isolation of transformer windings (safety)
:: Often specifically due to decoupling capacitors in the design (which you need).
* lack of fuse (safety)
:: The amount will varying with capacitor size,
* lack of full rectification bridge (quality)
::: if compliant to e.g. UL will necessarily be at a current capacity that cannot be harmful
::: but will often be enough to feel.
: upside: avoids ground loop when you connect with common-mode interconnects
: downside: can have this tingle issue


This may result in smoke and possibly a damaged phone.
''Grounding the laptop'' (most 3-wallplug-pin) avoids the tingle effect, by being able to siphon off this small AC current
If it doesn't quickly burn itself, or trip a fuse or an RCD fast enough,
: However, it is much easier to create a conductive [[ground loop]] when you add cabling
then it may couple ~200V to the phone case, and thereby potentially you.
:: specifically, when you connect to another grounded device, with a cable that connects ground to another ground-referenced device
::: e.g. analog audio
::: a lot of data cabling avoids this
::: data-and-power, like USB, often does not
: upside: avoids the tingle
: downside: makes it easier to get (ground loop) interference issues on baseband interconnects - like consumer audio cables between laptop and amplifier
:: In more pathological cases (powered, similarly-grounded devices, including some DIY) it could even mean damage




http://geekswithblogs.net/jemimus/archive/2005/10/28/58374.aspx


https://www.cnet.com/forums/discussions/my-computer-is-shocking-me-235884/


http://electronics.stackexchange.com/questions/157814/how-much-is-a-transformers-secondary-floating


https://www.ifixit.com/Answers/View/139534/Is+an+Ungrounded+Power+Adapter+Dangerous
In laptops, it is additionally ''possible'' that the further voltage conversion within the laptop may be inadequately filtered (often due to size constraints) and also help introduce some tingle{{verify}}, but this would only be relevant when grounded via something else.{{verify}}




http://arstechnica.com/civis/viewtopic.php?f=9&t=1134334


There are sometimes specific workarounds, e.g. if you have exactly one common mode audio connector you could isolate it (to avoid a conductive ground loop).


http://electronics.stackexchange.com/questions/78079/why-is-this-laptop-adapter-grounded




http://electronics.stackexchange.com/questions/78079/why-is-this-laptop-adapter-grounded
Side note:  
* some laptop connectors have a third pin on the laptop-side connector
:: this is will rarely (assume never) be a separate ground
:: That's typically communication, e.g. identifying the power capacity of the adapter, and sometimes DRM-style verification to make knockoff adapters harder to make


http://electronics.stackexchange.com/questions/116895/how-can-a-faulty-usb-charger-kill-you


http://www.theiet.org/forums/forum/messageview.cfm?catid=205&threadid=42876




http://www.thenakedscientists.com/forum/index.php?topic=8564.0
http://www.unitechelectronics.com/sparks.htm


https://www.google.com/search?q=tingle+unearthed+devices


http://www.aptsources.com/resources/pdf/Floating%20Output.pdf
http://www.thailandguru.com/grounding-earthing-electrical.html
 
https://www.aptsources.com/wp-content/uploads/pdfs/Floating-Output.pdf


-->
-->


==Less intentional / on not killing people==
===Phone zap / tingle===


====Electricity through humans====
Mostly similar to the laptop example above.


<!--
Many of these chargers are ungrounded wallwart-style, making this a likely thing.
====='one hand behind your back' rule'=====


Electricians, and people studying electronics, will probably know the 'one hand behind your back' rule.


One difference to the laptop case is that there are a lot more cheap-and-particularly-''crappy'' phone chargers out there (than there are low-grade laptop adapters).


The point is that if you touch two parts of a circuit, you connect through your chest.  
Some of them just low quality output, a few actually unsafe.


Mains voltage may not kill you, a few multiples higher likely will.
See e.g. [http://www.righto.com/2012/10/a-dozen-usb-chargers-in-lab-apple-is.html] [http://www.righto.com/2012/03/inside-cheap-phone-charger-and-why-you.html]




With just one hand, chances are your shoes are isolated well enough for you to 
It the touchscreen doesn't work as well, or at all (interferes with the way capacitive touch works) whenever it's on a charge cable, it's probably just a low-quality charger and you can fix that by buying a better one. It can be hard to tell quality from looks.
 
Reputable brands are a decent though not sure-fire way, and there ''are'' some decent cheaper-brand ones.
 
If this is something you work with regularly, such a habit is a great idea.
-->




=====Human resistance ratings=====
<!--
<!--
There are other things that particularly cheap phone chargers skimp on or violate, such as
* the clearance between high-voltage and low-voltage parts(safety)
* amount of isolation of transformer windings (safety)
* lack of fuse (safety)
* lack of full rectification bridge (quality)


Skin is moderately resistive
This may result in smoke and possibly a damaged phone.
: ...to DC and low-frequency AC, which is what we typically care about when asking this question
If it doesn't quickly burn itself, or trip a fuse or an RCD fast enough,
then it may couple ~200V to the phone case, and thereby potentially you.


Larger contact area lowers the effective


Electrolytes also lower the effective resistance.
http://geekswithblogs.net/jemimus/archive/2005/10/28/58374.aspx


https://www.cnet.com/forums/discussions/my-computer-is-shocking-me-235884/


'''Dry skin, and variation from surface area'''
http://electronics.stackexchange.com/questions/157814/how-much-is-a-transformers-secondary-floating


Touching a wire with a finger, or e.g. squeezing your fingers on two multimeter leads, you will typically measure something between 100kOhm and 1MOhm {{comment|(won't be very stable because it conducts so poorly so small movements vary a lot)}}.
https://www.ifixit.com/Answers/View/139534/Is+an+Ungrounded+Power+Adapter+Dangerous


Grasping a bare solid wire like those in your walls (same idea, a little more surface area) may get you down to 30kOhm.


Your hand on fully metal pliars may be 10kOhm
http://arstechnica.com/civis/viewtopic.php?f=9&t=1134334


The extra area from grasping a thick solid conductive pipe may get down to 5kOhm.


http://electronics.stackexchange.com/questions/78079/why-is-this-laptop-adapter-grounded


'''Sweaty skin'''


A sweaty salty human doing each of the above may reduce those figures by up to a fa factor 5 to 10.
http://electronics.stackexchange.com/questions/78079/why-is-this-laptop-adapter-grounded


http://electronics.stackexchange.com/questions/116895/how-can-a-faulty-usb-charger-kill-you


http://www.theiet.org/forums/forum/messageview.cfm?catid=205&threadid=42876


'''Saliva'''


Probably on the order of 5-10kOhm.  
http://www.thenakedscientists.com/forum/index.php?topic=8564.0
Which is why licking a 9V battery will get you order of a milliamp or two, and be very perceptible.




http://www.aptsources.com/resources/pdf/Floating%20Output.pdf


'''Immersion in a conductive liquid'''
-->


Might even get well under 1kOhm, again largely because of surface area.
==Less intentional / on not killing people==
: (this runs into 'where to put the other lead' details, though)


Not because of the water itself, which is a poor conductor,
====Electricity through humans====
but because  ''water with an [[electrolyte]]'', like salt, is actually a pretty decent conductor,
plus liquids get to ''all'' the surface area.


For similar reasons, an open wound (bypassing the skin) to a nearby open wound may actually present on the order of 1kOhm.
<!--
====='one hand behind your back' rule'=====


Electricians, and people studying electronics, will probably know the 'one hand behind your back' rule.




'''Footnotes'''
The point is that if you touch two parts of a circuit, you connect through your chest.


* the voltage-current relation of human skin is non-linear, meaning I=V/R is only an approximation for current across the skin
Mains voltage may not kill you, a few multiples higher likely will.
: so the above are approximate


* high voltage (think sustained kilo-volts) potentially breaks down skin, which changes things
: but you rarely see that around the house


* high frequency changes things
With just one hand, chances are your shoes are isolated well enough for you to 
: but you rarely see that around the house




If this is something you work with regularly, such a habit is a great idea.
-->
-->


=====Current through humans - where does the risk start?=====
 
=====Human resistance ratings=====
<!--
<!--


: '''Some numbers'''
Skin is moderately resistive
: ...to DC and low-frequency AC, which is what we typically care about when asking this question


As mentioned, DC are different, and high frequency AC different yet.
Larger contact area lowers the effective
In practice, figures for DC, mains AC (50 or 60Hz), and 'high frequency' (call it order of 10kHz) are proably decent indication


Electrolytes also lower the effective resistance.


For DC
: 1-5 mA is the threshold of ability to feel it
: 50mA hurts
: 50mA is where muscle control is overridden
: 70mA is where you may have difficulty breathing
: above that is more pain and issues.
: Heart fibrillation is starts being risky around 200mA-500mA if applied well and/or sustained


'''Dry skin, and variation from surface area'''
Touching a wire with a finger, or e.g. squeezing your fingers on two multimeter leads, you will typically measure something between 100kOhm and 1MOhm {{comment|(won't be very stable because it conducts so poorly so small movements vary a lot)}}.


For mains AC
Grasping a bare solid wire like those in your walls (same idea, a little more surface area) may get you down to 30kOhm.
: 1 mA is the threshold of ability to feel it
: 10mA hurts
: 10-20mA is where muscle control is overridden
: 20-25mA is where you may have difficulty breathing
: above that is more pain and issues.
: Heart fibrillation is starts being risky around 20mA-100mA if applied well and/orsustained


Your hand on fully metal pliars may be 10kOhm


High frequency AC resembles the DC list, except that the threshold of sensation is higher.
The extra area from grasping a thick solid conductive pipe may get down to 5kOhm.
: the numbers are higher in part because it won't penetrate as deeply {{verify}}


References {{comment|(they vary, this is just the most succinct one I saw)}}:
* https://electronics.stackexchange.com/questions/19103/how-much-voltage-current-is-dangerous


'''Sweaty skin'''


A sweaty salty human doing each of the above may reduce those figures by up to a fa factor 5 to 10.


Assuming moderately good contact (dry human graping a wire, or sweaty human with a good finger's touch) for ~25kOhm,
then a little V=IR, reveals that you'll feel 48VAC, and 100VAC to 200VAC starts to be dangeous.


AC, because around the house, higher voltages are typically AC wallpower.
(one exception is the output of solar panels, but they usually have well protected plus, because of this).


Also, DC is a little less dangerous at the same voltage,
'''Saliva'''
so if you're going to remember just a voltage,
let's remember the more dangerous of the two.


As such: given our skin's fairly high resistance, there is little risk under 50V, AC or DC.
Probably on the order of 5-10kOhm.
Which is why licking a 9V battery will get you order of a milliamp or two, and be very perceptible.


'''But never forget this varies with a lot of things.'''




'''Immersion in a conductive liquid'''


Might even get well under 1kOhm, again largely because of surface area.
: (this runs into 'where to put the other lead' details, though)


'''Not grabbing electricity'''
Not because of the water itself, which is a poor conductor,
but because  ''water with an [[electrolyte]]'', like salt, is actually a pretty decent conductor,
plus liquids get to ''all'' the surface area.


One of the very dumb and practical reasons it varies is touching a voltage, and grabbing that same voltage, is a very different hing.
For similar reasons, an open wound (bypassing the skin) to a nearby open wound may actually present on the order of 1kOhm.


If you've ever touched mains power, you know it very much stings, enough for you to instinctively recoil, fast enough to avoid burns and unlikely to influence your heart.




However, a certain amount of current overrides your muscles,
'''Footnotes'''
and if you wrapped your hands around a conductor, you now cannot let go.


That current may have been safe enough to touch, but if it means it is now sustained,
* the voltage-current relation of human skin is non-linear, meaning I=V/R is only an approximation for current across the skin
which introduces problems that a quick touch did not have.
: so the above are approximate
The above figures for your heart are "if sustained for a few seconds" figures.


* high voltage (think sustained kilo-volts) potentially breaks down skin, which changes things
: but you rarely see that around the house


Which is why 110V and 230V mains are ''both'' in the area of "you'll usually be fine, but if sustained, all bets are off".
* high frequency changes things
: but you rarely see that around the house




This is why [[RCD]]s a.k.a. [[GFCI]]s are great - they will turn off your power if thy see 5mA or 20mA, for more than 25 milliseconds or so.
-->
Those figures are clearly chosen with people in mind.


=====Current through humans - where does the risk start?=====
<!--


: '''Some numbers'''


So ''if'' you're taking the stupid shortcut of touching something to double-check it's really off,
As mentioned, DC are different, and high frequency AC different yet.
do it with the outside of your hand.
In practice, figures for DC, mains AC (50 or 60Hz), and 'high frequency' (call it order of 10kHz) are proably decent indication


People working on things like distribution boards will often have an additional set of habits.
Healthy respect is a very good idea.


-->
For DC
: 1-5 mA is the threshold of ability to feel it
: 50mA hurts
: 50mA is where muscle control is overridden
: 70mA is where you may have difficulty breathing
: above that is more pain and issues.
: Heart fibrillation is starts being risky around 200mA-500mA if applied well and/or sustained


=====More context=====
<!--
'''Nerves''' are sensitive to electricity. This helps lowers risks somewhat, in that there is a range in which you feel things but they are not dangerous yet.
When the amount of current is fairly small and constant,
more contact area will be felt less because you're mostly spreading a fairly constant amount of current.


Have you ever felt a tingle from a laptop?
For mains AC
The reason behind that is basically weak coupling that is almots necessarily low current capacity.
: 1 mA is the threshold of ability to feel it
So a laptop with metal screws may sting where it touches your legs,
: 10mA hurts
but a metal unibody may not, even though if you touch it with a fingertip you'll feel the same sting.
: 10-20mA is where muscle control is overridden
: 20-25mA is where you may have difficulty breathing
: above that is more pain and issues.
: Heart fibrillation is starts being risky around 20mA-100mA if applied well and/orsustained




If you ''do'' have current capacity behind it, more contact area will increase current.
High frequency AC resembles the DC list, except that the threshold of sensation is higher.
More surface area, and pressing down harder, lowers resistance relative to more gentle touches.
: the numbers are higher in part because it won't penetrate as deeply {{verify}}


References {{comment|(they vary, this is just the most succinct one I saw)}}:
* https://electronics.stackexchange.com/questions/19103/how-much-voltage-current-is-dangerous




'''Muscles''' are controllable by electricity.


[[Electrical muscle stimulation]] (EMS) uses this fact in a controlled way,
Assuming moderately good contact (dry human graping a wire, or sweaty human with a good finger's touch) for ~25kOhm,
and is safe (see the heart) because the pads are on the skin,  
then a little V=IR, reveals that you'll feel 48VAC, and 100VAC to 200VAC starts to be dangeous.
typically localized to the muscles being targeted.
It also helps that it's somewhat higher frequency.


AC, because around the house, higher voltages are typically AC wallpower.
(one exception is the output of solar panels, but they usually have well protected plus, because of this).


'''Burns''' can come from high enough current / voltage.
Also, DC is a little less dangerous at the same voltage,
so if you're going to remember just a voltage,
let's remember the more dangerous of the two.


As such: given our skin's fairly high resistance, there is little risk under 50V, AC or DC.


'''The Heart''' is a muscle, and under regular control.
'''But never forget this varies with a lot of things.'''






'''More on the heart'''


The heart is not so easily thwarted - to interrupt the heart you need to sustain a voltage, because you have to knock it out of its regular rhythm, and instead of slowly pump will sort of quickly twitch - called [https://en.wikipedia.org/wiki/Atrial_fibrillation fibrilation] {{comment|(which is why a [https://en.wikipedia.org/wiki/Defibrillation ''de''fibrilator], the thing that makes your heart go normal again, is called that)}}.
'''Not grabbing electricity'''


One of the very dumb and practical reasons it varies is touching a voltage, and grabbing that same voltage, is a very different hing.


If sustained, it takes only a few mA through the heart for fibrilation to potentially happen happen ''but only if delivered directly'' to the heart. Internal defibrilator paddles used in heart surgery (they look a bit like spoons) are less dramatic.
If you've ever touched mains power, you know it very much stings, enough for you to instinctively recoil, fast enough to avoid burns and unlikely to influence your heart.


Doing the same from the surface not only needs to get through your fairly skin (which has high resistance), it also needs to deal with the fact the current then spreads around. This is why you'd need 30+ mA total before more than a few would be going through the heart rather than other parts of you, and more if you're not doing it near the heart.


This is also why regular defibrilators use larger paddles, or more recently, stick-on conductors, and deliver on the order of 1000V {{comment|(which is why they need a little time to charge, though movies exaggerate this)}}.  
However, a certain amount of current overrides your muscles,  
and if you wrapped your hands around a conductor, you now cannot let go.


That current may have been safe enough to touch, but if it means it is now sustained,
which introduces problems that a quick touch did not have.
The above figures for your heart are "if sustained for a few seconds" figures.


Fibrilation is not something you particularly feel happening,
and because your oxygen doesn't deplete within seconds,
you will function while fibrilating for maybe a minute feeling nothing beyond a bit woozy,
which an already-small time window in which to fix it smaller.
There are now fully automated defibrilator kits, which only shock you when they detect you are actually fibrilating, as to not make things worse when you misjudged, also to stop once you're fine.


They also tend to have spoken instructions, so that anyone can do this.
Which is why 110V and 230V mains are ''both'' in the area of "you'll usually be fine, but if sustained, all bets are off".
And it's recommended you try if you can, because survival is most likely in the first three or so minutes,
and no ambulance is that fast.




This is why [[RCD]]s a.k.a. [[GFCI]]s are great - they will turn off your power if thy see 5mA or 20mA, for more than 25 milliseconds or so.
Those figures are clearly chosen with people in mind.


http://en.wikipedia.org/wiki/Electric_shock




So ''if'' you're taking the stupid shortcut of touching something to double-check it's really off,
do it with the outside of your hand.


People working on things like distribution boards will often have an additional set of habits.
Healthy respect is a very good idea.


-->
-->


====="It isn't the volts that kill you, it's the amps"=====
=====More context=====
<!--
<!--
'''Nerves''' are sensitive to electricity. This helps lowers risks somewhat, in that there is a range in which you feel things but they are not dangerous yet.
When the amount of current is fairly small and constant,
more contact area will be felt less because you're mostly spreading a fairly constant amount of current.


This is both true and potentially misleading.
Have you ever felt a tingle from a laptop?
The reason behind that is basically weak coupling that is almots necessarily low current capacity.
So a laptop with metal screws may sting where it touches your legs,
but a metal unibody may not, even though if you touch it with a fingertip you'll feel the same sting.


It also doesn't really explain anything.


If you ''do'' have current capacity behind it, more contact area will increase current.
More surface area, and pressing down harder, lowers resistance relative to more gentle touches.




For some idea of how much current your body doesn't like:
* 5mA is a level you can feel, but which is not yet dangerous
* 30mA going through your body is where you need to start worrying.
: it's not enough to burn, but you don't want it to be longer than a quick jolt.


'''Muscles''' are controllable by electricity.


So is a car battery rated to move 50A into your starter monitor many many times deadly?
[[Electrical muscle stimulation]] (EMS) uses this fact in a controlled way,
...no.  You can touch it all day and it won't do anything.
and is safe (see the heart) because the pads are on the skin,
typically localized to the muscles being targeted.
It also helps that it's somewhat higher frequency.




It's not the ''ability'' to move current, it's ''actually'' moving current
'''Burns''' can come from high enough current / voltage.


Assuming that a human is relatively constant resistance,
I=V/R means the current is proportional to the voltage.


On that order? If we assume a dry human barely touching a wire then let's say 50kOhm.
'''The Heart''' is a muscle, and under regular control.
Plug this, and some everyday voltages into I=V/R, and you get:
: 5V means  0.1mA
: 12V means 0.25mA
: 48V means    1mA
: 110V means 2.2mA
: 230V means  5mA


So that's not "kills immediately levels".


The thing is that a human drenched in salty water, eager to grab conductors solidly? A few factors more. Let's be pessimisic and say ten times
: 5V means    1mA
: 12V means  2.5mA
: 48V means  10mA
: 110V means  22mA
: 230V means  50mA


'''More on the heart'''


So very roughly speaking,
The heart is not so easily thwarted - to interrupt the heart you need to sustain a voltage, because you have to knock it out of its regular rhythm, and instead of slowly pump will sort of quickly twitch - called [https://en.wikipedia.org/wiki/Atrial_fibrillation fibrilation] {{comment|(which is why a [https://en.wikipedia.org/wiki/Defibrillation ''de''fibrilator], the thing that makes your heart go normal again, is called that)}}.
: average case and wallplug voltages won't kill you,
: 48V with worst case people is felt but still safe.
As these voltages were chosen with human safety in mind (balanced with efficiency of power transfer), this is not surprising.




This is not a complete story, though -- '''The other thing that matters''' is the '''''path''''' the electricity takes
If sustained, it takes only a few mA through the heart for fibrilation to potentially happen happen ''but only if delivered directly'' to the heart. Internal defibrilator paddles used in heart surgery (they look a bit like spoons) are less dramatic.
* skin-to-skin means most electricity flowing will be through the skin, and not far below
: this will hurt because you've got nerves there, but not really interfere with organs


* being very sweaty lowers resistance because water plus salt is an electrolyte solution
Doing the same from the surface not only needs to get through your fairly skin (which has high resistance), it also needs to deal with the fact the current then spreads around. This is why you'd need 30+ mA total before more than a few would be going through the heart rather than other parts of you, and more if you're not doing it near the heart.
: yet that's also the reason that mots of the additional current goes over the surface, where that water is.


* shorter paths will be a bit more superficial
This is also why regular defibrilators use larger paddles, or more recently, stick-on conductors, and deliver on the order of 1000V {{comment|(which is why they need a little time to charge, though movies exaggerate this)}}.
: but you don't control that in accidents


* if you bypass the skin, e.g. stab yourself with electrodes or stick them into wounds, then you'll often stick to what are effectively [https://en.wikipedia.org/wiki/Electrolyte electrolytes]
: Two issues:
:: electrolyte means lower resistance, meaning a dozen volts is now already dangerous.
:: the path will more easily go through more much more of you -- most relevantly the heart. The issue here is that a dozen mA is enough to risk [https://en.wikipedia.org/wiki/Ventricular_fibrillation fibrilation].


Fibrilation is not something you particularly feel happening,
and because your oxygen doesn't deplete within seconds,
you will function while fibrilating for maybe a minute feeling nothing beyond a bit woozy,
which an already-small time window in which to fix it smaller.
There are now fully automated defibrilator kits, which only shock you when they detect you are actually fibrilating, as to not make things worse when you misjudged, also to stop once you're fine.


They also tend to have spoken instructions, so that anyone can do this.
And it's recommended you try if you can, because survival is most likely in the first three or so minutes,
and no ambulance is that fast.


So:
* Say you touch your music player's or laptop's adapter (most are between 5 and 20 volts), or car battery
: Say it's approx 10V DC
: For numerical convenience's sake, say your resistance is 5kOhm (''very'' sweaty)
: Via I=V/R, the current is on the order of 2 mA.
: This may be just enough to feel, but possibly not. (Up to 5mA is considered harmless)




* Say you manage to stick your fingers into wall-plug voltage (120 or 230 volts AC), and you get ''maybe'' 50 mA.
http://en.wikipedia.org/wiki/Electric_shock
: You'll certainly feel that, and sustain this sort of thing and you ''will'' be in trouble.  
: Yet a momentary touch will usually do nothing more than rattle you a bit
: it's also enough to affect muscles, which is a problem when those muscles ''grab'' what you're touching
: {{comment|(side note: DC would feel less like a sting than AC)}}




* say you do the latter when sweating profusely
: you are covered with a decent conductor, which means there will be more current flowing
: ...''mostly'' over your skin, so mostly it'll just hurt more.
: ...but also a little more into you, so if well placed, and sustained, your heart will notice


For a fast death you need at least hundreds of volts if sweaty, thousands if not,
or stick electrodes through your skin into your inner electrolytes.
This is why electricity isn't all that dangerous, assuming you take basic care.


-->


For the same reason, when you have a power adapter, it's only the voltage that matters.
====="It isn't the volts that kill you, it's the amps"=====
That current figure is not what it ''will'' output, it's what it ''could'' output (when
<!--
the load is low-resistance enough) without burning itself.


{{comment|(Actually, the current capacity says something about minimum effective resistance, which ''does'' matter a tiny bit, but it's still as relevant as the second bit:)}}
This is both true and potentially misleading.


It also doesn't really explain anything.






For some idea of how much current your body doesn't like:
* 5mA is a level you can feel, but which is not yet dangerous
* 30mA going through your body is where you need to start worrying.
: it's not enough to burn, but you don't want it to be longer than a quick jolt.


{{comment|(Note that above a few dozen volts (and at higher frequencies), some other effects also start to contribute)}}


So is a car battery rated to move 50A into your starter monitor many many times deadly?
...no.  You can touch it all day and it won't do anything.




https://www.youtube.com/watch?v=9kr1MNIwwiM
It's not the ''ability'' to move current, it's ''actually'' moving current
-->


=====On current capacity=====
Assuming that a human is relatively constant resistance,
<!--
I=V/R means the current is proportional to the voltage.
Current capacity also matters.


On that order? If we assume a dry human barely touching a wire then let's say 50kOhm.
Plug this, and some everyday voltages into I=V/R, and you get:
: 5V means  0.1mA
: 12V means 0.25mA
: 48V means    1mA
: 110V means 2.2mA
: 230V means  5mA


In most case, high voltage means proportionally higher current, becaseu
So that's not "kills immediately levels".
: I=V/R
: resistance is fairly constant (even for things with inductive/capacitive effects, the continuous draw comes largely form the real part of that impedance)
: your power supply won't run out of current very easily
 


The thing is that a human drenched in salty water, eager to grab conductors solidly? A few factors more. Let's be pessimisic and say ten times
: 5V means    1mA
: 12V means  2.5mA
: 48V means  10mA
: 110V means  22mA
: 230V means  50mA


Can you have high voltage without proportionally higher current?


Yes, but they are relatively rare.
So very roughly speaking,
: average case and wallplug voltages won't kill you,
: 48V with worst case people is felt but still safe.
As these voltages were chosen with human safety in mind (balanced with efficiency of power transfer), this is not surprising.




This is not a complete story, though -- '''The other thing that matters''' is the '''''path''''' the electricity takes
* skin-to-skin means most electricity flowing will be through the skin, and not far below
: this will hurt because you've got nerves there, but not really interfere with organs


For example, you might build up 30kV or so shuffling on your carpet,
* being very sweaty lowers resistance because water plus salt is an electrolyte solution
but since your body is a ~200pF capacitor or at best,
: yet that's also the reason that mots of the additional current goes over the surface, where that water is.
you can't hold much charge, which means the discharge is ''always'' short, and the energy moved is tiny (see also [[ESD]]).


While this is enough to damage microelectronics (see [[ESD]]), people aren't going to care beyond the basic sting.
* shorter paths will be a bit more superficial
: but you don't control that in accidents


* if you bypass the skin, e.g. stab yourself with electrodes or stick them into wounds, then you'll often stick to what are effectively [https://en.wikipedia.org/wiki/Electrolyte electrolytes]
: Two issues:
:: electrolyte means lower resistance, meaning a dozen volts is now already dangerous.
:: the path will more easily go through more much more of you -- most relevantly the heart. The issue here is that a dozen mA is enough to risk [https://en.wikipedia.org/wiki/Ventricular_fibrillation fibrilation].




Similarly, a small Van Der Graaff generator[https://en.wikipedia.org/wiki/Van_de_Graaff_generator]'s dome may be 20 pF.
While it too can build built thousands of volts and you can still safely zap your students on the nose (no hard feelings),
because these devices have tiny current capacity, meaning their ability to deliver current drops so quickly that it can't sustain anything,
and the actual energy delivered (per time) can never be large.
Attaching a Leiden jar may get it to a much more noticeable 1nF (1000pF), but even that doesn't matter too much.


So:
* Say you touch your music player's or laptop's adapter (most are between 5 and 20 volts), or car battery
: Say it's approx 10V DC
: For numerical convenience's sake, say your resistance is 5kOhm (''very'' sweaty)
: Via I=V/R, the current is on the order of 2 mA.
: This may be just enough to feel, but possibly not. (Up to 5mA is considered harmless)




Load also matters.
* Say you manage to stick your fingers into wall-plug voltage (120 or 230 volts AC), and you get ''maybe'' 50 mA.
Say, there are tasers marketed as millions of volts.
: You'll certainly feel that, and sustain this sort of thing and you ''will'' be in trouble.  
Which is sort of bullshit, because you would need a ''very'' large air gap to build up that much without arcing.  
: Yet a momentary touch will usually do nothing more than rattle you a bit
It turns out this is just zero-load rating, which is ''irrelevant'' when it is actually on a human.
: it's also enough to affect muscles, which is a problem when those muscles ''grab'' what you're touching
 
: {{comment|(side note: DC would feel less like a sting than AC)}}
https://www.youtube.com/watch?v=DOMs7mYm_zs




* say you do the latter when sweating profusely
: you are covered with a decent conductor, which means there will be more current flowing
: ...''mostly'' over your skin, so mostly it'll just hurt more.
: ...but also a little more into you, so if well placed, and sustained, your heart will notice
For a fast death you need at least hundreds of volts if sweaty, thousands if not,
or stick electrodes through your skin into your inner electrolytes.
This is why electricity isn't all that dangerous, assuming you take basic care.




In other words, you need both highish voltage, and decent current capacity, before it's dangerous to people.
For the same reason, when you have a power adapter, it's only the voltage that matters.
That current figure is not what it ''will'' output, it's what it ''could'' output (when
the load is low-resistance enough) without burning itself.


For example, a car battery can give you higher current most wallplugs can,
{{comment|(Actually, the current capacity says something about minimum effective resistance, which ''does'' matter a tiny bit, but it's still as relevant as the second bit:)}}
because a starter motor may wish to draw up to 50A or so.


Which is pretty good current capacity, for a battery (technically it drops).


But because it's only 12V, applied to a dry human it's an imperceptible and safe 0.1mA, and even on sweaty human skin (10kOhm) it's a barely perceptible ~1mA (0.001A)


The only way that starter motor would get 50A is because it was designed to have approx 0.25 Ohm resistance.
(the starter motor is also one of the main reason those battery cables are so beefy{{verify}} - most other things draw ''much'' less)




-->
{{comment|(Note that above a few dozen volts (and at higher frequencies), some other effects also start to contribute)}}


====Electricity and heat====


=====Resistive heat=====
<!--
Mostly resistive


also arcs
https://www.youtube.com/watch?v=9kr1MNIwwiM
-->
-->
======On circuit breakers======
 
=====On current capacity=====
<!--
<!--
Current capacity also matters.


Circuit breakers only protect the wiring in your walls.


The breaker for a circuit trips at a current that is based on the thickness of the conductors in your walls,
In most case, high voltage means proportionally higher current, becaseu
so that if you draw enough current to get them hot, the breaker will trip. (Rather than, you know, the wall potentially burning).
: I=V/R
: resistance is fairly constant (even for things with inductive/capacitive effects, the continuous draw comes largely form the real part of that impedance)
: your power supply won't run out of current very easily


That said, this considered system stops at the wallsocket. Case in point...




-->
Can you have high voltage without proportionally higher current?
======On extension cords======
<!--
That said, you usually can still do unsafe things with just current - in particular with extension cords,
in part because the cheapest extension cords will thinner conductors, you often use them on multiple devices, so unless you are aware of the rating of everything.


More importantly, few extension cords have a fuse.  
Yes, but they are relatively rare.
Roughly the only exception to this is the UK, which puts fuses in all plugs. (Well, most{{verify}}.)




Which means there is no overcurrent protection on the extension cord's cord.


For many situations this is fine.
For example, you might build up 30kV or so shuffling on your carpet,
Say, why use an extension cord rated for more than 13A when you may only put a 0.1A lamp on it?
but since your body is a ~200pF capacitor or at best,
you can't hold much charge, which means the discharge is ''always'' short, and the energy moved is tiny (see also [[ESD]]).


In other cases, people just add extension cords until they can plug in all the things.
While this is enough to damage microelectronics (see [[ESD]]), people aren't going to care beyond the basic sting.


The space between the 13A that many extension cords are rated at, and the 16A and 20A circuits that are common enough in various countries, is overcurrent that has no protection.




And the cable insulation may be flammable.
Similarly, a small Van Der Graaff generator[https://en.wikipedia.org/wiki/Van_de_Graaff_generator]'s dome may be 20 pF.
As may the floor or other thing it's lying on.
While it too can build built thousands of volts and you can still safely zap your students on the nose (no hard feelings),
because these devices have tiny current capacity, meaning their ability to deliver current drops so quickly that it can't sustain anything,
and the actual energy delivered (per time) can never be large.
Attaching a Leiden jar may get it to a much more noticeable 1nF (1000pF), but even that doesn't matter too much.


It's worse when they're coiled up, largely just because you're concentrating the heat
and making it harder for air to cool it.




Load also matters.
Say, there are tasers marketed as millions of volts.
Which is sort of bullshit, because you would need a ''very'' large air gap to build up that much without arcing.
It turns out this is just zero-load rating, which is ''irrelevant'' when it is actually on a human.


The awareness and response is mixed.
https://www.youtube.com/watch?v=DOMs7mYm_zs


There's some rules of thumb, like "never use more than one extension cord",
which does nothing to teach what the actual issue is, and isn't necessarily safe,
but at least is better than ''zero'' awareness.


There is also some division between
people being almost afraid to use extension cords because they heard it's dangerous, and
people saying you don't need fuses or regulation because you just shouldn't do stupid things.


-->


=====Arcs and arc faults=====
In other words, you need both highish voltage, and decent current capacity, before it's dangerous to people.


<!--
For example, a car battery can give you higher current most wallplugs can,
because a starter motor may wish to draw up to 50A or so.


Arc faults are any reason where arcing sparks happen,  
Which is pretty good current capacity, for a battery (technically it drops).
usually due to loose wiring, or corroded wires.
Or even just dirty contacts.  


If a switch or outlet buzzes, this is probably that.
But because it's only 12V, applied to a dry human it's an imperceptible and safe 0.1mA, and even on sweaty human skin (10kOhm) it's a barely perceptible ~1mA (0.001A)


The only way that starter motor would get 50A is because it was designed to have approx 0.25 Ohm resistance.
(the starter motor is also one of the main reason those battery cables are so beefy{{verify}} - most other things draw ''much'' less)


It's not an overcurrent fault (it's often fairly low current)
and usually not a ground fault either.


That is to say, the arcing can be
-->
: line to neutral, or
: series arcing, or
: line/neutral to ground


The last may (or may not!) be caught by a ground fault protector (not what it's designed for, but doesn't hurt),
====Electricity and heat====
while the first two are basically just loads, and won't be caught by any regular breaker.


=====Resistive heat=====
<!--
Mostly resistive


Because this is heat, and sparks, this is potentially dangerous,
also arcs
by slowly melting insulation, and potentially setting fires.
 
While people will generally notice this, in some situations
 
-->
-->
======On circuit breakers======
<!--


===Protections===
Circuit breakers only protect the wiring in your walls.
====Safety earth====


'''Why?'''
The breaker for a circuit trips at a current that is based on the thickness of the conductors in your walls,
so that if you draw enough current to get them hot, the breaker will trip. (Rather than, you know, the wall potentially burning).


Earth wiring within a house is there for safety.
That said, this considered system stops at the wallsocket. Case in point...


Short version: it is a return connection that is much lower impedance than ''you'' are - and passes enough current enough that a fuse or circuit breaker would soon disconnect the live wire.


-->
======On extension cords======
<!--
That said, you usually can still do unsafe things with just current - in particular with extension cords,
in part because the cheapest extension cords will thinner conductors, you often use them on multiple devices, so unless you are aware of the rating of everything.


One of the main uses is earthing a conductor that should never be live - but might become so when things fail.
More importantly, few extension cords have a fuse.
For example, the chassis of a toaster or washing machine or such.
Roughly the only exception to this is the UK, which puts fuses in all plugs. (Well, most{{verify}}.)


If they eventually break so that wiring comes loose and touches the outside, and you want to design for that possibility.


Which means there is no overcurrent protection on the extension cord's cord.


'''With safety earth''' on that chassis, that's a short across your house's breaker, which will probably trip, meaning the dangerous voltage on that chassis is on there for a fraction of a second.
For many situations this is fine.
Say, why use an extension cord rated for more than 13A when you may only put a 0.1A lamp on it?


(Also it's across two chunky wires that won't have any issue with that current for factors longer than that)
In other cases, people just add extension cords until they can plug in all the things.


Even if you touch it within this time, the earth wire is much lower resistance to earth and (since this is a voltage divider) you shouldn't feel much.
The space between the 13A that many extension cords are rated at, and the 16A and 20A circuits that are common enough in various countries, is overcurrent that has no protection.




'''Without safety earth''', the live wire touching the chassis mean nothing other than that it is now at mains potential.
And the cable insulation may be flammable.
As may the floor or other thing it's lying on.


This has few immediate implications, but ''you'' will notice this when you next touch this and you are even vaguely earthed.
It's worse when they're coiled up, largely just because you're concentrating the heat
and making it harder for air to cool it.


The current through you is also much lower than any real use, so there is no reason for a breaker to trip.




(Which is why RCDs exist, and ''complement'' breakers)
The awareness and response is mixed.


There's some rules of thumb, like "never use more than one extension cord",
which does nothing to teach what the actual issue is, and isn't necessarily safe,
but at least is better than ''zero'' awareness.


There is also some division between
people being almost afraid to use extension cords because they heard it's dangerous, and
people saying you don't need fuses or regulation because you just shouldn't do stupid things.


-->


'''What?'''
=====Arcs and arc faults=====


Earth (or earth ground) refers to a physical pole hammered into the earth somewhere nearby.
<!--


Earth wiring is connected to that pole.
Arc faults are any reason where arcing sparks happen,
usually due to loose wiring, or corroded wires.
Or even just dirty contacts.  


Typically this is also bonded to things like radiator pipes, water pipes, steel structures.
If a switch or outlet buzzes, this is probably that.
So generally all these things are at most a few ohms to this earth.




Devices like think ovens, washing machine, etc. are typically designed with safety earth,
It's not an overcurrent fault (it's often fairly low current)
and using them safely will ''require'' that connection to earth - which, due to electrical code, usually just means 'socket with earth pin'.
and usually not a ground fault either.


Some (big) devices will even test the grounding and refuse to work if not present.
That is to say, the arcing can be
Yet most will assume that your electrical wiring is not violating electric code.
: line to neutral, or
Just at all, or because they have an earthed plug and it's technically a code violation to have an earthed socket that isn't actually earthed.
: series arcing, or
: line/neutral to ground


The last may (or may not!) be caught by a ground fault protector (not what it's designed for, but doesn't hurt),
while the first two are basically just loads, and won't be caught by any regular breaker.


(Note that powering things on generators is a little more interesting, ground-wise)


<!--
Because this is heat, and sparks, this is potentially dangerous,
House wiring also ties earth to neutral -- once, and only to avoid a floating neutral,  
by slowly melting insulation, and potentially setting fires.
and only because a floating neutral could avoid the breaker tripping {{verify}}
 
While people will generally notice this, in some situations
 
-->
-->


===Protections===
====Safety earth====


=====Earth versus ground=====
'''Why?'''
<!--
'''Earth''' is a closeby pole in the ground.


And to a mains panel connecting it in a way that allows high currents to flow and thereby the breakers to trip. Which in most places is ''required''.
Earth wiring within a house is there for safety.


Short version: it is a return connection that is much lower impedance than ''you'' are - and passes enough current enough that a fuse or circuit breaker would soon disconnect the live wire.


'''Ground''' is typically just a name for the most common reference shared by many components.


It need not be the lowest potential for that circuit (though often is),
One of the main uses is earthing a conductor that should never be live - but might become so when things fail.
it need not relate to mains earth,
For example, the chassis of a toaster or washing machine or such.
it need not be a safety feature.


If they eventually break so that wiring comes loose and touches the outside, and you want to design for that possibility.


Battery powered things have a ground that obviously have no relation,


but also powering something through a transformer means that circuit will float (relative to the primary side of that transformer),
'''With safety earth''' on that chassis, that's a short across your house's breaker, which will probably trip, meaning the dangerous voltage on that chassis is on there for a fraction of a second.
and isolation transformers even make their output side float intentionally (see also below).
Non-earthed adapters implicitly do this too.


(Also it's across two chunky wires that won't have any issue with that current for factors longer than that)
Even if you touch it within this time, the earth wire is much lower resistance to earth and (since this is a voltage divider) you shouldn't feel much.


On the other hand, and device or adapter that has an earthed cable?
Assume it as tied neutral to ground, making a mains-earth-referenced ground.


You can assume this for anything that you expect to draw more than a few dozen Watts.
'''Without safety earth''', the live wire touching the chassis mean nothing other than that it is now at mains potential.


Most audio equipment does ''not'', because they're trying to dodge the [[ground loop]] problem by sharing earth at most via their interconnects,
This has few immediate implications, but ''you'' will notice this when you next touch this and you are even vaguely earthed.
and not ''also'' sharing via mains earth.
(Amplifiers are usually the only devices that have to deliver power, and the rest can be safe in other ways)


The current through you is also much lower than any real use, so there is no reason for a breaker to trip.


Things like USB are tied to earth in computers, so when USB is just one option to power a device,
it my tie a previously-floating device to earth via earth.


(Which is why RCDs exist, and ''complement'' breakers)




For oscilloscopes it's relevant in that you can safely ignore polarities when measuring a floating circuit,
you'll e.g. be fine if you connect its ground to the floating circuit's Vcc {{comment|(it'll reference its Vcc to earth, which has no further effect because there is no ''circuit'', no loop)}} -- but once that devices is earth-referenced for some reason, that same thing means you are creating a short between its Vcc and its ground.


Lab power supplies are interesting for a similar reason. They often have a +, -, and Gnd.
The + and - by themselves are floating and you can typically ignore Gnd.
You can however short - to Gnd and have a mains-earth-referenced power supply.
You often don't need to, and if you do need this you'll typically know this stuff.


-->
'''What?'''


====Residual-current devices====
Earth (or earth ground) refers to a physical pole hammered into the earth somewhere nearby.
{{stub}}


Known under varied terms, including:
Earth wiring is connected to that pole.
* Residual-current devices (RCD)
* Ground fault circuit interrupter (GFCI)


* Ground fault interrupter (GFI)
Typically this is also bonded to things like radiator pipes, water pipes, steel structures.
* residual-current circuit breaker (RCCB)
So generally all these things are at most a few ohms to this earth.
: {{comment|(Note: an ''RCBO'' is a residual-current protection ''and'' an overcurrent protection in one)}}
* Earth leakage circuit breaker (ELCB)
* Appliance leakage current interrupter (ALCI)
* Leakage Current Detection Interrupter (LCDI)
* FI - Fehler and I indicating current {{verify}}
* Differential circuit breaker




There are apparently a few different designs.
Devices like think ovens, washing machine, etc. are typically designed with safety earth,
The common variant measures the current difference between the current going through the live and neutral wire, because those two currents should be exactly the same. {{comment|Conceptually / component-wise, you can think of it as a small sensing transformer coil around both live and neutral wire. When current in is equal to current out, that sensing transformer outputs nothing.)}}
and using them safely will ''require'' that connection to earth - which, due to electrical code, usually just means 'socket with earth pin'.


And if there is a difference, we assume that the extra current path is via ground (either the socket's safety earth, or the literal ground), and for safety we assume this might be going through a human, so it trips to cut power.
Some (big) devices will even test the grounding and refuse to work if not present.
Yet most will assume that your electrical wiring is not violating electric code.
Just at all, or because they have an earthed plug and it's technically a code violation to have an earthed socket that isn't actually earthed.




Electrical code varies when it comes to RCDs. Building styles also vary, with country and with time.
(Note that powering things on generators is a little more interesting, ground-wise)
Sometimes you'll see a chunky RCD on each leg/phase, at the power board, only.
Others add them per socket, e.g. only in the kitchen and shower.
Others protect other areas, double them up to project everything but trip smaller zones, and other variations.


<!--
House wiring also ties earth to neutral -- once, and only to avoid a floating neutral,
and only because a floating neutral could avoid the breaker tripping {{verify}}
-->


You can also get RCD extension cords, which can e.g. make sense when you do electronics repair work, both
: because you can get one that responds faster and for lower current,
: and because it avoids annoying other people in the same house, as a faster-tripping workstation RCD one should generally avoid the house RCD from tripping.


Also, more RCDs make it a little easier to diagnose who/what tripped it.
=====Earth versus ground=====
<!--
'''Earth''' is a closeby pole in the ground.


Building sites frequently put a series of larger-and-smaller RCDs on different areas because it interrupts fewer people and makes it easier to diagnose who's tripping it.
And to a mains panel connecting it in a way that allows high currents to flow and thereby the breakers to trip. Which in most places is ''required''.




'''Ground''' is typically just a name for the most common reference shared by many components.
It need not be the lowest potential for that circuit (though often is),
it need not relate to mains earth,
it need not be a safety feature.


<!--
RCD aim to trip at the order of 5-30mA for 20 milliseconds or so,
as a balance between 'most humans will survive that'
and making it less sensitive to stray currents, and making nuisance trips unlikely.


Certain situations (e.g. datacenters) may use higher values because false trips are much more costly (and there is some protective equipment that would trip RCDs more easily{{verify}}).
Battery powered things have a ground that obviously have no relation,


but also powering something through a transformer means that circuit will float (relative to the primary side of that transformer),
and isolation transformers even make their output side float intentionally (see also below).
Non-earthed adapters implicitly do this too.




The typical trip currents also vary, e.g.
On the other hand, and device or adapter that has an earthed cable?
For
Assume it as tied neutral to ground, making a mains-earth-referenced ground.
: home installations in 230V countries, typically ~30mA for ~20 milliseconds
: home installations in 120V countries, often quoted as just "5mA".
:: I've not been able to find the time that belongs to. A graph from UL943 suggests it's allowed to be much longer (multiple seconds at 6mA, more than half a second at 30mA), though I've also read it's much smaller than that in most devices (&le;25ms?).


-->
You can assume this for anything that you expect to draw more than a few dozen Watts.


Most audio equipment does ''not'', because they're trying to dodge the [[ground loop]] problem by sharing earth at most via their interconnects,
and not ''also'' sharing via mains earth.
(Amplifiers are usually the only devices that have to deliver power, and the rest can be safe in other ways)


<!--
'''Types'''


Type AC - trips for residual AC currents
Things like USB are tied to earth in computers, so when USB is just one option to power a device,  
: the most basic type
it my tie a previously-floating device to earth via earth.
: covers most domestic 'humans touching AC' needs, including selective protection of ovens, immersion heaters, electric showers, and the like.
: some power supplies may draw very high current for ''micro''seconds and still trip this - F, B, AKV, EV all seem better behaved around this
: no time delay?{{verify}}


Type A - what type AC does, and adds sensitivity to (low-frequency) pulsating currents
: ignores a few mA of smooth DC{{verify}}
: (diagram suggests better sensitivity to halfwave rectification??)


Type F - what type A does, and adds sensitivity to higher frequency switching
: e.g. from certain motor drives, some types of air conditioners and heat pumps
: ignores a few mA of smooth DC{{verify}}
: less known because type B does more{{verify}}


Type B - roughly what type F does, and adds sensitivity to pulsing and smooth DC currents
For oscilloscopes it's relevant in that you can safely ignore polarities when measuring a floating circuit,
: DC often comes from three-phase rectifiers, e.g. in larger installations
you'll e.g. be fine if you connect its ground to the floating circuit's Vcc {{comment|(it'll reference its Vcc to earth, which has no further effect because there is no ''circuit'', no loop)}} -- but once that devices is earth-referenced for some reason, that same thing means you are creating a short between its Vcc and its ground.
: preferable where you have three-phase systems actually interacting (large PV systems, )
 
Lab power supplies are interesting for a similar reason. They often have a +, -, and Gnd.
The + and - by themselves are floating and you can typically ignore Gnd.
You can however short - to Gnd and have a mains-earth-referenced power supply.
You often don't need to, and if you do need this you'll typically know this stuff.
 
-->
 
====Residual-current devices====
{{stub}}
 
Known under varied terms, including:
* Residual-current devices (RCD)
* Ground fault circuit interrupter (GFCI)
 
* Ground fault interrupter (GFI)
* residual-current circuit breaker (RCCB)
: {{comment|(Note: an ''RCBO'' is a residual-current protection '''''and''''' an overcurrent protection in one)}}
* Earth leakage circuit breaker (ELCB)
* Appliance leakage current interrupter (ALCI)
* Leakage Current Detection Interrupter (LCDI)
* FI - Fehler and I indicating current {{verify}}
* Differential circuit breaker
 
 
There are apparently a few different designs.
The common variant measures the current difference between the current going through the live and neutral wire, because those two currents should be exactly the same. {{comment|Conceptually / component-wise, you can think of it as a small sensing transformer coil around both live and neutral wire. When current in is equal to current out, that sensing transformer outputs nothing.)}}
 
And if there is a difference, we assume that the extra current path is via ground (either the socket's safety earth, or the literal ground), and for safety we assume this might be going through a human, so it trips to cut power.
 
 
'''Electrical code''' varies when it comes to RCDs.
Building styles also vary, with country and with time.
: Sometimes you'll see a chunky RCD on each leg/phase at the power board - only.
: Others add them per socket, and then often only in the kitchen and shower.
Others protect other areas, double them up to project everything but trip smaller zones, and other variations.
 
 
 
Building sites may put a series of larger-and-smaller RCDs on different areas because it interrupts fewer people from working, and makes it easier to diagnose who's tripping it.
 
 
You can also get '''RCD extension cords''', which can e.g. make sense when you do electronics repair work,
possibly for rooms that are not protected (if that applies to your house).
 
While a lot of them are standard-valued, you can sometimes get ones that responds faster and for lower current,
which can be marginally safer, and sometimes more importantly, means the one at your desk trips,
not the house one, saving you and possible housemates a lot of annoyance and waling.
 
You'll probably accept just your DIY setup being overly triggery,
(and/or better isolate the causes).
 
 
Certain situations (e.g. datacenters) may use higher values,
because false trips are much more costly,
there can be some protective equipment that would trip RCDs more easily{{verify}},
and technicians can be instructed better than random people in random houses.
 
 
 
RCD aim to trip at the order of a dozen milli-amps for a dozen milliseconds or so,
as a balance between 'most humans will survive that'
and making it less sensitive to stray currents, and making nuisance trips unlikely.
 
 
The typical trip currents vary, e.g.
For
: home installations in 230V countries, typically ~30mA for ~20 milliseconds
: home installations in 120V countries, often quoted as just "5mA".
:: I've not been able to find the time that belongs to. A graph from UL943 suggests it's allowed to be much longer <!-- (multiple seconds at 6mA, more than half a second at 30mA), though I've also read it's much smaller than that in most devices (&le;25ms?).
 
 
 
There are a bunch of types,
mostly addressing things it specifically should, or specifically shouldn't be sensitive to.
 
 
<!--
'''Types'''
 
Type AC - trips for residual AC currents
: the most basic type
: covers most domestic 'humans touching AC' needs, including selective protection of ovens, immersion heaters, electric showers, and the like.
: some power supplies may draw very high current for ''micro''seconds and still trip this - F, B, AKV, EV all seem better behaved around this
: no time delay?{{verify}}
 
Type A - what type AC does, and adds sensitivity to (low-frequency) pulsating currents
: ignores a few mA of smooth DC{{verify}}
: (diagram suggests better sensitivity to halfwave rectification??)
 
Type F - what type A does, and adds sensitivity to higher frequency switching
: e.g. from certain motor drives, some types of air conditioners and heat pumps
: ignores a few mA of smooth DC{{verify}}
: less known because type B does more{{verify}}
 
Type B - roughly what type F does, and adds sensitivity to pulsing and smooth DC currents
: DC often comes from three-phase rectifiers, e.g. in larger installations
: preferable where you have three-phase systems actually interacting (large PV systems, )
 
AKV
 
EV
: trip if DC component > 6mA
 
 
Type S - specifically time-delayed (think 200ms at 100mA).
: '''Not mean for personal protection''', mainly for things like fire risk in industrial installations.
 
 
TODO: make this a table
 
 
 
AC covers the most basic use, like washing machines and heaters.
 
There are some devices that create pulsating DC(-like) current,
often from diode or thyristor rectifiers, such as some cooking plates, or single phase inverters like some PV setups{{verify}}.
Type AC is less sensitive to this{{verify}}, and Type A is preferred for proper protection.
 
Similarly, DC-residual faults can effectively saturate the AC-type and make type AC trip less, i.e. protect less.
: ...but they're probably not common in home use?{{verify}}
 
While DC residual faults were previously most likely at larger, commercial/industrial installations,
they are becoming more common in home installations, with things like inverters (e.g. PV systems),
vehicle chargers, and some power-saving features on larger devices.
 
So type AC is being phased out, in favour of type A, or preferably B,
which will trip in more varied dangerous cases so be safer
(while also being more specific on a few cases they shouldn't trip on{{verify}}).
 
 
 
PV systems are a funny case, because while they used to be transformer-based and galvanically isolated,
newer styles are often basically fast switch mode, and basically not isolated (full reasons are more detailed).
It seems they have more (DC?) leakage, and in particular in moist weather this can be enough to trip a basic AC RCD{{verify}}.
 
 
The best solution varies. If the PV inverters are on their own circuit (they probably should be), a higher-valued RCD might work,
but it's not ideal and I'm not sure it's even allowed everywhere.
 
Note there are some extra requirements on RCDs like these, and there may be more local ones.
Say, some may ''effectively'' require type B. Which are pricy.
 
 
 
https://www.electrical-installation.org/enwiki/Types_of_RCDs
 
https://electrical.theiet.org/wiring-matters/years/2019/77-september-2019/which-rcd-type/
 
https://www.doepke.co.uk/downloads/Techpubs/Techpub-08.pdf
 


AKV


EV
: trip if DC component > 6mA


For fault testing an RCD device, it can be useful to know that 30mA amounts to "does it see less than ~7.5kOhm to ground" on 230V, and 3.5kOhm on 110V.)


Type S - specifically time-delayed (think 200ms at 100mA).
This is basically all that that test button does.
: '''Not mean for personal protection''', mainly for things like fire risk in industrial installations.




TODO: make this a table
In centrally installed RCDs consider the write after it, so if you make a test load, it should be a slightly lower resistance than that.


Note that when resistance between neutral and ground wires is larger (this is a code thing), the load may need to be higher


In theory, you want that resistor to be ~10W if you want it to not burn if the RCD failed.


AC covers the most basic use, like washing machines and heaters.
Apparently the test-button test resistors are often on the order of 2W order.
If you don't hold keep in in circuit it's also fine.


There are some devices that create pulsating DC(-like) current,
If it trips it's also fine, but since one of the test outcomes is that it doesn't, you shouldn't design something to assume it's not.
often from diode or thyristor rectifiers, such as some cooking plates, or single phase inverters like some PV setups{{verify}}.
Type AC is less sensitive to this{{verify}}, and Type A is preferred for proper protection.


Similarly, DC-residual faults can effectively saturate the AC-type and make type AC trip less, i.e. protect less.
: ...but they're probably not common in home use?{{verify}}


While DC residual faults were previously most likely at larger, commercial/industrial installations,
they are becoming more common in home installations, with things like inverters (e.g. PV systems),
vehicle chargers, and some power-saving features on larger devices.


So type AC is being phased out, in favour of type A, or preferably B,
which will trip in more varied dangerous cases so be safer
(while also being more specific on a few cases they shouldn't trip on{{verify}}).


Note that RCDs do not replace circuit breakers, in the sense that they do nothing to protect against overcurrent.
In a distribution board they are often alongside the real breaker for the same leg.


There are models that do both in one unit, see RCBO.
This is usually only done when there's space limitations, because replacing these things separately would be a little cheaper.


PV systems are a funny case, because while they used to be transformer-based and galvanically isolated,
newer styles are often basically fast switch mode, and basically not isolated (full reasons are more detailed).
It seems they have more (DC?) leakage, and in particular in moist weather this can be enough to trip a basic AC RCD{{verify}}.




The best solution varies. If the PV inverters are on their own circuit (they probably should be), a higher-valued RCD might work,
but it's not ideal and I'm not sure it's even allowed everywhere.


Note there are some extra requirements on RCDs like these, and there may be more local ones.
Say, some may ''effectively'' require type B. Which are pricy.


'''What could defeat RCDs'''


You cannot count on RCDs to work reliably on non-grounded systems.


https://www.electrical-installation.org/enwiki/Types_of_RCDs
The RCD detection mechanism itself works,
but the assumption that the leftover mismatch travels via ground would be more of a guess.


https://electrical.theiet.org/wiring-matters/years/2019/77-september-2019/which-rcd-type/
...because there's not any wired path to ground at all, which also means you can't become a path ''via'' ground either, and in theory an RCD would also not even be required for safety - you could touch a live chassis, or the phase wire in general.


https://www.doepke.co.uk/downloads/Techpubs/Techpub-08.pdf


In practice that's still a bad idea, because this is only safe as long as there isn't some ''stray'' connection to ground,
and in practice it's almost impossible to stay away from accidentally grounding something.


So you can assume that it is grounded, you just have no idea where or with what resistance.


Which also means you don't know where to install RCDs so that they are still guaranteed to trip.


For fault testing an RCD device, it can be useful to know that 30mA amounts to "does it see less than ~7.5kOhm to ground" on 230V, and 3.5kOhm on 110V.)
This is one of a few reasons most electrical installations are required to be earted with a big ole pipe ''somewhere'' (whether that's at your distribution board or down the street), and related to why there are typically strict rules about extra earths.


This is basically all that that test button does.


{{verify}}
-->


In centrally installed RCDs consider the write after it, so if you make a test load, it should be a slightly lower resistance than that.
See also:
* [[Electronics_notes/Ground#Residual-current_breakers_.28and_ground.29]] about ground, and comparison to regular breakers


Note that when resistance between neutral and ground wires is larger (this is a code thing), the load may need to be higher
====Arc fault protectors====


In theory, you want that resistor to be ~10W if you want it to not burn if the RCD failed.
An arc fault is an unintended discharge between conductors, from things like
: loose wiring connections
: overheating wiring that broke down insulation over time (note that breakers should make that impossible)
: otherwise damages wire insulation


Apparently the test-button test resistors are often on the order of 2W order.
The sparks and heat generated can further damage the wire, and lead to fire.
If you don't hold keep in in circuit it's also fine.


If it trips it's also fine, but since one of the test outcomes is that it doesn't, you shouldn't design something to assume it's not.
<!--
Arcs also happen without really being faults, e.g.
: holding a switch at just its flipover point
: in [[mechanical relays]] switching higher-current complex loads
-->






An arc-fault circuit interrupter (AFCI) measures
: fast switching (order of 100 kHz)
: of non-negligible current
: sustained for a few seconds.


Note that RCDs do not replace circuit breakers, in the sense that they do nothing to protect against overcurrent.
In a distribution board they are often alongside the real breaker for the same leg.


There are models that do both in one unit, see RCBO.
They seem to often be digital{{verify}}
This is usually only done when there's space limitations, because replacing these things separately would be a little cheaper.


They seem to often also integrate ground fault sensing.


====Design safety, and certification====


=====Certifications=====


<!--
In transformers/adapter, the fact that it contains a transformer makes it easy to do this via galvanic isolation{{verify}}


'''What could defeat RCDs'''


You cannot count on RCDs to work reliably on non-grounded systems.
Not zapping people
The more typical design on large devices is to have an earth wire
Earthing a metal case is


The RCD detection mechanism itself works,  
IEC
but the assumption that the leftover mismatch travels via ground would be more of a guess.
- IEC60950-1 classification
- 62368-1
- (IEC 61140?)
(square-in-square)
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_I Class I] means chassis is grounded
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_II Class II] means double insulated
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_III Class III] means the device is entirely low-voltage and safe to touch, and power conversion is external to it (and probably SELV)
http://pes-spdc.org/sites/default/files/guide-to-iec-tc108-safety-standards-parameters.pdf


...because there's not any wired path to ground at all, which also means you can't become a path ''via'' ground either, and in theory an RCD would also not even be required for safety - you could touch a live chassis, or the phase wire in general.
CE mark https://en.wikipedia.org/wiki/CE_marking
UL mark http://www.ul.com/
GS mark https://en.wikipedia.org/wiki/Gepr%C3%BCfte_Sicherheit
VDE https://www.vde.com/en/institute/portfolio/safety/Pages/Safety.aspx




In practice that's still a bad idea, because this is only safe as long as there isn't some ''stray'' connection to ground,
and in practice it's almost impossible to stay away from accidentally grounding something.


So you can assume that it is grounded, you just have no idea where or with what resistance.
-->


Which also means you don't know where to install RCDs so that they are still guaranteed to trip.


This is one of a few reasons most electrical installations are required to be earted with a big ole pipe ''somewhere'' (whether that's at your distribution board or down the street), and related to why there are typically strict rules about extra earths.
=====Double insulation=====
<!--
The 'double' refers to "in addition to the insulation on wires/components".


So if a live wire inside becomes loose,
or a wire/component insulation is gone for whatever reason,
there is ''some'' other reason the device won't immediately try to kill you.


{{verify}}
-->


See also:
In practice that often means either
* [[Electronics_notes/Ground#Residual-current_breakers_.28and_ground.29]] about ground, and comparison to regular breakers
: none of the outside case is conductive. Consider e.g. that vacuum cleaners typically have all-plastic cases.
: there is an extra non-conductive case (for protection) below a metal one (e.g. for sturdiness).  


====Arc fault protectors====
Take a look at various TVs, hairdryers, maybe some laptop adapters,
and see how they might do one of the above.


An arc fault is an unintended discharge between conductors, from things like
: loose wiring connections
: overheating wiring that broke down insulation over time (note that breakers should make that impossible)
: otherwise damages wire insulation


The sparks and heat generated can further damage the wire, and lead to fire.
Note that double insulation is unrelated to grounds-earth safety.


<!--
Arcs also happen without really being faults, e.g.
: holding a switch at just its flipover point
: in [[mechanical relays]] switching higher-current complex loads
-->
-->


====Galvanic isolation, floating outputs, floating ground====
<!--
Consider a phone charger, which takes 100+ volts and produces 5 volts.


Since 5V is safe for humans, if you can design so that there is no possible conducting connection between the ~100V and the ~5V sides (and no part that would do this in its ''usual'' failure modes).


An arc-fault circuit interrupter (AFCI) measures
That makes it much easier to guarantee that the maximum voltage and current that exist on the output side, and thereby guarantee safety in the person-touches-it-and-ground case.
: fast switching (order of 100 kHz)
: of non-negligible current
: sustained for a few seconds.




They seem to often be digital{{verify}}
It also means that the charger does not need to be grounded make touching its ''output'' safe.
When we're talking about the block itself it's still useful to take precautions simply because ''part'' of it is high voltage, e.g. isolating it well (see e.g. double insulation), or grounding it (I've seen some that essentially have a copper casing inside, though that was probably largely for EM interference).
-->


They seem to often also integrate ground fault sensing.
=====Isolation transformers=====
<!--
Using an '''isolation transformer''' means ''all'' power has to go through these windings.
Which devices that already ''are'' transformers could easily do.


====Design safety, and certification====


=====Certifications=====
One thing it avoids is DC currents through it.
This part is not very relevant for wallsockets, because they don't carry it.
It's still a useful choice in DC-producing devices like phone chargers and laptop chargers, because it helps isolate the two sides as mentioned above.


<!--
In transformers/adapter, the fact that it contains a transformer makes it easy to do this via galvanic isolation{{verify}}


The more interesting part, though, is that the output floats.


Not zapping people
'''Floating outputs''' and '''Floating ground''' mean almost the same thing.
The more typical design on large devices is to have an earth wire
Even if the circuit has a common low reference point that you may ''think'' of as ground.
Earthing a metal case is
There is nothing pulling it or any other level to anything else you can point at.


IEC
The most important things to say about this relate to noise, and to safety.
- IEC60950-1 classification
- 62368-1
- (IEC 61140?)
(square-in-square)
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_I Class I] means chassis is grounded
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_II Class II] means double insulated
- [https://en.wikipedia.org/wiki/Appliance_classes#Class_III Class III] means the device is entirely low-voltage and safe to touch, and power conversion is external to it (and probably SELV)
http://pes-spdc.org/sites/default/files/guide-to-iec-tc108-safety-standards-parameters.pdf


CE mark https://en.wikipedia.org/wiki/CE_marking
UL mark http://www.ul.com/
GS mark https://en.wikipedia.org/wiki/Gepr%C3%BCfte_Sicherheit
VDE https://www.vde.com/en/institute/portfolio/safety/Pages/Safety.aspx


Floating systems have little common mode '''noise''', because there ''is'' no common to fight over.
It avoids ground loops, because you avoid disagreement on what ''exactly'' is ground.
Balanced lines do this - one way to construct baluns are use of transformers this way.


However, it comes with footnotes relating to safety and blowing up of your devices.
It e.g. makes the audio interconnection discussion rather interesting.


-->


About '''safety''': Remember that in house wiring, earthing provides a return connection that is lower impedance than you.
Floating ground means that there ''is'' no ground, until ''you'' are the path to ground.


=====Double insulation=====
'''Having floating grounds by accident''' are unsafe -- because it means you didn't ground a device that was designed to be safer via it.
<!--
In more detail, means
The 'double' refers to "in addition to the insulation on wires/components".
: its chassis is at whatever voltage
 
: there is a potential difference to the place where your electricity is earthed
So if a live wire inside becomes loose,
: and you ''are'' the best path to ground
or a wire/component insulation is gone for whatever reason,
: the regular fuse won't blow because there's no ground wire for that current
there is ''some'' other reason the device won't immediately try to kill you.
: The thing that will save you in this situation is a RCD, because it notices the live wires don't balance




In practice that often means either
'''Floating ground by design''' can be quite safe, mostly because the design does not rely on ground as understood above.
: none of the outside case is conductive. Consider e.g. that vacuum cleaners typically have all-plastic cases.
Isolation transformers mean the entire output circuit is separate, so there is no circuit you would be completing by
: there is an extra non-conductive case (for protection) below a metal one (e.g. for sturdiness).  
standing in a puddle and poking your finger in(to ''either one'' of the pins).
 
Shaving sockets in (hotel) bathrooms usually do either this (...and also have a tiny fuse, so that it will deal with a short on the isolated circuit),
or by code are required to be behind an RCD.


Take a look at various TVs, hairdryers, maybe some laptop adapters,
If it's so safe, why not do it on everything?
and see how they might do one of the above.
A few reasons - you need to do it separately for each device (only one safe touch per circuit),
different floating devices should not interact{{verify}},
you can't combine it with high-current grounding{{verify}}.


-->


Note that double insulation is unrelated to grounds-earth safety.


-->
===Is 120V safer than 230V?===


====Galvanic isolation, floating outputs, floating ground====
<!--
<!--
Consider a phone charger, which takes 100+ volts and produces 5 volts.
Sort of.  
 


Since 5V is safe for humans, if you can design so that there is no possible conducting connection between the ~100V and the ~5V sides (and no part that would do this in its ''usual'' failure modes).
====Voltage and people====


That makes it much easier to guarantee that the maximum voltage and current that exist on the output side, and thereby guarantee safety in the person-touches-it-and-ground case.
Sure, everything else being equal,
: sticking your fingers in a 230V socket will make you pass twice the current through you,
: relative to doing the same in a 120V country.




It also means that the charger does not need to be grounded make touching its ''output'' safe.
If you feel a '...however' coming, you're right.
When we're talking about the block itself it's still useful to take precautions simply because ''part'' of it is high voltage, e.g. isolating it well (see e.g. double insulation), or grounding it (I've seen some that essentially have a copper casing inside, though that was probably largely for EM interference).  
 
-->


=====Isolation transformers=====
For one, saying it's twice as bad is ''way'' oversimplified.
<!--
Using an '''isolation transformer''' means ''all'' power has to go through these windings.
Which devices that already ''are'' transformers could easily do.


There are lots of details to this, many of which matter enough to at least mention.


One thing it avoids is DC currents through it.
This part is not very relevant for wallsockets, because they don't carry it.
It's still a useful choice in DC-producing devices like phone chargers and laptop chargers, because it helps isolate the two sides as mentioned above.


But there's a much dumber reason the difference is smaller:
* both are in the region where a quick touch is typically fine.
* both are in the region ''if you can't let go'', it will probably kill you


The more interesting part, though, is that the output floats.
...whether it kills you in a few seconds or a few ''more'' seconds is immaterial in most situations.


'''Floating outputs''' and '''Floating ground''' mean almost the same thing.
Even if the circuit has a common low reference point that you may ''think'' of as ground.
There is nothing pulling it or any other level to anything else you can point at.


The most important things to say about this relate to noise, and to safety.
So while 230V is theoretically going to kill you faster,
the cases in which this is true in practice are fairly specific.




Floating systems have little common mode '''noise''', because there ''is'' no common to fight over.
It is arguably much more important to have [[GFCI]]s, a.k.a. [[RCD]]s,
It avoids ground loops, because you avoid disagreement on what ''exactly'' is ground.
because this is their reason for existing.
Balanced lines do this - one way to construct baluns are use of transformers this way.


However, it comes with footnotes relating to safety and blowing up of your devices.
...and wherever you have RCDs, both become a lot less risky.
It e.g. makes the audio interconnection discussion rather interesting.
''Not that you should ever rely on them''.




About '''safety''': Remember that in house wiring, earthing provides a return connection that is lower impedance than you.
Floating ground means that there ''is'' no ground, until ''you'' are the path to ground.


'''Having floating grounds by accident''' are unsafe -- because it means you didn't ground a device that was designed to be safer via it.
https://electronics.stackexchange.com/questions/136981/whats-more-dangerous-110v-or-240v
In more detail, means
: its chassis is at whatever voltage
: there is a potential difference to the place where your electricity is earthed
: and you ''are'' the best path to ground
: the regular fuse won't blow because there's no ground wire for that current
: The thing that will save you in this situation is a RCD, because it notices the live wires don't balance
 
 
'''Floating ground by design''' can be quite safe, mostly because the design does not rely on ground as understood above.
Isolation transformers mean the entire output circuit is separate, so there is no circuit you would be completing by
standing in a puddle and poking your finger in(to ''either one'' of the pins).
 
Shaving sockets in (hotel) bathrooms usually do either this (...and also have a tiny fuse, so that it will deal with a short on the isolated circuit),
or by code are required to be behind an RCD.
 
If it's so safe, why not do it on everything?
A few reasons - you need to do it separately for each device (only one safe touch per circuit),
different floating devices should not interact{{verify}},
you can't combine it with high-current grounding{{verify}}.


-->




===Is 120V safer than 230V?===


<!--
Sort of.


====Current and heat====


'''Voltage and people'''
For the same amount of power you want to move around,


Everything else being equal, sticking your fingers in a 230V socket will make you pass twice the current through you,
120V implies higher currents than 230V for the same power draw, because P=VI
relative to doing the same in a 120V country.
: For example,  
:: a 100W lamp on 230V means 0.43A
:: a 100W lamp on 120V means 0.83A




If you feel a however coming, you're right.
There's two ways you can go with this argument.
 
 
For one, saying it's twice as bad is ''way'' oversimplified.
 
There are lots of details to this, many of which matter at least enough to mention.
 
 
But there's a much dumber reason the difference is smaller:
* both are in the region where a quick touch is typically fine.
 
* ''both'' are in the region ''if you can't let go'', it will probably kill you
: and whether it kills you a few seconds earlier or later is immaterial in most situations
 
 
So while 230V is theoretically going to kill you faster,
the cases in which this is true in practice are fairly specific.
 
 
It is arguably much more important to have [[GFCI]]s, a.k.a. [[RCD]]s,
because this is their reason for existing.
 
...and wherever you have RCDs, both become a lot less risky.
''Not that you should ever rely on them''.
 
 
 
https://electronics.stackexchange.com/questions/136981/whats-more-dangerous-110v-or-240v
 
 
 
 
 
'''Current and heat'''
 
120V implies higher currents than 230V for the same power draw, because P=VI
: For example, a 100W lamp on 230V means 0.43A, and a 100W lamp on 120V means 0.83A


 
* For one and the same wire, running the same power over it will make the wire run hotter at lower voltage
There's two ways you can go with this argument.
: because that wire has a given resistance, that lower voltage means higher current as mentioned, and P=I<sup>2</sup>R
: yet this ''mostly'' doesn't matter, because you choose the wire based on its rating


* lower-voltage countries need thicker wires for the same ''power''
* lower-voltage countries need thicker wires for the same ''power''
: but that ''mostly'' doesn't really matter, because there are other choices in distributing power
: but that ''mostly'' doesn't really matter, because it means practicalities (and the safety standards) just adapt.
: e.g. north America splits things into more circuits within a house. That may mean more wire (because some of that length is spent just on getting each to the breaker box)
: e.g. when distributing power in a house, north America splits things into more circuits within a house than most 230V countries do. That may mean more wire (because some of that length is spent just on getting each to the breaker box), but that... is a perfectly workable fix.


* For one and the same wire, running the same power over it will make the wire run hotter at lower voltage
: because that wire has a given resistance, that lower voltage means higher current as mentioned, and P=I<sup>2</sup>R
: but that doesn't really matter, because you choose the wire based on its rating




Both mean that as long as someone's thinking about it, it's all safe.
As long as someone's thinking about it, it's all safe.


And in house wiring, it's electrical code, and electricians that will lose their license if they sign off on something demonstrably stupid, so they do that thinking for you.
And in house wiring, it's electrical code,  
and (depending a little on where you are) electricians may well lose their license if they sign off on something demonstrably stupid.
So they do that thinking for you.


Electrical code basically thinks in current anyway.
Electrical code basically thinks in current anyway.
Line 1,950: Line 2,072:




'''What about extension cords?'''
====On extension cords?====


{{comment|(For now I'm interpreting this as 'up to 5 meters / 15 feet, mostly to split one into many sockets', not as 'carry it 30 meters / 100 feet or more', because the latter brings in some extra details. I'll get to it later.)}}
{{comment|(For now I'm interpreting this as 'up to 5 meters / 15 feet, mostly to split one into many sockets', not as 'carry it 30 meters / 100 feet or more', because the latter brings in some extra details. I'll get to it later.)}}


I always assumed that lower voltage means either hotter wires or more expensive power cords,
I always assumed that lower voltage means either hotter wires or more expensive power cords,
and that that's why the  
and that that's why the "OMG don't chain extension cords" and "OMG don't plug space heaters into extension cords"  
"OMG don't chain extension cords" and "OMG don't plug space heaters into extension cords"  
comes mostly from Americans and people in other 120V countries.  
comes mostly from Americans and people in other 120V countries.  


Line 1,965: Line 2,086:
...up to the wallsocket.
...up to the wallsocket.


Anything you plug into the wall may have thinner wire, so run hotter,
Anything you plug into the wall probably has thinner wire,  
so runs hotter,
because there's no guarantee what thickness/current rating that is.
because there's no guarantee what thickness/current rating that is.
This is true anywhere.  
This is true anywhere.  
Line 1,975: Line 2,097:
so it is possible to make ''those'' a too thin.
so it is possible to make ''those'' a too thin.


This is true in any country, any voltage.
This is true in any country, any voltage.  




There is, however, a difference in extension cords - in what gets made, and in certifications.
There is, however, a difference in extension cords - in what gets made, and in certifications.


Say, I live in a 230V country where houses 16A breakers by default.
Say, I live in a 230V country where house circuits use 16A breakers by default.
Almost all of the store-bought extension cords in my house I've found so far are rated 250V 16A.
Almost all of the store-bought extension cords in my house I've found so far are rated 250V 16A.
A few merely 10A, and that's not ''ideal'', that 10A is still good for a mere 2500W instead of 3500W (approximately).  
A few merely 10A, and that's not ''ideal'', that 10A is still good for a mere 2500W instead of 3500W (approximately).  
Line 1,986: Line 2,108:
Not that anyone thinks of that when plugging stuff in, and that's sort of the point here.
Not that anyone thinks of that when plugging stuff in, and that's sort of the point here.


US circuits tend to be 10A, sometimes or 20A,
US circuits tend to be 10A, sometimes 20A.
It's apparently easy to get a lot more varied extension cords - at least 5A, 7A, 12A, and 16A extension cords {{verify}}, which are choices like 600W, 850W, 1400W, and 1900W (approximately).  
It's apparently easy to get a lot more varied extension cords - at least 5A, 7A, 12A, and 16A extension cords {{verify}}, which are choices like 600W, 850W, 1400W, and 1900W (approximately).


So apparently saving a few bucks means there is a lot more variation, and a bunch more extension cords that are indeed not good for chunkier devices.
So apparently saving a few bucks means there is a lot more variation, and a bunch more extension cords that are indeed not good for chunkier devices.
Line 1,996: Line 2,118:
...because I see roughly three options
...because I see roughly three options
* teach everyone electronics (not going to happen)  
* teach everyone electronics (not going to happen)  
* don't care about it (less safe)
* don't care about it at all (less safe)
* be a little panicky about it (safer)
* be a little panicky about it (safer)


Line 2,003: Line 2,125:




-->
<!--
~100V is the practicual minimum - below that wires need to be very thick
~250V is the practical maximum - above that people sticking their fingers into sockets get dangerous amounts of current.
-->
-->

Revision as of 16:56, 18 April 2024

⚠ This is for beginners and very much by a beginner / hobbyist

It's intended to get an intuitive overview for hobbyist needs. It may get you started, but to be able to do anything remotely clever, follow a proper course or read a good book.


Some basics and reference: Volts, amps, energy, power · batteries · resistors · transistors · fuses · diodes · capacitors · inductors and transformers · ground

Slightly less basic: amplifier notes · varistors · changing voltage · baluns · frequency generation · Transmission lines · skin effect


And some more applied stuff:

IO: Input and output pins · wired local IO · wired local-ish IO · ·  Various wireless · 802.11 (WiFi) · cell phone

Sensors: General sensor notes, voltage and current sensing · Knobs and dials · Pressure sensing · Temperature sensing · humidity sensing · Light sensing · Movement sensing · Capacitive sensing · Touch screen notes

Actuators: General actuator notes, circuit protection · Motors and servos · Solenoids

Noise stuff: Stray signals and noise · sound-related noise names · electronic non-coupled noise names · electronic coupled noise · ground loop · strategies to avoid coupled noise · Sampling, reproduction, and transmission distortions

Audio notes: See avnotes


Platform specific

Arduino and AVR notes · (Ethernet)
Microcontroller and computer platforms ··· ESP series notes · STM32 series notes


Less sorted: Ground · device voltage and impedance (+ audio-specific) · electricity and humans · power supply considerations · Common terms, useful basics, soldering · landline phones · pulse modulation · signal reflection · Project boxes · resource metering · SDR · PLL · vacuum tubes · Multimeter notes Unsorted stuff

Some stuff I've messed with: Avrusb500v2 · GPS · Hilo GPRS · JY-MCU · DMX · Thermal printer ·

See also Category:Electronics.


Sensing

Galvanic skin response (GSR)
This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.

Galvanic skin response (GSR), Electrodermal activity (EDA), electrodermal response (EDR), psychogalvanic reflex (PGR), skin conductance response (SCR), sympathetic skin response (SSR), and skin conductance level (SCL).

(Because of the varied names accumulated over time, EDA is intended as a new standard name, but some fields haven't moved yet, so many existing documents will use old terms.)


All are fancy names for 'how much electricity does your skin conduct'.

Some check just that.

Some suggest indirect measurement of mental state.


Sweating is a response controlled by the sympathetic nervous system, to things like

basic physics - warming up due to exertion, or environmental temperature, that mean you have to thermoregulate
health - hydration level, fever, ingestion of irritants, contact with toxins, menopause, other hormonal changes, like change in medicine, hyperthyroidism, reaction to caffeine, morphine, alcohol and other drugs, insulin levels, differences in ability to thermoregulate due to health, differences in ability to thermoregulate due to humidity
mental origins - strong forms of anger, fear, anxiety, arousal


Mental state?

The idea is that

if you can control for most of that last list - physics of the moment, and health, and further calibration,
then sweating could indicate the last few on that list, making skin conductance one measure of emotional and sympathetic responses.

Criticism includes:

  • that's a lot of ifs
  • hydration level affects the response regardless
  • response varies by location, being driven by somewhat different responses
  • sweat response has delay, seconds to longer depending on the type of response. It becomes hard to tell what it's a reponse to.



It's impossible to avoid mentioning the polygraph-style lie detector, which measures not only GSR, but also heart rate, breathing rate, and blood pressure.

The idea idea is that these are all controlled by the sympathetic nervous system rather than consciously, so you can't voluntarily change them, which is the entire reason they're sold as lie detectors.

But there are reasons that they are no longer admissible in most courts, for many detailed reasons - that all amount to that they are unreliable at best.

Even its inventor has spoken out their frustration by the the ways is regularly misused.


Problems include that

  • it cannot distinguish between different forms of arousal - consider
    • anger (because of strong personal ethics)
    • worry - that this will be treated as proof, thinking of social implications
    • fear - including the one where it it just sunk in what the implications might be if this pseudoscience is taken seriously
    • startle response -
    • sexual arousal - maybe you just have a thing for authority figures
none of which have anything to do with lies, let alone guilt
  • it cannot distinguish between such responses being involuntary, and such responses being triggered intentionally
remember, the indicators are very basic and low resolution. All they really measure is 'body is a little different', not how or what
  • you can intentionally mess with the calibration, e.g. by thinking of some anguish at the right time
  • you can intentionally to suppress these responses by mentally distracting yourself
Also means ADHD people are just less guilty overall, huh?
more to the point, this can be trained
  • it does not consider that sociopaths won't have some of these responses to start with, by definition


See also:

electrocardiography (ECG)

Measuring the heart muscle (-cardio-), which at skin surface is seen on the scale of a millivolt or so.


A little harder to DIY, because that's weak there is also typically coupling of electrical fields (and easily AC line noise). For a start you want a differential amplifiers (probably an inamp), and probably some shielded or twisted wire to minimize induction, think about positioning (or you may get common mode voltage via impedance mismatch(verify)), maybe a passband filter.

And right-leg drive (probably here called something else) can't hurt.

See

Electromyography (EMG)

Measuring skeletal muscles (-myo-), which seems to be one the scale of dozens of millivolts (verify)}

See http://en.wikipedia.org/wiki/Electromyography

Neuroimaging

Electroencephalography (EEG)
This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.

Measuring activity in the brain (-encephalo-) - which (outside) is on the scale of dozen microvolts (to at most millivolts (verify))

At a low level, you measure a tiny fluctuating voltage change at a spot on the surface of the scalp, comparing that voltage to other such spots for reference, using metal electrodes and conductive paste for better contact.

Muscles nearer the surface are much stronger signal - a clenched jaw or blinking your eye is very visible in data (in very different ways - jaw is high frequency, blink low). In fact some of the electrodes are only there to measure those in isolation, so that we have a chance to remove them later


Comparing the voltage to other such voltages can (only) tell you things like

  • that an area broadly became more or less active
  • when you started reacting
  • differences between things like "makes sense" and "that's weird and I'm processing why".
  • broadly, which areas of the brain engaged more than others



Electrocorticography (ECoG)

Electrocorticography (ECoG), or intracranial electroencephalography (iEEG), is like EEG but sensing directly on the brain itself, rather than from outside the skull and skin.

Is surgically invasive, so generally only seen around things like epilepsy treatment.


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

Magnetic resonance imaging (MRI)
Magnetoencephalography (MEG)
Functional Near-Infrared Spectroscopy (fNIRS)

Functional near-infrared spectroscopy (sometimes Optical Topography (OT)) uses near-infrared spectroscopy to estimates the concentration of hemoglobin to estimate activity, so is useful for basic functional neuroimaging.

It is noninvasive and has high temporal resolution, but low spatial resolution and only works near the surface.

(it's not electronic and doesn't really belong on this page, but it mostly does belong in this list of measuring humans)


Electrooculography (EOG)

Electrooculography (EOG), a.k.a. retinal Electrooculography, basically helps record eye movements.

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


Electroglottography (EGG)

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.

Measures the how closed the vocal folds are, via the resistance of two electrodes around the neck.


Electronics side

Electropalatography (EPG)

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

Electromagnetic articulography (EMA)

a.k.a. Electromagnetic Midsagittal Articulography (EMMA)


Positioning the tongue, using sensor coils in EM field, receiving signals from multiple fixed transmitters (chunky thing above head).


Events

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.


Stimulating

Conductive

TENS, Transcutaneous Electrical Nerve Stimulation

Aims to desensitive nerves, so is used for short-term pain relief.

Higher frequency (and less strength?) than EMS, only enough to feel.

Electric massage is closer to TENS than EMS(verify)

See also:


EMS, Electrical Muscle Stimulation

Also known as NMES (neuromuscular electrical stimulation) and electromyostimulation.

Used to help muscle training, such as that to avoid atrophy.

It uses pulses that are strong and long enough to trigger muscle contraction, and helps engage more of an muscle that you consciously engage. It's not that effective without your help, though.


See also:


Massage

High frequency

Purple wand

Static electricity, ESD, and humans

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.


ESD and electronics

Avoiding ESD

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.


Lightning

Unsorted

On (not) causing tingling

Laptop tingle / zap

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.



Symptoms:

  • continuous tingling on exposed metal (sockets, screws, metal bodies, e.g. in your hands, on your lap)
  • felt only when the adapter is connected
  • Felt more clearly when
the contact area is small
you have good contact with the device (e.g. sweaty hands/legs)
you have good contact with the floor (e.g. no shoes or socks, moist concrete)
When measured, this is AC, and up to a few dozen volts, and usually not more than a milliAmp or two


Phone zap / tingle

Mostly similar to the laptop example above.

Many of these chargers are ungrounded wallwart-style, making this a likely thing.


One difference to the laptop case is that there are a lot more cheap-and-particularly-crappy phone chargers out there (than there are low-grade laptop adapters).

Some of them just low quality output, a few actually unsafe.

See e.g. [1] [2]


It the touchscreen doesn't work as well, or at all (interferes with the way capacitive touch works) whenever it's on a charge cable, it's probably just a low-quality charger and you can fix that by buying a better one. It can be hard to tell quality from looks. Reputable brands are a decent though not sure-fire way, and there are some decent cheaper-brand ones.


Less intentional / on not killing people

Electricity through humans

Human resistance ratings
Current through humans - where does the risk start?
More context
"It isn't the volts that kill you, it's the amps"
On current capacity

Electricity and heat

Resistive heat
On circuit breakers
On extension cords
Arcs and arc faults

Protections

Safety earth

Why?

Earth wiring within a house is there for safety.

Short version: it is a return connection that is much lower impedance than you are - and passes enough current enough that a fuse or circuit breaker would soon disconnect the live wire.


One of the main uses is earthing a conductor that should never be live - but might become so when things fail. For example, the chassis of a toaster or washing machine or such.

If they eventually break so that wiring comes loose and touches the outside, and you want to design for that possibility.


With safety earth on that chassis, that's a short across your house's breaker, which will probably trip, meaning the dangerous voltage on that chassis is on there for a fraction of a second.

(Also it's across two chunky wires that won't have any issue with that current for factors longer than that)

Even if you touch it within this time, the earth wire is much lower resistance to earth and (since this is a voltage divider) you shouldn't feel much.


Without safety earth, the live wire touching the chassis mean nothing other than that it is now at mains potential.

This has few immediate implications, but you will notice this when you next touch this and you are even vaguely earthed.

The current through you is also much lower than any real use, so there is no reason for a breaker to trip.


(Which is why RCDs exist, and complement breakers)



What?

Earth (or earth ground) refers to a physical pole hammered into the earth somewhere nearby.

Earth wiring is connected to that pole.

Typically this is also bonded to things like radiator pipes, water pipes, steel structures. So generally all these things are at most a few ohms to this earth.


Devices like think ovens, washing machine, etc. are typically designed with safety earth, and using them safely will require that connection to earth - which, due to electrical code, usually just means 'socket with earth pin'.

Some (big) devices will even test the grounding and refuse to work if not present. Yet most will assume that your electrical wiring is not violating electric code. Just at all, or because they have an earthed plug and it's technically a code violation to have an earthed socket that isn't actually earthed.


(Note that powering things on generators is a little more interesting, ground-wise)


Earth versus ground

Residual-current devices

This article/section is a stub — some half-sorted notes, not necessarily checked, not necessarily correct. Feel free to ignore, or tell me about it.

Known under varied terms, including:

  • Residual-current devices (RCD)
  • Ground fault circuit interrupter (GFCI)
  • Ground fault interrupter (GFI)
  • residual-current circuit breaker (RCCB)
(Note: an RCBO is a residual-current protection and an overcurrent protection in one)
  • Earth leakage circuit breaker (ELCB)
  • Appliance leakage current interrupter (ALCI)
  • Leakage Current Detection Interrupter (LCDI)
  • FI - Fehler and I indicating current (verify)
  • Differential circuit breaker


There are apparently a few different designs. The common variant measures the current difference between the current going through the live and neutral wire, because those two currents should be exactly the same. Conceptually / component-wise, you can think of it as a small sensing transformer coil around both live and neutral wire. When current in is equal to current out, that sensing transformer outputs nothing.)

And if there is a difference, we assume that the extra current path is via ground (either the socket's safety earth, or the literal ground), and for safety we assume this might be going through a human, so it trips to cut power.


Electrical code varies when it comes to RCDs. Building styles also vary, with country and with time.

Sometimes you'll see a chunky RCD on each leg/phase at the power board - only.
Others add them per socket, and then often only in the kitchen and shower.

Others protect other areas, double them up to project everything but trip smaller zones, and other variations.


Building sites may put a series of larger-and-smaller RCDs on different areas because it interrupts fewer people from working, and makes it easier to diagnose who's tripping it.


You can also get RCD extension cords, which can e.g. make sense when you do electronics repair work, possibly for rooms that are not protected (if that applies to your house).

While a lot of them are standard-valued, you can sometimes get ones that responds faster and for lower current, which can be marginally safer, and sometimes more importantly, means the one at your desk trips, not the house one, saving you and possible housemates a lot of annoyance and waling.

You'll probably accept just your DIY setup being overly triggery, (and/or better isolate the causes).


Certain situations (e.g. datacenters) may use higher values, because false trips are much more costly, there can be some protective equipment that would trip RCDs more easily(verify), and technicians can be instructed better than random people in random houses.


RCD aim to trip at the order of a dozen milli-amps for a dozen milliseconds or so, as a balance between 'most humans will survive that' and making it less sensitive to stray currents, and making nuisance trips unlikely.


The typical trip currents vary, e.g. For

home installations in 230V countries, typically ~30mA for ~20 milliseconds
home installations in 120V countries, often quoted as just "5mA".
I've not been able to find the time that belongs to. A graph from UL943 suggests it's allowed to be much longer

See also:

Arc fault protectors

An arc fault is an unintended discharge between conductors, from things like

loose wiring connections
overheating wiring that broke down insulation over time (note that breakers should make that impossible)
otherwise damages wire insulation

The sparks and heat generated can further damage the wire, and lead to fire.



An arc-fault circuit interrupter (AFCI) measures

fast switching (order of 100 kHz)
of non-negligible current
sustained for a few seconds.


They seem to often be digital(verify)

They seem to often also integrate ground fault sensing.

Design safety, and certification

Certifications
Double insulation

Galvanic isolation, floating outputs, floating ground

Isolation transformers

Is 120V safer than 230V?