Adruino Based Electrostatic Field Mill

32K2116

Intro: Adruino Based Electrostatic Field Mill

How to build your own adruino based electrostatic field mill. I'm going to show you how to build this amazing device that allows you to monitor the amount of electrostatic potential exists around you. Youll be able to watch the electrostatic fields that follow under clouds, occur when you move and walk or even wave your arms! We're going to build this from parts that almost any body has around the house.

Here's a video demo of it in action!

STEP 1: Parts Required

To build your field mill you'll need the following: An adruino (any model should work) An old processor or case fan from an old computer (it needs to run and be the kind with 3 wires) A couple of the clear CDs that come on the tops and bottoms of cr-r spindle packages One cd any kind A cd-r spindle package Aluminum foil A glue gun Spray adhesive A dead hard drive Some wire

STEP 2: Building the Shutters

A field mill works exposing a plate to the electrostatic field and then measuring it. This is done by a machanical shutter that rotates in front of the measuring electrode. For our shutters we're going to use a couple of clear cd spacers and aluminum foil. First we cover one side of a clear cd spacer with foil. We repeat the process with a second clear spacer. Next we use a ruler to divide each cd's foil into quarters, We then remove the foil on each diagonal quarter. Repeat this process with the second disk

STEP 3: Installing the Top Shutter

To create the shutter system we first mount one shutter to the inside top of the cd package case. The second shutter will rotate below the top shutter thus creating a metal shieldl that will alternately open and close as the second disk rotates below it. Glue the Top disk to the inside top of the CD-r stack case.

STEP 4: Building the Shutter Rotor.

Below the top shutter the second shutter rotates to open and close repeatedly to allow and then block the electrostatic field from the sensor plate. this is done with a small electric motor. A brushless motor if desired because they dont use brushed to connect the rotating shaft to the rest of the system and instead use a rotating magnetic field to cause the shaft to spin. We also need a way to let the electronics of the field mill know when the rotating shutter is in the open and closed state. Normally this is done with some kind of optoelectronic sensor that requires some pretty tricky wiring and setting up to build!
However there's a cheaper and simpler way to do this and if you're into gadgets and computers you probably already have this laying around. A computer case or processor fan. These are brushless motors with a handy timing signal line already built into them! Plus they're cheap!

STEP 5: Rotor Parts From the Dead Hard Drive

