4-Channel Data Logger

Thread Starter

Wingsy

Joined Dec 18, 2016
86
I'm thinking seriously about undertaking a project to build myself a 4-channel data logger. So far I've come up with some specs I want it to meet, and most of the hardware. If anyone has any ideas of what to take out or what to put in, I'm all ears (or eyes in this case).

Resolution: 12-bit

Accuracy: 0.1%, but I'll take 0.5%

Sample rate: Max of 4000 s/s, all 4 channels simultaneously. Selectable from 4k/s to 1 sample per minute. At slower sample rates each channel is averaged, up to 16 samples per reading.

Range: 2, 4, 8 or 16V.

AD780 reference for ADC, trimmed to 3.072v. The most accurate voltmeter I have is a EXtech 560 so my accuracy is totally dependent on that (0.03%).

LCD screen (NewHaven NHD-C0216CZ-FSW-FBW-3V3) for setup and showing channel values as they are read.

2MByte Flash chip (AT45DQ161) for storage.

Serial port for upload to computer, in CSV format. (No, not going to a flash card.)

A DPDT relay, for control of whatever I'm recording. (Like battery discharge, to shut off tester at some threshold.)

What else?
 

OBW0549

Joined Mar 2, 2015
3,566
Two more things to consider: anti-aliasing filtering, and some sort of overvoltage protection on your analog inputs which will function both with power on and power off.
 

Thread Starter

Wingsy

Joined Dec 18, 2016
86
Two more things to consider: anti-aliasing filtering, and some sort of overvoltage protection on your analog inputs which will function both with power on and power off.
The inputs go through a 105k before reaching an input amplifier (TSZ124), and the amplifier has a max input current of 10ma. So I should be OK for an input on the 2v range of 1000v (Ha!) or until the 105k smokes (about 150v).

And I have no plans for an anti-aliasing filter other than a small capacitor in the feedback of the input amp (gain of 1.5). What are the implications of essentially having no filter?
 

OBW0549

Joined Mar 2, 2015
3,566
And I have no plans for an anti-aliasing filter other than a small capacitor in the feedback of the input amp (gain of 1.5). What are the implications of essentially having no filter?
You'll be susceptible to aliasing; that is, if your input signal has any frequency components higher than half the sampling rate, they will alias down into the lower frequencies. For example, if you're sampling at 4 kHz and your input signal has a strong component at 3.9 kHz, that signal component will appear to your system like 100 Hz (4 kHz - 3.9 kHz = 100 Hz).

Generally not a good thing, although how disruptive aliasing is depends on what you're doing. If you're trying to digitize audio, it will create havoc; if all you're doing is recording the slow discharge of a battery into a load, it can almost certainly be ignored.

Googling on "why use anti-aliasing filter" will bring up a lot of good tutorial and reference information.
 

Thread Starter

Wingsy

Joined Dec 18, 2016
86
OK, I'm done. Took a while, between doing this and occasional real life stuff. I didn't get the sample rates I originally wanted - the effort seemed to increase exponentially with the sample rate. So my max is 200 samples/sec. But hey, it's now 16-bit rather than 12, so I'm calling it a tradeoff. Here's the "specs":
All channels: 200s/s, 100s/s, 50s/s, 25s/s, 10s/s, 5s/s, 1s/s, 10sec, 30sec, 1min.
Each channel full scale ranges: 0.256, 0.512, 1.024, 2.048, 4.096, 8.192, 16.384
Record time: 1min, 10min, 30min, 1hr, 5hr, 10hr, 24hr, 2days 5 days, 10days.
Auto record stop for chan #1 above/below specified limit.
Relay on (optional) while recording.
Data transmitted via XMODEM at 115kb.
Power: 9-12v.
Current drain 33ma, 13ma with backlight off.
All the setup & control is done with the 3 pushbuttons and the 2-line x 16-char LCD.
Cost: around $75
Code size around 4.4kb

For a long long time I have occasionally had the desire for a data logger, and since I'm retired and the winters are boring, I built one. A solution now looking for a problem.

DataLogger.jpg
BatteryCharge2.png
 

Thread Starter

Wingsy

Joined Dec 18, 2016
86
Thank you both.

Next project is a simulated rotating beacon for a miniature lighthouse I plan to put on my pond, on a fake rock. 16 LEDs in a circle, 3 LEDs on at a time. The leading LED is increasing in brightness while the trailing one is decreasing. I'm hoping that will appear to be a mechanical rotating beacon. Whatcha think?
 

Reloadron

Joined Jan 15, 2015
7,889
Years ago it may have been this or another forum but there was a guy who built a lighthouse and used a LED fade in and fade out. When all was said and done I saw a video of it and it turned out really good. I believe the same for yours will happen. Projects like a light house require a skill set of paying attention to detail, the same detail I saw in your board layout and print. Hell yeah, go for it and best of luck.

Ron
 
Top