Earth's Field Magnetometer

This project is the design, build, test, and calibration of an Earth's Field Magnetometer suitable for use as an aid in predicting possible 50 MHz aurora propagation.  The sensor is an FGM-3 detector available from Fat Quarters Software.   It is powered by 5 volts DC.

Because the FGM-3 sensor is sensitive to temperature changes and stray magnetic fields, it will be located in my back yard mounted below ground were the temperature is stable.  The temperature will be monitored by a digital temperature sensor attached to one end of the FGM-3 with super glue.  The sensor is a Dallas Semiconductors DS1624 which transfers data on a two wire buss.  The buss is physically too long for the DS1624 to communicate with the microprocessor located in the house, so a special I2C buss driver is used on each end of the buss.  This part is a Phillips type P82B715.  

The sensor feeds a counter module located in the house.  This counter consists of a 24 bit serial binary counter with parallel outputs, a 24 bit shift register with parallel inputs, a time base with a frequency divider, and a selector chip.  A microprocessor system is used as an interface between my PC and the counter and two wire temperature buss.  The microprocessor system I chose is the NetMedia BX-24.  This system is programmed in a language similar to Visual Basic.  I thought that by learning Visual Basic for the PC programming and BasicX for the BX-24 the confusion factor would be reduced.   The input to the PC is via a serial port.

The first step of the construction phase was to bury a 4-inch diameter PVC sewer pipe in the back yard.  This site was selected to minimize stray magnetic fields, yet not interfere with future use of the back yard.  The site chosen was on a small hill side (up hill is North).

PVCpipe.jpg (44986 bytes)

An eight foot piece of 4-inch diameter PVC pipe was capped on one end.  Next a post hole digger was used to dig as deep a hole as possible.  The pipe was placed in the hole and measured.  The pipe was removed from the hole and the length not needed was removed with a saw.  A 4-inch clean out was added on the open end of the pipe before it was permanently installed in the hole. A hole was drilled in the side of the pipe and a 1/2-inch tubing connector was guled in it for a cable entrance. The cable entrance is covered with a red balloon in the photo.  This part of the project was completed in the Fall of 1999.

The next step was to set up the Net Media BX-24 micro-processor system and start learning how to program it.  A Radio Shack circuit board was used to mount the BX-24 and re-set switch.  Pins were used so that connections could be easily made or removed.

BX24.jpg (32589 bytes)

This photo shows the 24 pin socket before the BX-24 was installed.   The 9V battery and connector were later installed in a pill bottle with a slide switch mounted to the child proof cap.  The reset switch is the blurry area above the row of six pins.  This setup allowed the BX-24 to be programmed.

The next part of the project was to build a board to mount a couple of DS1624 chips.  The same type of Radio Shack breadboard was used to make the DS1624 board.  Later, a P82B715 chip was added to this board so that a long length of cable could be used (this required a second P82B715 at the other end of the cable).  The next photo shows the counter board on the left, the BX-24 in the middle, and the DS1624 board on the right.  The PC serial port is not connected in the photo since it was being used to down load this photo to the PC.

Electronics_0.jpg (51870 bytes)

The DS1624 board was built first and the BX-24 was programmed to set up the I2C buss and read the temperature of each of the two sensors.  Each DS1624 has a 256 byte ROM and code was written to store and retrieve data from it.  A remote sensor was built on the end of a 15 foot cable and placed in the freezer of my refrigerator in the next room and the BasicX code subroutines were checked.

Next the counter was built.  The counter has several parts.  The time base consists of a crystal standard with a claimed stability of 25 PPM over its temperature range.  I used a 24.576 MHz oscillator, Emerson HG-1012 JA24 566 M-BX2 (under $5.)

This is followed by a divider made from a 74HC4020 followed by two 74HC4040's.  Pins are used so that by moving jumpers the divide ratio can be set to several combinations.  The output of this time base is used as a gate signal to route FGM-3 pulses to the binary counter and it is routed to the interrupt pin of the BX-24.   When the gate is low FGM-3 pulses are counted, when it is high they are not.   The high signal causes an interrupt to be generated so that the BX-24 can transfer the binary count to the shift register (parallel transfer).  The gate signal is also one of two inputs to an AND gate.  The other input is strap selectable from the outputs of the first 74HC4040 chip.  The output is used to reset the 74HC4020 / 74HC4040 chips.  The result is a long gate time followed by a shorter no-gate time.

The 24 bit binary divider uses one section of a 74HCT14 Schmidt triggered inverter (not in photo, added later) to clean up the FGM-3 signal followed by three 74HC590 chips. Immediately after the end of the gate period, the count is latched and then parallel transferred to a 24 bit shift register using three 74HC589 chips.  Next, the 74HC590 chips are cleared so they are ready to begin counting when the gate goes low.

