I’ve invited some fellow writers for dinner and this book went missing.
Paraphrasing John Goodman in The Big Lebowski: “This is what happens, Larry.”
Instead of sending who-stole-the autobiography-of-Klaus-Kinski email. I’ve decided to make a Nano Lie Detector (AKA Polygraph) for next dinner.Parts
- Arduino Nano
- Analog VU-meter x2
- Heart Rate sensor
- Jumper cables
- Aluminum foil
- 5V power source
A polygraph is a device that measures physiological indicators while a person answers a series of questions. Deceptive answers will produce certain physiological responses that can be differentiated, for example: increased heart rate and changes in sweat gland activity (galvanic response).
There is a cheap sensor to measure heart rate and with some easy to find parts, a galvanic response sensor can be made. Arduino will read both sensors and display the information using a vintage analog VU-meter.Obstacles
I’ve found 2 small issues during this project. One related to the VU-meter and the other one related to GSR. To move analog VU-meter needle you have to send voltage through a digital output pin using PWM and I’ve forgot that not all digital pins are capable of producing PWM. For Arduino Nano: pins 3, 5 and 6 can be used but not 4.
The other issue was related to galvanic response sensor. I’ve tested several ideas found on the web - no circuit at all, amplifications, filters, etc – but readings were not reliable until I’ve connected one jumper to a 300k ohm resistor and Ground besides A1 input.Code
Code just reads heart rate sensor and sends coordinated tics to left needle, then reads analog input 1 (higher values means more finger sweat and a possible lie) to move right needle. Finally a comparison triggers the buzzer. There is a small setting named Threshold for the Heart Rate that has to be manually configured. It is the limit to start considering new heart beats. A potentiometer could be added to manually adjust this setting (instead of hard-coding)Custom case
Two 3D-printed rectangles, 4 screws and one handle from a drawer. Cardboard will work as well.DemoWhere to go from here
A button to differentiate answers, local storage and reports could be good improvements.
More Arduino projects here