Now we need to get our rotating shutter onto the fan with enough clearence to be able to spin. We also need some way to ground the metal portion of out shutter blades to ground so they'll block the field when needed. This is where the Dead hard drive comes in! there's loads of good spacers and metal disks inside a hard drive. SO grab your old dead hard drive and rip that sucker apart and pull out all the disks, rings, magnets and other goodness! (I'll let you figure out how to open the hard drive because there are too many different types to describe here. I'lll offer this hint. Take out all the screws!

STEP 6: Building the Rotor Disk

Now we need to build our rotating shutter. This part spins while grounded and blocks the outside field while the charge is measured from the collecting plate.  The first thing we need to do is make sure both the metal shutters on the second cd are electricly connected to each other and a way to drain any charge from them. for this we're going to use the metal rings and disks from the old hard drive. Place the metal ring from the drive in the center of the rotor disk. Taking care to make sure it's centered as good as possible. Also make sure it makes good contact with the aluminum foil shutters. Press the ring down and hot glue it in dots all around the inside of the ring. DONT put any hot glue under the ring. We need it to touch metal to metal with the foil!

STEP 7: Add the Rotor to the Fan

Next we need to glue the rotor to the fan. You glue the rotor to the fan RING SIDE down. so the ring is the only part that connects to the fan hub. I placed a circle of hot glue around the edge of the fan hub and carefully centered the ring and held it until it cooled.
I also removed the fins from the fan but in retrospect decided this was unnecessary  when you're done the disk should be held above the fan hub but the ring. This ring will become our ground/brush system to keep the rotating shutters grounded..

STEP 8: Connecting the Ground Brush

Now we need to attach a wire that will ride along the side of the metal ring to bleed off any charge the rotating shutter develops.
I took a piece of bare copper wire and held one side down with a small screw on the side of the plastic fan case and positioned it to press against the rotating ring. It takes a bit of adjusting to get the wire to press against the ring with enough pressure to hold it there. The other end of this wire runs out to ground.

STEP 9: Installing the Rotor

Now we need to get the rotor inside the case. Turn the case over so the first stationary shutter that we glued to the inside is at the bottom and the open end of the case is upward. Take the Rotor assembly and insert it (rotor side down) into the case until it starts to get snug. (My fan's frame was larger than the cd circumference so it allowed me to use it as the holding frame, If your fan is smaller you will have to use wooden dowels or some Teflon screws to hold it in place)

Once you have the rotor in place. spin the cd with your finger to make sure it can spin freely inside the case.
Here you can see it running inside the case

STEP 10: Building the Collection Plate

The next part of our field mill is the collection plate. This part is easy! It's just a cd (covered with foil with a little foil tab to connect a wire to. This is what actually senses the field.
Get a cd and cover it with foil. Make sure to leave a tab hanging off to connect the sensing wire to.

Next we're going to use the spindle that used to hold the cd's when they were in the package. However we need to shorten it so when the cover that is now our shutter system is placed over it. The sensor place is held below the rotor by about 1 inch or so.
Measure and cut the center spindle and then glue the sensor place to the top of it. Metal side up.

STEP 11: Install the Sensor Plate.

Now we lower the top of our field mill onto our sensor plate. we need to make a hole in the cover just above the base so the wires can extrude from the device.

STEP 12: Isolate the Case

Now we need to isolate the entire case from the electrical environment. We do this by wrapping it in foil except for the top where we want the static field to enter. This shield also needs to go to ground

STEP 13: Hooking It to the Arduino and Software

Once we have the sensor set up we need to hook it to our Arduino.

for my version I'm feeding the fan with 5 volts which seems to run it fast enough for this application.
From the fan:
Red-5v 
Black-Gnd
Yellow (rotoation pulse) - pin 21 (arduino mega)
                                       or   pin 2 (arduino uno)
Rotor Ground                     Arduino ground
From the collection plate to Analog input A0
Case Ground                      Arduino Ground

STEP 14: Arduino Software

Now we need some software so our Arduino knows what to do with the monster we just attached to it!
 Here is the sketch I wrote that reads the rotation of the rotor and collects a reading from A0 on each rotation.
You may Need to adjust this for your Arduino
it will output measurements to the serial output for display as raw data or to be processed with a graphing program.
Ive also included a simple graphing display app written in "Processing" on a PC

------------------------Arduino mega sketch----------------------
int pin = 7;
volatile int state = LOW;
int tt=0;
void setup()
{
  Serial.begin(9600);
  pinMode(pin, OUTPUT);
  attachInterrupt(2, blink, CHANGE);
}

void loop()
{
  Serial.println(tt);
   digitalWrite(pin, state);

}

void blink()
{
 tt=(analogRead(A0)-200);

  state = !state;
}


---------------------------Processing Sketch----------------
import processing.serial.*;

  Serial myPort;        // The serial port
  int xPos = 1;         // horizontal position of the graph

  void setup () {
  // set the window size:
  size(1024, 480);       

  // List all the available serial ports
  println(Serial.list());
  // I know that the first port in the serial list on my mac
  // is always my  Arduino, so I open Serial.list()[0].
  // Open whatever port is the one you're using.
  myPort = new Serial(this, Serial.list()[1], 9600);
  // don't generate a serialEvent() unless you get a newline character:
  myPort.bufferUntil('\n');
  // set inital background:
  background(0);
  }
  void draw () {
  // everything happens in the serialEvent()
  }

  void serialEvent (Serial myPort) {
  // get the ASCII string:
  String inString = myPort.readStringUntil('\n');

  if (inString != null) {
  // trim off any whitespace:
  inString = trim(inString);
  // convert to an int and map to the screen height:
  float inByte = float(inString);
 inByte = map(inByte, 0, 1000, 0, height);

  // draw the line:
  stroke(255,255,255);
  line(xPos, height, xPos, height - inByte-20);
  textSize(32);
text(inByte, 10, 30);





  // at the edge of the screen, go back to the beginning:
  if (xPos >= width) {
  xPos = 0;
  background(0);
 }
 else {
  // increment the horizontal position:
  xPos++;
  }
  }
  }


13 Comments

Does this show both positive and negative charges as just a charge or does it show it is + or - charge? (seems like if it does, that it would be a very good way to measure triboelectric effect of materials giving info to build a better series based on stuff one has, as well as modifications to materials that effect its charge potential like my idea of rubbing graphite on teflon to make graphene like layers that have a positive charge on one side and possibly negative on the back to mirror the charge of the teflon, or even better still rubbing down something that is turned into an electret using high voltage and heat to orient the charge of the molecules in it like plastics or glass, then cool and use the remaining charge to organize that carbon layer how you want :)

Where is the programme written for graphing this thing. I checked the code but it talks about all these variables that need to be input into some programme.

I made a comment to answer that if it can help
To all of you who struggle with the code, wich obviously has a problem because nothing is plugged in the pin 7, know that you can completely ignore the part about detecting the motor phase with the yellow pin.
Your measures will be less precise but it will work very well.
Here is the only code necessary to read the tension :

______________________________________________________________________
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorValue= analogRead(A0);
float voltage= sensorValue * (5.0 / 1023.0); // those two lines are used to convert analog into
//digital, link is at the end ;)
Serial.println(voltage);
}
_______________________________________________________________________
It should also work this way :
________________________________________________________________________
void setup() {
Serial.begin(9600);
}
void loop() {

int voltage=analogRead(A0) //less code but the value may not match what you read on the
//sensor
Serial.printin(voltage)
}
____________________________________________________________________________

the processing sketch is not necessary ! you can display graphs directly
in the arduino IDE programming window , go

tools ---> Serial Plotter

and here you go! ;)
__________________________________________________________________________________
+ If you want to store your data, I recommend the microsoft excel plug in "PLX DAQ v2.11"
the latest version the better it will work !
just open the sketch you download in arduino software, scroll down to this line :

