Silicon ChipGalvanic Skin Response - March 2020 SILICON CHIP
  1. Outer Front Cover
  2. Contents
  3. Subscriptions: PE Subscription
  4. Publisher's Letter
  5. Feature: The Fox Report
  6. Feature: Techno Talk by Mark Nelson
  7. Feature: Net Work by Alan Winstanley
  8. Project: Diode Curve Plotter by Tim Blythman
  9. Project: Audio DSP by Design by Phil Prosser, Words Nicholas Vinen
  10. Project: Steam Train Whistle ... or Diesel Horn by JOHN CLARKE
  11. Project: Galvanic Skin Response by Jim Rowe
  12. Feature: PIC n’ Mix by Mike Hibbett
  13. Feature: Circuit Surgery by Ian Bell
  14. Feature: AUDIO OUT
  15. Feature: Make it with Micromite by Phil Boyce
  16. Feature: Visual programming with XOD by Julian Edgar
  17. Feature: Max’s Cool Beans by Max the Magnificent
  18. Feature: Electronic Building Blocks by Julian Edgar
  19. PCB Order Form
  20. Advertising Index

This is only a preview of the March 2020 issue of Practical Electronics.

You can view 0 of the 80 pages in the full issue.

Articles in this series:
  • Techno Talk (February 2020)
  • Techno Talk (February 2020)
  • Techno Talk (March 2020)
  • Techno Talk (March 2020)
  • (April 2020)
  • (April 2020)
  • Techno Talk (May 2020)
  • Techno Talk (May 2020)
  • Techno Talk (June 2020)
  • Techno Talk (June 2020)
  • Techno Talk (July 2020)
  • Techno Talk (July 2020)
  • Techno Talk (August 2020)
  • Techno Talk (August 2020)
  • Techno Talk (September 2020)
  • Techno Talk (September 2020)
  • Techno Talk (October 2020)
  • Techno Talk (October 2020)
  • (November 2020)
  • (November 2020)
  • Techno Talk (December 2020)
  • Techno Talk (December 2020)
  • Techno Talk (January 2021)
  • Techno Talk (January 2021)
  • Techno Talk (February 2021)
  • Techno Talk (February 2021)
  • Techno Talk (March 2021)
  • Techno Talk (March 2021)
  • Techno Talk (April 2021)
  • Techno Talk (April 2021)
  • Techno Talk (May 2021)
  • Techno Talk (May 2021)
  • Techno Talk (June 2021)
  • Techno Talk (June 2021)
  • Techno Talk (July 2021)
  • Techno Talk (July 2021)
  • Techno Talk (August 2021)
  • Techno Talk (August 2021)
  • Techno Talk (September 2021)
  • Techno Talk (September 2021)
  • Techno Talk (October 2021)
  • Techno Talk (October 2021)
  • Techno Talk (November 2021)
  • Techno Talk (November 2021)
  • Techno Talk (December 2021)
  • Techno Talk (December 2021)
  • Communing with nature (January 2022)
  • Communing with nature (January 2022)
  • Should we be worried? (February 2022)
  • Should we be worried? (February 2022)
  • How resilient is your lifeline? (March 2022)
  • How resilient is your lifeline? (March 2022)
  • Go eco, get ethical! (April 2022)
  • Go eco, get ethical! (April 2022)
  • From nano to bio (May 2022)
  • From nano to bio (May 2022)
  • Positivity follows the gloom (June 2022)
  • Positivity follows the gloom (June 2022)
  • Mixed menu (July 2022)
  • Mixed menu (July 2022)
  • Time for a total rethink? (August 2022)
  • Time for a total rethink? (August 2022)
  • What’s in a name? (September 2022)
  • What’s in a name? (September 2022)
  • Forget leaves on the line! (October 2022)
  • Forget leaves on the line! (October 2022)
  • Giant Boost for Batteries (December 2022)
  • Giant Boost for Batteries (December 2022)
  • Raudive Voices Revisited (January 2023)
  • Raudive Voices Revisited (January 2023)
  • A thousand words (February 2023)
  • A thousand words (February 2023)
  • It’s handover time (March 2023)
  • It’s handover time (March 2023)
  • AI, Robots, Horticulture and Agriculture (April 2023)
  • AI, Robots, Horticulture and Agriculture (April 2023)
  • Prophecy can be perplexing (May 2023)
  • Prophecy can be perplexing (May 2023)
  • Technology comes in different shapes and sizes (June 2023)
  • Technology comes in different shapes and sizes (June 2023)
  • AI and robots – what could possibly go wrong? (July 2023)
  • AI and robots – what could possibly go wrong? (July 2023)
  • How long until we’re all out of work? (August 2023)
  • How long until we’re all out of work? (August 2023)
  • We both have truths, are mine the same as yours? (September 2023)
  • We both have truths, are mine the same as yours? (September 2023)
  • Holy Spheres, Batman! (October 2023)
  • Holy Spheres, Batman! (October 2023)
  • Where’s my pneumatic car? (November 2023)
  • Where’s my pneumatic car? (November 2023)
  • Good grief! (December 2023)
  • Good grief! (December 2023)
  • Cheeky chiplets (January 2024)
  • Cheeky chiplets (January 2024)
  • Cheeky chiplets (February 2024)
  • Cheeky chiplets (February 2024)
  • The Wibbly-Wobbly World of Quantum (March 2024)
  • The Wibbly-Wobbly World of Quantum (March 2024)
  • Techno Talk - Wait! What? Really? (April 2024)
  • Techno Talk - Wait! What? Really? (April 2024)
  • Techno Talk - One step closer to a dystopian abyss? (May 2024)
  • Techno Talk - One step closer to a dystopian abyss? (May 2024)
  • Techno Talk - Program that! (June 2024)
  • Techno Talk - Program that! (June 2024)
  • Techno Talk (July 2024)
  • Techno Talk (July 2024)
  • Techno Talk - That makes so much sense! (August 2024)
  • Techno Talk - That makes so much sense! (August 2024)
  • Techno Talk - I don’t want to be a Norbert... (September 2024)
  • Techno Talk - I don’t want to be a Norbert... (September 2024)
  • Techno Talk - Sticking the landing (October 2024)
  • Techno Talk - Sticking the landing (October 2024)
  • Techno Talk (November 2024)
  • Techno Talk (November 2024)
  • Techno Talk (December 2024)
  • Techno Talk (December 2024)
  • Techno Talk (January 2025)
  • Techno Talk (January 2025)
  • Techno Talk (February 2025)
  • Techno Talk (February 2025)
  • Techno Talk (March 2025)
  • Techno Talk (March 2025)
  • Techno Talk (April 2025)
  • Techno Talk (April 2025)
  • Techno Talk (May 2025)
  • Techno Talk (May 2025)
  • Techno Talk (June 2025)
  • Techno Talk (June 2025)
  • Techno Talk (July 2025)
  • Techno Talk (July 2025)
