EMF Detector
This DIY EMF detector works by utilizing the principle of electromagnetic induction. The exposed wire acts as an antenna, picking up electromagnetic signals present in the surrounding environment. These signals induce a small current in the wire, which is then measured by the Arduino through analog pin A5. The 1 ohm resistor helps to limit the current flow and protect the Arduino
Materials Required:
20 cm single-core wire
1 ohm resistor
1 Breadboard (optional)
Arduino board (e.g., Arduino Uno)
15 Jumper wires
10 LEDs (2 RED, 3 ORANGE, 3 YELLOW, 2 GREEN
10 Resistors 220 or 330 ohm
Here are some suggested uses for the EMF detector
Ghost Hunting and Paranormal Investigations:
Detect electromagnetic anomalies believed to be associated with ghostly activity.
Use during paranormal investigations to monitor fluctuations in EMF fields, potentially indicating the presence of spirits.
Environmental Monitoring:
Assess electromagnetic pollution in various environments, such as homes, workplaces, and outdoor spaces.
Identify sources of electromagnetic interference (EMI) that may affect electronic devices or human health.
Electromagnetic Field Research:
Conduct scientific experiments to study the behavior and characteristics of electromagnetic fields in different settings.
Explore how electromagnetic phenomena interact with surrounding objects and materials.
Wireless Technology Optimization:
Test and optimize the placement of wireless routers, antennas, and other devices to maximize signal strength and minimize interference.
Determine areas with weak wireless signals or potential sources of signal disruption.
Educational Projects:
Introduce students to concepts of electromagnetism and electronics through hands-on experimentation.
Teach about the principles of sensor technology, data acquisition, and signal processing.
Home and Office Safety:
Ensure safe distances from sources of high EMF, such as power lines, electrical appliances, and transformers.
Identify and mitigate potential EMF hazards that could impact human health or electronic equipment.
Electrical Appliance Testing:
Verify the proper functioning of electrical appliances and devices by checking for abnormal EMF emissions.
Troubleshoot equipment malfunctions related to electromagnetic interference or faulty wiring.
Radio Frequency Spectrum Analysis:
Explore the RF spectrum to analyze signal strength and frequency distribution in radio communication bands.
Investigate radio frequency interference (RFI) sources and optimize radio communication systems.
Outdoor Exploration and Adventures:
Use during outdoor adventures, such as camping or hiking, to observe natural variations in EMF fields.
Investigate electromagnetic phenomena in remote or wilderness areas for scientific or recreational purposes.
Art and Creative Projects:
Incorporate the EMF detector into art installations or interactive exhibits exploring themes of technology, environment, and perception.
Use EMF data as input for generating visual or auditory representations in multimedia artworks.
In the provided image, the LEDs are arranged sequentially, starting with the red LED connected to Pin 2 and ending with the LED at Pin 11. This sequential arrangement allows for easy visualization of the EMF data, with each LED representing a specific range of values.
To create the antenna for the EMF detector, begin with a 20 cm single-core wire. Strip off approximately 1 cm of insulation from one end, exposing the wire.
On the other end of the wire, strip off about 7 cm of insulation to expose the central portion. This exposed section acts as the central pickup for detecting EMF signals in the surrounding environment. By placing this portion strategically, you can capture electromagnetic fluctuations and variations, providing valuable data for the EMF detector's operation.
Connect this exposed end to the analog pin five (A5) on the Arduino board, which serves as the input for sensing electromagnetic field (EMF) data.
Additionally, a 1 ohm resistor is connected from the antenna wire to ground (GND), completing the circuit. The resistor helps limit the current flow and protects the Arduino board while ensuring accurate EMF measurements. Together, the antenna and resistor form a crucial part of the EMF detector, enabling the visualization of electromagnetic phenomena.
Arduino code below with detailed comments explaining each part to someone who's new to programming
/*Author: Douglas FesslerDate: 3/17/2024Description: This code serves as the firmware for an electromagnetic field (EMF) detector using an Arduino board. It reads analog data from a sensor, smooths it using a rolling average, and visualizes it using a 10-segment LED bar graph. The LEDs represent the intensity of the EMF field detected by the antenna sensor. The code includes setup for data smoothing, LED configuration, and serial communication for debugging purposes.*/
#define NUMREADINGS 25 // raise this number to increase data smoothing
int senseLimit = 1023; // raise this number to decrease sensitivity (up to 1023 max)int probePin = 5; // analog 5int val = 0; // reading from probePin
int LED1 = 11; // connectionsint LED2 = 10; // toint LED3 = 9; // LEDint LED4 = 8; // bargraphint LED5 = 7; // anodesint LED6 = 6; // withint LED7 = 5; // resistorsint LED8 = 4; // inint LED9 = 3; // seriesint LED10 = 2; //
// variables for smoothing
int readings[NUMREADINGS]; // the readings from the analog inputint index = 0; // the index of the current readingint total = 0; // the running totalint average = 0; // final average of the probe reading
void setup() {
pinMode(2, OUTPUT); // specify LED bargraph outputs pinMode(3, OUTPUT); pinMode(4, OUTPUT); pinMode(5, OUTPUT); pinMode(6, OUTPUT); pinMode(7, OUTPUT); pinMode(8, OUTPUT); pinMode(9, OUTPUT); pinMode(10, OUTPUT); pinMode(11, OUTPUT);
Serial.begin(9600); // initiate serial connection for debugging/etc
for (int i = 0; i < NUMREADINGS; i++) readings[i] = 0; // initialize all the readings to 0}
void loop() {
val = analogRead(probePin); // take a reading from the probe
if(val >= 1){ // if the reading isn't zero, proceed
val = constrain(val, 1, senseLimit); // turn any reading higher than the senseLimit value into the senseLimit value val = map(val, 1, senseLimit, 1, 1023); // remap the constrained value within a 1 to 1023 range
total -= readings[index]; // subtract the last reading readings[index] = val; // read from the sensor total += readings[index]; // add the reading to the total index = (index + 1); // advance to the next index
if (index >= NUMREADINGS) // if we're at the end of the array... index = 0; // ...wrap around to the beginning
average = total / NUMREADINGS; // calculate the average
if (average > 30){ // if the average is over 50 ... digitalWrite(LED1, HIGH); // light the first LED } else{ // and if it's not ... digitalWrite(LED1, LOW); // turn that LED off }
if (average > 125){ // and so on ... digitalWrite(LED2, HIGH); } else{ digitalWrite(LED2, LOW); }
if (average > 225){ digitalWrite(LED3, HIGH); } else{ digitalWrite(LED3, LOW); }
if (average > 325){ digitalWrite(LED4, HIGH); } else{ digitalWrite(LED4, LOW); } if (average > 425){ digitalWrite(LED5, HIGH); } else{ digitalWrite(LED5, LOW); }
if (average > 525){ digitalWrite(LED6, HIGH); } else{ digitalWrite(LED6, LOW); }
if (average > 625){ digitalWrite(LED7, HIGH); } else{ digitalWrite(LED7, LOW); } if (average > 725){ digitalWrite(LED8, HIGH); } else{ digitalWrite(LED8, LOW); }
if (average > 825){ digitalWrite(LED9, HIGH); } else{ digitalWrite(LED9, LOW); }
if (average > 925){ digitalWrite(LED10, HIGH); } else{ digitalWrite(LED10, LOW); } Serial.println(val); // use output to aid in calibrating }}
Now, let's go through each part:
Setup:
Defines constants and variables:
NUMREADINGS: Sets the number of readings used for data smoothing.
senseLimit: Specifies the maximum sensor reading value, adjusting sensitivity.
probePin: Assigns the analog pin for sensor input.
val: Initializes a variable for storing sensor readings.
LED1 to LED10: Assigns pins for the 10-segment LED bar graph.
Smoothing Setup:
Declares variables for data smoothing:
readings: An array to store recent sensor readings.
index: Tracks the current index in the readings array.
total: Keeps a running total of recent sensor readings.
average: Stores the smoothed average of sensor readings.
Setup Function (setup()):
Configures LED pins as output.
Initiates serial communication for debugging.
Initializes all elements of the readings array to zero.
Main Loop (loop()):
Reads the sensor value from probePin.
If the sensor reading is above a threshold:
Constrain the reading within the specified range.
Map the reading to a new range for consistent comparison.
Update the rolling average by adding the new reading and removing the oldest.
Calculate the new smoothed average.
Illuminate LEDs based on the smoothed average, with each LED representing a range of values.
Output the raw sensor reading to the serial monitor for calibration and debugging.
LED Display:
The code iterates through the LEDs, turning them on or off based on the smoothed average. Each LED represents a specific range of average sensor readings.
In summary, this code reads sensor data, smooths it using a rolling average, and visually represents it using a 10-segment LED bar graph. The LEDs illuminate based on the intensity of the EMF field detected by the antenna sensor, allowing users to observe fluctuations and patterns in electromagnetic activity in their environment.
Donate
If you've enjoyed exploring my Arduino projects and want to see more amazing creations, your support can make a big difference! By contributing, you're helping me continue to innovate and bring even more exciting projects to life. Together, we can explore the endless possibilities of DIY electronics! Don't forget to like, subscribe, and follow for updates on the latest developments. Thank you for being a part of this journey!
Click here to make a difference with your donation today!