Serial.println("LABEL,Date,Time,Timer,Counter,millis,analog voltage");

add the text in italic.
Then go to this one:

Serial.println( (String) "DATA,DATE,TIME,TIMER," + i++ + "," + millis()+"," +Serial.print(voltage)+",AUTOSCROLL_20" );

same here.

Then open the xms file in excel, activate the macro, a window open. Connect to the COM you use for the arduino and it will run automatically :)
Excel might crash if your computer is not strong enough but nothing too important.

Hope this was useful !
nice project really!

Why

int pin = 7;

and noting is connected to pin 7 ??

Is there an error in the arduino code?

Because it seems unusual to me

The processing sketch does not show any graph on the screen, is there a specific version of processing I should consider using?

Good question! What it does is measure that static electric field. For example. If you have this set in your living room and you walked across the carpet. You'd see the graph vary as you built up a static charge. Then if you touched a doorknob you'd see it drop as the spark kept from your finger to the doorknob. Or, if you didn't touch anything you'd see the graph slowly lower as the electrical potential in your body bled away. Placed outdoors on a pole above the ground and with the open end pointed towards the ground. You'd be able to see the electrical fields generated by cumulus clouds as the drift by. Some clouds have an electrical shadow that follows them. Larger storms do the same thing. When the electrical potential gets large enough. Lightning! Field mills are used as NASA around launch sites to monitor the potential for lightning strikes. I hope this helps explain what it does.
thanks for the explanation
cool but what is it? what is a Electrostatic field mill?
That's supposed to say... Thanks so much!! Goofy spell correct grabbed it! :)
That's so much! I've wanted to build a field mill for a while but all the plans I found were really complex from an electronic point if view. I was sitting messing with a PC case fan whennit hit me that here was a quiet brushless motor with a rotation pulse built in! Once I hooked it up to the adruino to see how the rotation counter worked I thought, " you know the adruino could do everything all the multiplexing and electrolooptical analog plans I'd been seeing for other field mill plans were doing, but in a much simpler and easy to build way! The idea for the CDs came along when I was trying to design a shutter system. After that the project took off!
Thanks for the comments!
Such a great project! The waveforms look amazing and quite accurate!