Data is shifted into the BX-24 one bit at a time from the shift register.  A 74HC137 is used to control the various counter circuits with inputs sent from the BX-24.  The circuit is flexible enough that it can be expanded to a three axis counter in the future.  In fact, that is why the 74HC589 / 590 ICs were used instead of more common types. Schematic of the counter and BX24 controller

Software was written to run the counter.  Instead of the FGM-3 signal, signals were taken from the divider chain.  This made the outcome predictable and allowed setting the no-gate period so that it was long enough for the BX-24 to complete the tasks needed before the next count. Unfornatuately later, when connected via a long cable, the FGM-3 counts were somewhat erratic. Adding a Schmidt triggered inverter at the input of the binary counter eliminated the problem.

At this point, a long coil of cable was used as an I2C buss.  The cable capacitance was so high that even just connecting it across the DS1624 board I2C buss caused a failure.  To correct this problem, a P82B715 was added on the DS1624 card and a remote card was made.  The remote card also had a P82B715 chip and a DS1624 on it.  The remote card was driven through a shielded twisted 3-wire cable.   One wire was used as 5 VDC, two for the I2C buss and the cable shield was used for the 5 VDC return.  This worked with well over 100 feet of cable (the cable I had was Teflon jacketed and the wires were #24 Teflon insulated).  The remote board is to the left of the DS1624 board shown below and will be mounted near the FGM-3 sensor inside the PVC pipe in the back yard.

Electronics_1.jpg (49359 bytes)

The next step was to provide 5 VDC for the FGM-3 and the remote DS1624 chips (a second DS1624 chip is physically mounted to the FGM-3).  It was decided to use a separate regulator for the magnetometer (the improvement gained by using separate regulators may be insignificant; it was easier to just do it than think it through).   The remote DS1624 board was mounted to a strip of aluminum with a 7805 regulator mounted on each side of the strip.  Brass hardware was used.

Remote.jpg (12746 bytes)

The grooves in the aluminum strip will be used to lash the cables to this assembly with nylon lacing tape.  Incidentally, the quality of this picture is about as good as I can get with my digital camera.  The picture is taken with the camera too close to be well focused, but at greater distance there is not much that can be seen.   At the left is the 7805 regulator for the I2C components.  The 7805 regulator for the FGM-3 is directly beneath it, on the other side of the aluminum strip. Schematic of remote I2C components

Below is a picture of the FGM-3 with the DS1224 temperature sensor with its four #30 wires attatched. The plastic housing was tempororily removed from the FGM-3 so the DS1624 could be super glued to the flat end surface opposite the FGM-3 leads. Then the plasitic housing was put back on most of the way and the cavity that resulted was filled with silastic. This was done to give the leads some support. The data and clock wires and the power wires were twisted together resulting in two twisted pairs. Schematic of remote temperature sensor

Remote.jpg (12746 bytes)

Before everything is installed below ground, the magnetometer should be calibrated.  A means should be found to orient the FGM-3 in a direction where the magnetic field is minimum.  This will occur when the long axis of the sensor is pointing in an East - West (magnetic) direction.

In order to do this, a discarded wooden turntable was used (originally part of a chiropractic device).  All metal was removed from the turntable and the pivot axle was replaced with a wooden dowel rod.  Wood glue was used to hold everything together so all the screws could be removed.  A plastic IC 'tube' was glued to the turn table along its diameter with super glue.  Slots were cut and rubber bands added to hold the FGM-3 and/or calibration coil.

Turntable_1.jpg (44105 bytes)

 

A couple of holes were bored in opposite corners (not shown in this photo) in order to stake the fixture to the ground with wooden dowel rods.  An index line (not shown) was added along the IC tube axis so that the turntable could be rotated exactly 180 degrees.  It is anticipated the procedure for aligning the FGM-3 will be as follows:

1.  Align the fixture in an East - West direction using a compass.   Stake one corner of the fixture using a wooden dowel rod.

2.  With the temperature stable, measure the magnetometer count.

3.  Rotate the turntable 180 degrees and measure the magnetometer count.

4.  The object is to have the zero and 180 degree counts as close together as possible.  Use a piece of masking tape to add   index marks left and right of the center line on the rotatable part of the turntable and check these points as above.  When a point is found where the count difference is minimum, note the readings and reset the turntable to the center axis.

5.  Now rotate the whole fixture about the dowel rod stake until the count of step four is read.  At this point add the second stake.

6.  Repeat as needed until the fixture is aligned.

With fairly stable temperatures between 50 and 60 degrees F, measure the FGM-3 count as the temperature changes in order to get an idea of the temperature characteristics.  Hopefully this can be done during a quiet period of the geomagnetic field.

Once the temperature characteristic has been found, remove the FGM-3 from the turntable and mount the calibration coil.  Here is a picture of the calibration coil I wound.

Coil.jpg (23910 bytes)

The coil was wound on a piece of PVC pipe using Teflon insulated wire.   The dowel rod shown was marked in such a manner that it could be used to position the FGM-3 in the center of the coil windings.

The current in the coil winding is measured with a meter.  A control box was built so that the current could be finely adjusted and a reversing switch was added so the current in the coil could be reversed.  A large inductor (relative to the calibration coil) was used in series with the coil in order to smooth the current and hold it more constant as the sensor puts out its TTL level signal.  The current through the inductor always flows in the same direction in the box and a diode was placed across the inductor to kill the flyback during switching (which reverses the coil wires).

Out_Box.jpg (19528 bytes)

Out_Box.jpg (19528 bytes)

It is anticipated that with stable temperatures various fields will be created in the calibration coil and the FGM-3 count recorded.

Work yet to be done includes the final calibration of the FGM-3 for temperature and magnetic field, installing it in the ground, writing the Visual Basic program to log the data in Access (or maybe Excel) and tweaking the BX-24 code to include calibration look up tables for calibration and field.  Hopefully the code can be written over the winter.

I also have an LCD display that could be used as a monitor.

 

UPDATE, January 2001

The weather turned cold before the calibration process could be completed. The magnetometer was moved to the garage for the winter. The Visual Basic program for the PC is being created (a workable one is in use at present) and the BX-24 program is being improved.

An accurate current source was designed to run off the I2C bus to supply current to the calibration coil in 100 uA steps. The current source runs from the 5 V supply and can be programmed to supply up to 1500 uA to the calibration coil. Below is a graph showing how the FGM-3 responds to a change in magnetic field produced by the calibration coil current. For each 100 uA change in coil current from zero to 1500 uA, eleven counts are made The graph shows three complete cycles of operation. .

FGM3_Cal.jpg (31K bytes)

A graph showing the effects of the car leaving and later returning is shown below. The car is perhaps three feet from the FGM-3.

Car_Efft.jpg (11K bytes)

 

UPDATE: February 2001 -- First Good Coil Calibration Data

At long last a period of fairly stable magnetometer temperature was observed on February 4, 2001. This period coincided with fairly stable magnetic conditions observed at Bay St. Louis, MS. This run was part of one of a series of runs made by saving the data sent from the BX-24 as a text file on the PC. The time stamp was added by the PC and is only as accurate as the PC's clock and slightly lags the observation. Strings consisting of many data records were built and saved in a file on the PC.

After the run (and during the next run), the data was processed. First, the file was opened in Microsoft Word and all the string markers were removed using a macro. Next the data was imported into Microsoft Access and the error file was used to locate problems in the text file (there are always a few of these because handshaking is not used on Port 1 of the BX-24). The data was redundant enough that accurate corrections could easily be made. A second attempt to import the file into Access yeilded no error file.

Next, the data was exported to an Excell Workbook and inspected for stable temperature periods corresponding to stable Bay St. Louis data. One four hour period was selected and the data was graphed using excell. The result is shown below:

Chart showing a linear charistic (8K bytes)

Incidently, the current source above was built using several REF200 chips and a PCF8574 I2C driven 8 bit I/O port. Expected accuracy of this circuit is about +/- 0.25% (much better than the test equipment I have). The whole thing is supplied by my 5.2V power supply, although pull up resistors were needed on the PCF8574 because it uses internal current limiting when it sources current. Later, a reversing relay and driver were added so that the polarity of this current source could be reversed using another bit of the 8 bit I/O port Schematic of stepped current source.

Chart showing a linear charistic, bidirectional source applied 10K bytes)