Using Cheap Asian Electronic Modules Part 22: by Jim Rowe Galvanic Skin Response This Seeed/Grove-designed galvanic skin response sensor measures changes in the resistance of human skin, which indicate changes in mood, apprehension or other psychological phenomena. It’s smaller than a stamp and comes with a pair of sensing electrodes. It also has an analogue voltage output, making it easy to use with any micro or a digital multimeter. T hese days, the phrase ‘galvanic skin response’ (GSR) is regarded as obsolete; instead, it is known as ‘electrodermal activity’. or EDA. Nonetheless, GSR is still pretty widely used. GSR is often regarded as the primary body parameter measured in ‘lie detectors’, or ‘polygraphs’ as they’re known in the US. However, GSR is only one of the many physiological indicators monitored in polygraphs; others are blood pressure, pulse rate and respiration. We should point out that despite the widespread use of polygraphs throughout the US and other countries, there is a great deal of doubt in scientific circles about their accuracy and reliability. They supposedly can indicate when a person gives false answers to questions. However, polygraph evidence is mostly inadmissible in UK courts and most other countries. The first suggestion that human sweat glands were involved in creating changes in the electrical conductivity of the skin was made in Switzerland in 1878, by researchers Hermann and Luchsinger. Then in 1888, the French neurologist Fere demonstrated that skin conductivity could be changed by emotional stimulation and also that this could be inhibited by drugs. Pioneering psychoanalyst Carl Jung, in his book Studies in Word Analysis (1906), described experiments using a 36 GSR meter to evaluate the emotional sensitivities of patients to lists of words during word association sessions. Although the first polygraph was invented in 1921 by John Augustus Larson at the University of California, it only monitored blood pressure and respiration. Larson’s protege Leonarde Keeler updated the device in 1939 by making it portable and adding the monitoring of GSR. His device was purchased by the FBI and then became the prototype of the modern polygraph. So what is GSR/EDA? The electrical conductivity of our skin is not under conscious control, but modulated by our sympathetic autonomous (subconscious) nervous system. Therefore, it responds to our cognitive and emotional states. The GSR module (24 x 20mm) includes a 150mm 4-pin JST cable and two electrode sleeves which connect via a 2-pin JST cable. The contact material on the sleeves is nickel. Practical Electronics | March | 2020 Seeed/Grove GSR Sensor Fig.1: complete circuit diagram for the Seeed/Grove GSR sensor module. Non-inverting input pin 5 of IC1 varies from 0-2.5V (5V DC supply) depending on the conductivity of your skin. VR1 adjusts the voltage at pin 3 of IC1a. The difference between these appears at the pin 8 output of IC1c and goes through a low-pass filter, and then onto pin 1 of J3. Initially, it was thought that modulation of sweat gland activity by the sympathetic nervous system was solely responsible for the changes in GSR/EDA, and this is still regarded as the main factor. However, it’s now believed that there are also accompanying changes in blood flow and muscular activity which affect conductivity. GSR/EDA sensors are usually fitted to the fingers because our hands and feet have the highest density of sweat glands on our bodies (200-600 sweat glands per cm2). In fact, the palms of our hands and the inside of our fingers are ideal locations for sensing GSR/ EDA, and you don’t have to take off your shoes and socks! The Seeed/Grove GSR module The Seeed/Grove-designed GSR sensing module is tiny, measuring only 24 × 20 × 9mm, including the two JST 2.0 PH-series SIL headers. The unusual shape of the PCB, with semicircular cut-outs at two ends which host the 2mm mounting holes, is because the module was designed as part of Seeed Studio’s ‘Grove’ module system, a standardised prototyping system. There are many modules available in the Grove system, including sensors for light, IR, temperature, gas, dust, acceleration and the Earth’s magnetic field – to name just a few. All of these modules have a standardised connector system, and Seeed has also produced shields and similar ‘piggyback’ boards to make it easy to connect multiple Grove modules to micros like the Arduino, the Raspberry Pi and the Beaglebone series. Since the modules come with a cable fitted with a 4-pin JST 2.0 connector at each end, it’s quite easy to connect a single module like this to a board such as a Micromite, or even to a digital multimeter (DMM). This module isn’t quite as affordable as some of the other modules we’ve looked at in these articles, perhaps because it comes with a pair of ‘finger sock’ electrode sleeves, together with suitable cables to connect to the module. It also comes with the aforementioned 150mm-long cable for connection to the micro. Fig.2: the GSR sensor can be easily tested by powering it via a USB supply (eg, a computer) for the required 5V DC and connecting the analogue voltage output to a DMM. Practical Electronics | March | 2020 The cost for the module plus these extra parts is around US$16, and is available from the usual web outlets (GearBest, Amazon and eBay). There’s also a very similar module made by SichiRay, available from AliExpress. Inside the module There’s not a great deal to the Seeed/ Grove GSR sensor module, as you can see from Fig.1. It uses an SMD version of the LM324 quad op amp (IC1), with three of its amplifiers connected in the standard instrumentation amplifier configuration. IC1c is used as a standard differential amplifier with a gain of 2.0, while IC1b and IC1a are unity-gain buffers driving its two inputs. But instead of having a gainsetting resistor connected between the inverting inputs (−) of IC1b and IC1a, as is typically the case with a purpose-designed instrumentation amplifier, the input buffers are left with unity gain. To the left of IC1b and IC1a is the simple circuitry used to sense the skin conductivity between the two sensing electrodes, which are connected to J1. At the top is a resistive voltage divider which derives a reference voltage of Vcc ÷ 2, or 2.5V when the module is powered from a 5V supply. This reference voltage is used to bias non-inverting (+) inputs of both IC1b and IC1a via 200kW series resistors. Since pin 1 of J1 is connected to the + input of IC1b (pin 5), the voltage at this pin will vary according to the skin conductivity between the two electrodes. On the other hand, the + input of IC1a (pin 3) is simply connected via small trimpot VR1 to ground, and the pin 2 input of J1 also connects to ground. 37 Fig.3: wiring diagram for the GSR module to an Arduino module. Output pin SIG must be connected to an analogue input pin. So the voltage applied to pin 5 of IC1b will vary between near-zero and almost +2.5V, depending on the skin conductivity of the connected person. The voltage at pin 3 of IC1a can be varied over the same range using VR1. This allows VR1 to set the full-scale output voltage of the module when the electrodes are open-circuit. Note that when the electrodes are worn, the maximum current that could flow between them is 12.5µA (2.5V ÷ 200kΩ). This is too low to be consciously sensed, and certainly not enough to give an electric shock. So the variations in skin conductivity between the two sensing electrodes connected to J1 cause changes in the voltage difference between pins 5 and 3 of IC1. The output voltage from pin 8 of IC1c is this difference. A simple 2Hz low-pass filter comprising a 1MΩ series resistor and a 100nF capacitor is connected between pin 8 of IC1c and pin 1 of J3, which is the power supply/ output connector. Pin 2 of J3 is connected to TP4 and pin 5 of IC1b, which allows you to monitor the voltage across the GSR electrodes with a DMM if necessary. Trying it out Probably the simplest way of trying out this module is to provide it with a source of 5V DC and use a DMM to monitor its analogue output voltage, as shown in Fig.2. The 5V power supply for the module can come from virtually any USB supply, since it only draws about 1.2mA. Fig.3 shows how the Seeed/Grove GSR module can be connected to an Arduino Uno or an equivalent microcontroller board, while Fig.4 shows how it’s connected to a Micromite LCD BackPack (see the article in the May 2017 issue of PE). In both cases, the VCC and GND pins of the module’s output connector (J3) are connected to +5V and GND respectively, while the SIG output pin 38 Fig.4: wiring diagram for the GSR module to a Micromite BackPack. ► is connected to the A0 pin of the Arduino, or to pin 24 of the Micromite. I found a very simple sketch for the Arduino in one of Seeedstudio’s wikis (http://wiki.seeedstudio.com/ Grove-GSR_Sensor/). It merely makes a series of 10 measurements of the module’s output voltage, adds them together and then divides by 10 to get their average. This is then sent back to your PC, to be either printed out in Serial Monitor or plotted using Serial Plotter. Then it loops back and repeats this sequence over and over again. You can see a sample output plot from this sketch in Fig.6. It’s called GSR_Testing_sketch.ino and we’ve made it available as a download from the March 2020 page of the PE website. Note that when you first power up the Arduino with the module connected, it’s a good idea to set trimpot VR1 to give a readout of around 512 before the electrodes are fitted to anyone’s fingers. This only needs to be done once, not every time you apply the power. For those who want to use the GSR module with a Micromite, I have written a small program in MMBasic. This is identical to the Arduino program, taking a series of 10 measurements and calculating their average. The measurements are then sent back to the PC for display in the MMChat window. It’s also shown on the Micromite’s LCD screen as a single figure, which changes with each new set of measurements. Fig.5 shows a screen grab of this program in operation. It’s called GSR module checkout.bas and is also available as a download from the March 2020 page of the PE website. This should provide you with a starting place for writing a more elaborate program of your own, perhaps one that displays the growing GSR plot on your PC’s screen, like a polygraph display. Once again, it’s a good idea to adjust VR1 for a reading of around 512 before the electrodes are fitted. Breadboarding it Given how simple the circuit shown in Fig.1 is, you may be wondering whether it’s possible to breadboard it. We reckon it wouldn’t be too hard. The only thing you need to be careful of is to avoid any possible leakage currents on the tracks and components connected to the non-inverting inputs of IC1a and IC1b (pins 3 and 5), as this could disturb the readings, especially if the leakage currents were to vary with temperature, humidity etc. Practical Electronics | March | 2020 Fig.5: the sample program running on a Micromite. Connect two fingers to the sensors to display the current skin resistance. Anything ±5% from those initial values indicates a change in mood. A higher reading typically indicates a more relaxed mood, while a lower reading is a tenser mood (greater perspiration, thus decreasing skin resistance). www.poscope.com/epe This generally means keeping the breadboard and components plugged into it clean and dry and avoid touching it during operation. You could probably even build a little GSR module yourself on a bit of veroboard, using a DIP LM324 IC and a handful of passives, in a similar arrangement to that shown in Fig.1. Useful links http://bit.ly/pe-mar20-eda http://bit.ly/pe-mar20-poly http://bit.ly/pe-mar20-grove The Seeed/Grove galvanic skin response module, shown above at twice actual size, is based on an LM324 quad op amp and costs around US$16.00. Reproduced by arrangement with SILICON CHIP magazine 2020. www.siliconchip.com.au - USB - Ethernet - Web server - Modbus - CNC (Mach3/4) - IO - PWM - Encoders - LCD - Analog inputs - Compact PLC - up to 256 - up to 32 microsteps microsteps - 50 V / 6 A - 30 V / 2.5 A - USB configuration - Isolated PoScope Mega1+ PoScope Mega50 Output plot of the values from the GSR module using the Arduino Serial plotter. The values swing from a high of 280 to a low of 264, even though the reference value is 512, due to the way the module is designed. Practical Electronics | March | 2020 - up to 50MS/s - resolution up to 12bit - Lowest power consumption - Smallest and lightest - 7 in 1: Oscilloscope, FFT, X/Y, Recorder, Logic Analyzer, Protocol decoder, Signal generator 39