Sensor interface board, power question, general review - Page 1
Forum section: electronics / projects

author: PioB
author_rank: Regular Contributor
timestamp: February 15, 2014, 04:25:47 pm
content: Hi,I am designing a computer interface for my wife who would like to measure some properties of a membrane for her PhD work.For this she'll sweep over a continuous water flow through the membrane (0 ml/sec ... n ml/sec) and will measure the pressure difference before and after the membrane.I ordered some differential pressure sensors that take 12V and output the signal from 0..25 mV or 0..40 mV as follows:10 kPa sensor:2.5 mV/kpa (0..25 mV)100 kPa sensor:0.4 mV/kpa (0..40 mV)My design (single sided board, red connected vias will be wires) so far:To feed the sensor and the amplifier I use a Traco Power TMA0512 DC/DC converter putting out ±12 V.(1)Signal arriving from the sensor: I am using GND as a reference, but should the Vout- of the Sensor go too negative, I can pull that to GND with a jumper on connector M02.The INA126 Instrument amplifier (of which I have one in my parts bin and thus used it for the design) takes one resistor (R2) to adjust the amplification factor (412 ? for 200x).(2)The signal is then put through a 1:1 voltage divider so I can amplify the 25 mV(max) signal 400 times or the 40 mV(max) signal 250 times to 10 V and then go into the DAC without being afraid of applying more than 5 V. Is there a better solution?In a first version I'll just use the integrated ADC of the ATmega328p and then go to a USB-UART board.The big questions I have are:1) Power - The TMA0512 can furnish up to 1W, the sensor, uC and Amplifier should not use too much, so USB powered (5 V 500 mA) should furnish enough power. Should that not be the case or VCC from USB not be stable enough, how could I power the system externally and not lose USB functionality without making my FTDI interface and following the data sheet on auxiliary power? She has access to CNC facilities at her university which can easily make boards for THT components, but an FT231X in TSSOP is a bit small...2) Is there a better solution for taking the output from the amplifier and feeding it to the ADC without frying it?3) Any gross mistakes I was overlooking in my designThank you very much for your help.(1)Something about the TMA0512D DC/DC-converter I just found out by measuring on the breadboard:It puts out about ±20 Volts without any load, with only the INA126 connected about ±13.5 V and with additional 10 kOhm from the rails to GND around ±12.5 V.According to the data sheet "-– Load variation 20 – 100 % ±10 % max."So I added R4 and R5 from the rails to the ground to add some load which brings the voltage to 12 V.(2)From the data sheethttps://www.distrelec.ch/ishop/Datasheets/vzINA126_e.pdfCode:DESIRED GAIN R_G NEAREST 1%(V/V) (?) R_G VALUE (?)5 NC NC10 16000 1580020 5333 536050 1779 1780100 842 845200 410 412500 162 1621000 80.4 80.62000 40.1 40.25000 16.0 15.810000 8.0 7.87