Currently, a regulated power supply is being constructed to run another current source to drive the FGM-3's built in coil. I am still struggling with Visual Basic and hope to eventually automate all the data handling.

 

UPDATE, March 2001

The regulated power supply was completed last winter and a second current source to supply current to the internal FGM-3 coil. This source used a single REF200 chip connected as a 50 uA source and three DPDT relays controlled via 3 bits of an eight bit I2C port. Using computer controlled sources on both the FGM-3 internal coil and the external calibration coil allowed a first calibration of the FGM-3 internal coil.

 

UPDATE, April 2001

The FGM-3 was removed from the external calibration coil after many data runs had been completed. It was intended to run the FGM-3 using only its internal coil. Unfortunately, it was connected wrong and all the remote electronics blew out. A new DS1624 chip (this time an SIOC size) was mounted on the FGM-3 and the two chips on the remote board were replaced.

A program was written to check the effectiveness of the decoupling used on the FGM-3 internal calibration coil.

 

UPDATE, May and June 2001

A series of tests was run to check if enough decoupling was being used in the feed wires for the internal and external calibration coils. The FGM-3 was still situated in my garage and although the readings seemed very consistent there were occassional changes lasting less than ten seconds.

I was fortunate to attend the hamfest at Princeton, IL, and was able to purchase two CRT tubes in Mu metal shields. One of these shields was used to make a fixture to shield the FGM-3 and external calibration coil. The fixture was made using 2X8 lumber, PVC pipe, glass epoxy board, and held together with wooden dowels and elastic

