This weekend I'm working on a pretty strange data logger. It uses the ratiometric voltage-to-frequency circuit described at the bottom of this page to make a wireless data logger for a PC. The output of the V/F drives an infra-red LED and a photo-transistor at the computer receives the signal and analyzes it using a spectrum analysis program like Spectrum Lab or Argo. Those programs have features for automatically saving plots and Spectrum Lab is a treasure-trove of other features, making this data-taking scheme quite versatile. The circuit is quite inexpensive, employing a cheap quad comparator and a couple transistors:
(Don't choose subs for the MPSA18 and 2N4403, if possible. The 'A18 has very high gain, even at very low current and the '4403 has a zero temp-co saturation voltage when biased as shown.)
The front-end of the V/F is modified to accept 0 to1 VDC and convert it to 1 to 2 kHz. See the V/F circuit at the bottom of this page for more details. The output of the converter drives an IR LED to transmit the signal across the room. Alternately, an optocoupler could be used or simply a direct connection to the computer, although the computer's ground is often noisy and good to avoid. The accuracy and linearity of this circuit are surprising. With the 560k linearity resistor, the overall accuracy is probably about 0.2% of full scale. Selecting the linearity resistor for best performance can yield 0.05% linearity or better, depending on one's patience and equipment. All the resistors are 5% types in the prototype and the accuracy is achieved by tweaking the emitter resistor for the proper gain and adjusting the "position" control to place the trace at the desired spot on the display, typically the screen of a program like Spectrum Lab. Here's a small screen from Spectrum Lab:
I adjusted the input voltage with a 10-turn pot (not shown anywhere), taking fairly precise steps at first, then a gentle ramp down, then little steps back up, then a few squiggles.
By converting 0 to 1 volt to 1 to 2 kHz and subtracting 1 kHz from the spectrum display, the frequency in Hz corresponds to millivolts. It's quite linear on a frequency counter.
Here's a quick linearity check:
The converter is accurate beyond the ability to resolve on the screen, even when it's full-size. The V/F was on a bench across the room and held down by a heavy battery (just for the mass):
The V/F is the little board with the blue gain pot. The big pot is the "position" or zero offset control. I don't have the resistors in each end of the position pot so it's a bit sensitive. The IR LED is pointing at my desk where the photo transistor resides. The signal is huge, even without any IR filter material over the photo transistor. I want to add a filter plus a preamplifier to cut down on interference from other signals.
At this point the receiver is nothing more than an infra-red photo-transistor with the collector tied to the tip and ring and the emitter tied to the ground of the microphone input. The microphone input supplies the power for the transistor. Just for kicks I tried a program called Argo using a mode called QRSS 20 with and offset of -1 kHz:
The little plot on the right shows the results of a 1 mV step on the input. It jumps around at the transition because I'm trying to set it by hand with a ten-turn pot. I think you can see the wires in the pot on the plot! My voltmeter was reading 610 mV before I adjusted it down. The beauty of a linear V/F is that the resolution is unlimited, assuming one can measure the frequency with the desired resolution.
The spectrum display can accommodate as many signals as desired. The plot is quite impressive when it fills the screen and the accuracy and stability of the V/F shines.
It's a slower data taker that would lend itself to weather instruments, radiation measurements, propagation plots, and other slow-moving data. The audio format makes data logging as simple as grabbing a voice recorder or a smart phone with an app. The signals from several V/Fs could be transmitted along a common wire if the IR link isn't practical. Single channel links could use a tiny AM or FM transmitter to a suitable receiver.
I happen to have some very, very old PCBs for this circuit and, with a bunch of mods, I made them work. Starting from scratch might have been easier! I made sure to stick to 5% carbon film since the zero and gain are adjustable and temperature stability in the typical lab isn't an issue. The only passive that's critical is the capacitor but most good film types are fine. The best would be a ceramic COG or even one of those huge micas. With better parts, this circuit can exhibit excellent stability over a wide temperature range.
This is the latest active antenna for LF reception, especially my SID receiver that uses WWVB. I've connected the Oddball SID Receiver directly to this antenna without any 60 kHz pre-selection. Previously the antenna was tuned. This antenna blocks the strong AM band signals so it will be interesting to see if the SID receiver can function properly without a tuned front-end (much like a simple SDR).
Here it is in the antenna box, replacing the SID Seizer preamp. The 22 ohm is in series with the base of the second transistor and isn't in the schematic. A jumper probably would work but I'm always concerned about parasitic oscillations and I had a span to jump.
I made a "bias tee" box for two antennas:
The power comes in on the left, connects to the two 10 mH chokes and is delivered to the antenna connectors at the bottom. The signals are passed to the two receiver connectors at the top. One will be for the 60 kHz SID receiver and the "Watering Hole" Receiver at 185.3 kHz. The other is for a broadband whip that's currently driving my Sferics Detector.
After bench testing a couple of things became clear. The circuit has trouble driving the transformer below about 35 kHz, so I reduced the gain at the low end, making sure to preserve gain at 60 kHz. (My goal is to receive 60 kHz and 185.3 kHz at a minimum.) Also, the gain drops off above about 100 kHz, possibly due to the transformer. Lowering the MPSA18 collector capacitor gives the circuit a peaking characteristic that flattens the response nicely. Although the Bode plot below doesn't show it, the actual unit is quite flat from 45 kHz to 300 kHz. The actual plot looks much like the green one below only with the low end rolling off at 45 kHz instead of 20 kHz. The peaking is controlled by the 470 ohm in series with the .0047 uF (a lower value resistor giving more peaking). Tweaking the values gives a beautifully flat response dropping like a rock outside the band.
The response is sharply down by the edge of the broadcast band thanks to help provided by the notch. I just fine tuned a 10 pF trimmer (in place of the 7.5 pF in the schematic) until KLBJ (590 kHz) completely disappears.
I added a 75 ohm resistor in series with the output and the circuit has no trouble driving a 25 foot long cable with a high-Z termination. The receivers will have high-Z inputs.
The antenna is back outside with the new circuit installed, awaiting some additional wiring to get the SID detector back in business.
(This project is languishing due to lack of interest!)
These days I'm looking at ways to pick up emissions from the Jovian system. Going against tradition, I've opted to try to make two small loop antennas do the job, instead of the typical long dipole. The antennas are much like the Hula-Loop antenna, only built for outdoors. In use, the two loops are arranged in a line and spaced 1/2 wavelength apart (25 feet for 20 MHz). This spacing and alignment causes the signals from the antennas due to vertically polarized signals along the antennas' line to be out of phase, and easily canceled simply by adding the signals. Alternatively, one antenna can be flipped around to reverse the phase and a differential amplifier can be used to subtract the signals, with the same cancellation occurring. Signals along the other horizontal axis are already ignored by the loops. The result is a pattern that points straight up. Signals from above will exhibit the same phase in both antennas. Here's a couple of very, very preliminary schematics:
This is the schematic for each antenna. This part seems to work fine and may not change much. The schematic below is a possible receiver that has not been tested, except for the two variable-voltage circuits at the top. Those adjust the voltage to the antenna amplifiers for fine-tuning the gain. The phase is also fine-tuned by slightly changing the frequency of one loop to get minimal response to terrestrial signals. I've gotten from 6 to 10 dB of noise reduction. And, if the two in-phase signals add the way they should, that really means over 9 dB improvement over a single loop!
The receiver portion is untested and will require that I rotate one antenna 180 degrees. Looking at it, I need to add termination resistors for the cables. I'd probably eliminate the 1000 uH chokes and bypass the emitters of the darlingtons to ground with .01 uF caps. That would terminate the cables with close to 75 ohms (68 plus a little from the darlington emitter). The receiver is a direct conversion type with a low-level audio output that will need further amplification and processing. Eventually, I want to make a circuit that will "collect" pops and pulses in windows of time in some fashion, perhaps a peak/hold or an integrator. That way, the storms can be displayed on a slow plot, showing several hours of data.
I've been thinking about the circuit above and I've decided that it would be better to have a 1 MHz tuned transformer in the collectors of the differential amplifier, followed by a 1 MHz filter. That would drive another amplifier before driving a detector. The reason to not go directly to baseband is that it would be easy to set the bandwidth of the filter to 50 or 100 kHz, before the detector, to get a higher receive bandwidth.
For now, I've been using an ordinary power combiner feeding a selective level meter for testing the antennas (at 20.1 MHZ). I transmit the audio all over the house with the "Unfair Radio Transmitter." The antenna phasing trick does seem to work. I can get up to 10 dB reduction in background noise during the day, and that's not counting the fact that two antennas should increase the signal strength significantly. Here's a photo of the antennas and receiver in an empty room above a garage:
The camera was inside one loop, facing the other loop. They're slightly out of alignment to reduce a local interference source, but that's gone now, so they're nice and straight, in a near north/south alignment.
There was an "Io B" period on 11/25/2011 that I seemed to have received with this setup. Keep in mind that virtually all of my experiments give "false positives" at the beginning! This will be no exception, I suspect. Most of the time, the receiver outputs a clean white noise sound, but this racket occurred during the expected window of time, and faded right on schedule - seemed real to me. (Well, I think I heard that "noise" again and it might be splatter from a strange-sounding teletype transmission of some sort - not sure yet.) Fine-tuning one antenna could peak the signal or completely null it out, so the cancellation technique does work. Here's a terrible little video where I disconnect one antenna from the power combiner to show how much louder the background noise is without cancellation. Unfortunately, the battery in my camera died right at the end, so you only get a fraction of a second of sound with the second antenna disconnected.
I'm pleased that these electrically small loops seem to work indoors! But the room is a good distance from the electronics in the house, it's a second story above a garage, and there's little metal in the walls.
It was pointed out to me that Jupiter will be invisible to this type of receiver for much of next year. It will be high in the sky at the same time as the sun. It will be late next year before the conditions are good again. So, I'll probably use this setup with the power combiner and selective level meter to determine whether the antennas really work and wait to build the stand-alone receiver for a while.
Below is a ratiometric voltage-to-frequency converter I'm developing. Here's a list of advantages:
More measurement resolution is easily had by simply counting longer (4.5 digits in 1 second and 5.5 digits in 10 seconds for a 10 kHz V/F), or by using a high resolution period measurement or fractional cycle measurement. The circuit below will work well up to about 30 kHz.
Ratiometric response rejects excitation voltage variations when using bridges or voltage dividers. Simply run the V/F and sensor on the same voltage.
The signal is averaged over the full measurement interval. That's more important than it sounds in noisy environments!
Open-loop design gives very low jitter at low input levels, giving steady readings and making high-resolution period measurements possible.
Frequency output can be directly plotted using FFT software, such as Spectrum Lab.
Dirt cheap! I recently bought dirt for my garden, and I can attest that this circuit is significantly cheaper than dirt. In fact, most things are cheaper than dirt.
Linearity adjustment can remove some non-linearity from the source as well as the reset non-linearity.
Not shown is that a transistor may be added to pull pin 2 down for an external sync, greatly reducing the tendency for the last digit to jump around in simple counter applications. The gate signal simply turns on the 2N4403 until the counter is ready to count again, making the circuit start at the same point for each count period.
The top schematic is the main unit, and it uses an ordinary quad comparator (LM339). The bottom schematic uses a "rail-to-rail" op-amp as an optional buffer. The buffer isn't always necessary, but the linearity resistor on the converter's input does source a little current to the input that might cause a problem for very high impedance signal sources.
This open-loop design relies on key components' stability for precision, but the lack of feedback gives it remarkably low jitter, especially at low input levels. The input signal is compared to a divided-down version of the power supply, so the frequency output is proportional to the ratio of the input voltage to the power supply voltage. This ratiometric response gives added stability when measuring voltage dividers, or bridges, even after amplification, including typical strain gauges, pressure sensors, and potentiometers. Since there is no feedback, it would be expected that the finite width of the reset pulse would cause the frequency to read low as the input voltage increases. That little error can be corrected by making the reference voltage track the input voltage slightly, which is accomplished by the linearity resistor. Mathematically, the correction is perfect and the linearity can be tweaked to better than 0.01% of span for a full-scale frequency of around 10 kHz.
The 1000 pF capacitor is critical, and should be an COG (NPO) or similarly stable capacitor. The MPSA18 connected to pin 1 is also critical and only very high gain types will work well.
It's hard to adjust the gain and linearity without a precision voltage switchbox, maybe with 1 volt steps from 0 to 5 VDC. The voltages can (probably should) be simply divided down from the power supply, thanks to the ratiometric response, but use high-precision or measured resistors for maximum accuracy. With care, the performance can be surprisingly good.
One could modify the input buffer circuit to output 2.5 to 5 volts for the desired input voltage range, causing the V/F to vary from, say 5 kHz to 10 kHz. That single octave range could be used with a spectrum analyzer program like Spectrum Lab to make a precise voltage chart recorder. The output of several V/Fs could be combined through fairly large resistors of different values to plot several variables on one chart. The different value resistors will present different amplitudes to Spectrum Lab, so each trace can be made a different color.
Here's briefly how it works: The first op-amp and MPSA18 sink current in proportion to the input voltage. The capacitor voltage ramps down at a rate determined by the input voltage. When the capacitor voltage drops below the reference voltage on pin 9, the comparators change state, and the PNP discharges the capacitor very rapidly. The discharge is so fast, that it is completed before the comparators reset. The 2N4403 has a very low saturation temperature coefficient when biased as shown, so it makes a stable reset switch, albeit with a little offset voltage which is calibrated out during initial adjustments. The reset pulse is quite short, so the last comparator is added to generate a square wave output.
This weekend, I'm working on a better system for posting real-time data. I think I have an adequate Visual Basic macro for Excel that will import data from an inexpensive Dataq device. The second graphic on the "live data" page shows the end product. Here's a list of what I'm doing so far:
A macro running in the Excel spreadsheet reads four channels of a Dataq DI148U every 100 seconds and places the data in four columns. (I modifed a macro I found on the Dataq site.) There are 864 rows, for a total of 24 hours. It also creates a fifth column with the current computer time. I'll send that spreadsheet to anyone who wants to give it a try. It's not too terribly difficult to get it working or to modify it for other Dataq devices. I can give limited advice, but I managed to stumble through it so you can, too. I have an aversion to software!
The spreadsheet generates the two graphs, one an x-y scatter plot of one channel (with connecting lines) and the other an ordinary line graph with three channels. So that the scatter plot looks sensible, I started the macro at 0:00, which is the beginning of the plot. Any sort of calculation or graphic may be performed or created with the data; it's just a spreadsheet, after all. It's pretty obvious what needs changing in the macro to modify the number of rows or columns, too.
Now it gets edgy: In order to get the image on the web page, I first use a "magnifier" written in AutoHotkey. It has a magnification of one, and only serves as a controllable window capable of "looking at" anything on the screen, even overlapping programs. I modified one that I found on the web by reducing the magnification to unity and by removing its transparency. I'll post that program, too. Then, I use Irfanview to capture the client area of the magnifier program every five minutes. Capturing the client area of this simple magnifier program results in a completely clean image with no "stuff" around the edges like scroll bars. Irfanview saves the captured image to a public dropbox.com folder on another local computer (it could be the same one). I use the URL of that image that dropbox.com supplies on my web page and they serve that portion of the page. This trick makes it easy to avoid extra security measures some web servers have that make it so difficult to automate uploads.
All of these steps are pretty easy, now that I've got the macro working. The hardest part for others who aren't programmers will be a couple of minor modifications to the macro to work with their Dataq device, basically making sure that the correct com port is set and the correct model number for the Dataq gadget is in the macro. Also there's an oddity with the baud rate that I can't explain but can work around. For some reason, changing the baud rate seems to change the sample rate, at least at the extremes. I set the baud rate in the macro to 9600 and I would do the same to the Dataq device, using the supplied configuration program. I think I didn't change the Dataq setting at first and it didn't seem to care. But it matters in the macro, at least for this computer. A mid-range baud rate seems to make the sample time entered give the correct delay. I'll leave that one for more software-oriented people to explain. I enter 0.01 Hz for the sample time to get 100 second samples. You might get fine results as-is.
I moved the solar flare stuff to: Solar Flare Project