author: Rerouter
author_rank: Super Contributor
timestamp: February 15, 2014, 09:34:43 pm
content: Ok, as you have such low signal voltages i shall warn you that you are well in the realm of thermocouples (dissimilar metal junctions can create a few hundred uV to a few mV based on the temperature difference) to avoid this, keep the 2 traces as close as possible,next up is your switcher, its specced for 100mV ripple, so unless your sensor tells you it has good ripple rejection, you may want to increase your filtering more than a 22uF cap, (perhaps to that end tell us its current draw, for low currents LC filters can work wonderfully,As for powering externally, your switcher can tolerate 5V +-10%, so you could OR the voltage rail to it with 2 schottkey diodes and be within the 4.50V margin, the best way would probably be to use a physical switch to select what you want, (no room for error)Furthur reading over your schematic i am curious why you are running the amplifier off +12, if you add a 4.7K resistor in series with both inputs you can swap the positive rail to VCC, (on datasheet under input protection) which will protect the micro from having 12V shoved up its ADC if the gain it too high, and allows you to remove the resistor divider on the output, instead have something in the 4.7K ballpark in series to the ADC, and a reverse polarity protection diode from ground on the ADC side of that resistor, (anode to ground cathode to ADC)

author: PioB
author_rank: Regular Contributor
timestamp: February 15, 2014, 10:55:28 pm
content: Hi Rerouter,thank you very much for your comments. I'll answer quickly to the ones I can and will look into the rest after a good night's sleep. My background is in chemistry, but I'm trying to learn fast.The data sheet for the DC/DC converterhttps://www.distrelec.ch/ishop/Datasheets/tma_eng_tds.pdfsays"Capacitive load– Single output models 220 ?F max.– Dual output models 100 ?F max."that's why I only put 22 uF per rail. Or is it possible that I misunderstood that specification?The sensor(s) that will be used (http://www.freescale.com/files/sensors/doc/data_sheet/MPX2010.pdf, orhttp://www.freescale.com/files/sensors/doc/data_sheet/MPX2010.pdf) use about 6 mA, so about 70 mW.Thank you very much.

author: Rerouter
author_rank: Super Contributor
timestamp: February 15, 2014, 11:16:04 pm
content: Quote from: PioB on February 15, 2014, 10:55:28 pmas your model is a dual output it means the maximum can be 100uF per rail, but the better thing to do is add an LC filter after your output cap rather than increasing your bulk capacitance and still seeing the switching noise,as the switching frequency is approximatly 100Khz, try adding a 33uH inductor and 22uF cap as a 5Khz LC lowpass filter after your 22uF bulk capacitance (the resistance of the inductor isn't at all critical, just aim low to minimise voltage drop) arguably 5Khz is much lower than it needs to be but the components are not big,The main reason i am thinking to filter out this noise is the datasheet says output is ratio-metric to supply voltage,

author: tszaboo
author_rank: Super Contributor
timestamp: February 16, 2014, 12:48:02 am
content: Quote from: Rerouter on February 15, 2014, 11:16:04 pmExaclty. You will not have 12V on the output, if you use USB, becausehttp://nandblog.com/usb-5v/usb is not 5V. That is probably fine here, as your circuit will still work with 9V.The INA126 is a bit excessive, too accurate for a MCU ADC.One other problem is that you dont have anti-aliasing filter for your ADC. the INA has limited bandwidth, but I assume your sampling will be low frequency.

author: PioB
author_rank: Regular Contributor
timestamp: February 17, 2014, 10:32:51 am
content: Quote from: Rerouter on February 15, 2014, 09:34:43 pmThank you very much for your input, I modified the schematics accordingly, I'll get to work on the board if I didn't goof anything up. The sensors have an output impedance of min 1400 — max 3000? according to the data sheet, so I don't think I need an additional current limiting resistor in the input path to the amplifier?So in the end I'll have a signal between 0 and 4 V to work with (worst case output ina126 (V+)-0.9V), so I'll amplify 160 or 100 times depending on the sensor, so no worries on frying the ADC.Quote from: NANDBlog on February 16, 2014, 12:48:02 amThank you very much. I read your linked blogpost (and more there), very interesting. I think to best not connect USB VCC and just operate the amplifier via an external 5V power supply. The sampling will be indeed slow enough; pushing water through the membrane won't need insane sampling rates so that I don't need to filter out any HF components.

author: PioB
author_rank: Regular Contributor
timestamp: February 18, 2014, 08:40:23 pm
content: Hi,ok I redid the schematics and the board taking all suggestions into account. I hope I haven't overlooked anything obvious.

author: babysitter
author_rank: Frequent Contributor
timestamp: February 18, 2014, 09:02:47 pm
content: Hi,you might get additional info if you tell us more about your sensor!I wouldstronglysuggest to add means to measure the supply voltage of the sensor, as they might be ratiometric and the output signal is dependent on the supply voltage. (Using an inamp and the low output signal sound like wheatstone bridge type sensors. These are ratiometric. Sensors with preconditioning would output higher voltage I guess.Crazy bandwidth: If you trap some air bubbles and your sensors have some bandwidth, you might be surprised what signals you get !I worked with a filter manufacturer and designed a dedicated trans-membrane pressure/flow measurement system for their lab/education center. Made of reusable sensors with attachable media adapters.

author: PioB
author_rank: Regular Contributor
timestamp: February 18, 2014, 09:27:27 pm
content: Quote from: babysitter on February 18, 2014, 09:02:47 pmHi,thank you very much for your info.I just showed your post to my wife and she said that you did exactly what she wants to do!The sensors I ordered are the MPX 2010DP and the MPX 2100DPhttp://www.freescale.com/files/sensors/doc/data_sheet/MPX2010.pdfandhttp://www.freescale.com/files/sensors/doc/data_sheet/MPX2100.pdfwhich are indeed "Ratiometric to Supply Voltage"As to the data sheet which they are not thought for measuring anything else than dry air, so the idea was to only connect the high pressure side to water and purposely trap an air bubble. The low pressure side would hang open for our first tries.For measuring the input voltage, a voltage divider in front of the ATmega ADC would be sufficient; or would more precision be needed?The paper my wife found was sparse on any kinds of details, no technical info other than that they used an Omega PX26-001DV wet/wet sensor (and showed a noisy graph)... I'll ask her for the reference.I am also a chemist and am working on gaining some electronics knowledge...Thank you very much for your help

author: babysitter
author_rank: Frequent Contributor
timestamp: February 18, 2014, 09:56:45 pm
content: Sounds like I am able to helpYour wife should try to get a disposable blood pressure monitoring set for arterial and venous pressure from a nearby hospital or medical device dealer to begin with, go for any, you can be almost certain that they either employ Freescale MPX2300, GE (now Amphenol?) NPC10x or some Hipot HYB ceramic hybrids. They all are made for 5V excitation (you better have a dedicated regulator, e.g. good old REF195 only for the analog frontend, to keep noise from the digital subsystem out) with 25 µV at 5 V excitation as output signal. Use a Inamp (I like the AD620) to preamplify and use the REFIN connected to a pot to trim away the zero offset. Allow negative swings of the pressure-proportional signal.Ratiometric mode: Check if you can use a external reference voltage with your ADC, use sensor excitation voltage for this.Physical connection is a Luer-Lock on one side, the other side might be obstacled by a flushing system (tiny leak that allows several ml/h drip from a pressurized saline solution reservoir into the tubing that goes to the blood vessel), you might need to break off and glue something there (its often polycarbonate) to get a flow-through sensor, a "T"-connected sensor can be done by blocking the flushing system.Filling: You can reduce the bubbles by employing a filling liquid with some soap in it which gives the bubbles more possibility to move away during filling. Big bubbles give a slow response of the system (e.g. with your bubble on purpose), its the small ones that give HF "shaking" when the liquod column is moving.Flow: Getting to know the flow rate was done with a weight scale with RS232 output under the wastebucket, a proper flow sensor was later added by the filter tech guy himself, I did not have it on the radar.