Here is a picture:

Shield Fixture

A 2-1/4-inch hole was bored in each of the end 2X8's so that the the small end of a PVC reducer fitting would just fit inside the hole. Three reducer fittings were used at the neck end of the shield and one at the screen end. A rubber 3in. to 2in. pipe reducer (hose clamp removed) was used to add some stability between the conical CRT shield and the PVC pipe near the mid point.

Next is a another picture showing the middle PVC reducer fitting at the neck end of the shield. The outer fitting used for support is hidden. The inner fitting is inside the shield. This provides support for the shield.

Shield Fixture

The external calibration coil wound on another PVC pipe was centered coaxially inside. The FGM-3 was centered inside the calibration coil. The regular FGM-3 wiring was routed the out neck end and the temp sensor wiring exited the screen end. Here is a crude drawing showing further details of the shield.

 

UPDATE, July 2001

Up until now, the PC files have been stored as text. This required running a Word macro, importing the resulting file into Access, and then exporting the result to Excel. The data would then be analyzed using an Excel worksheet..

After months of trying, the Visual Basic program on the PC was successfully modified so the data is both written to a text file and directly written to an Access data base using an ADO connection.

The shielding fixture seems to be very effective. There are no longer occassional unexplained changes in the frequency count. Furthermore, when the car leaves the driveway the frequency changes only about 16.5 Hz (See the graph above which shows several hundred Hz change for the unshielded setup)

 

UPDATE, June 2002

Much data has been gathered with the FGM-3 in the shield fixture with the object of determining the zero field temperature characteristic of the FGM-3. My data does not agree with what others have measured at cooler temperatures. My FGM-3 temperature characteristic seems to change slope somewhere around 23 degrees centigrate and has a very steep negative slope in the vicinity of 12 degrees.

A run made June 15, covering a 19 hour period where the FGM-3 temperature peaked, revealed the results in the shield fixture are not always repeatabe. In the many prior runs the differences were thought to be due to differences between the internal FGM-3 component temperatures and the surface temperature. If this were the case, a slow rate of surface temperature change should result in repeatable frequency readings. This was not shown in the chart for this run.

This effect is now believed to be due to the way in which the temperature sensor is mounted to the FGM-3.

1624 mounted to FGM-3 (44986 bytes)

The DS1624 is super-glued to the unleaded end of the FGM-3. The plastic outer covering of the FGM-3 is pushed past the DS1624 to form a cyclindrical cavity which is filled with silicone silastic (RTV) to provide support for the four small wires. The resulting assembly is placed in the middle of a 1/2-inch PVC pipe 23-1/2 inches long. An identical pipe with an overwound coil is used for magnetic field calibration.

It is believed that the PVC pipe, silastic, and the FGM-3 potting material all have high thermal resistance. Therefore, most of the heat transmission to/from the FGM-3 is via the leaded end of the part. When the external temperature changes the FGM-3 components that determine its output change temperature long before the temperature change reaches the DS1624 temperature sensor.

For example, as the temperature reaches a maxiumum indicated by the DS1624, the FGM-3's components have already reached somewhat higher temperatures and have begun to cool. There is a hysteresis at each temperature that is dependent on the rate of change of the external temperature. Even if the external temperature changes only 1 deg C/hr, there is a very large hysteresis.

 

UPDATE,August 2002

A single Pacific Instruments type SEN-L magnetic sensor was substituted for the FGM-3 in order to begin to compare the two devices. A DS-1624 temperature sensor was bonded to the approximate center of the SEN-L using Arctic Silver Thermal Epoxy.

The SEN-L oscillator circuit used was the one recommended by Pacific Instruments with a minor modification that facilitated remotely changing the sensor bias current direction using my existing equipment. The oscillator was built on a Radio Shack project board of the type used for the BX-24. It was too large to be mounted inside the shield fixture.

The circuit was set up on a piece of plywood supported by concrete blocks, above the shield fixture and aligned for nearly the same frequency reading in either bias current direction. This resulted in a SEN-L orientation noticeably SW of what was expected. The frequency and temperature were measured about every four seconds for several hours and results were graphed. The graph shows that in the general neighborhood of 23 degrees C the drift is about 30 Hz / Degree C.