Show Posts
Pages: [1] 2
1  Using Arduino / Sensors / Re: DS18B20 NOT RESPONDING on: July 02, 2013, 03:36:14 pm
MBird,
In a previous thread I posted my DS1820 library. Maybe it will help.
http://forum.arduino.cc/index.php?topic=173589.msg1292707#msg1292707
It should help you to see how to talk to the device.
2  Using Arduino / Sensors / Re: Maxim DS18B20 Temperature Sensor Giving Bad Readings on: June 25, 2013, 05:22:31 pm
Hi Eugbug,
I used this sensor in a project a while back. In order to learn how to use it, I wrote a library that wrapped the one-wire library. I won't claim this to be the greatest code but it worked well for me in a Sous Vide cooker project. Maybe you can get some ideas from it. It even has documentation!
3  Topics / Device Hacking / LCD Screen Display KD035G6-54NT-A1 on: June 19, 2013, 04:02:06 pm
Hello,
I have a LCD Screen Display type KD035G6-54NT-A1 that appears to have a serial interface as well as RGB. It's apparently a pretty standard 320x240 display that I got from a video advertising card. I have a minimal datasheet with pin outs and some timing diagrams so I may be able to figure out how to talk to it. But it'll be a big learning curve.
Has anyone here ever worked with such devices? I would really appreciate a head start. I don't have any real idea what I want do with it yet, maybe something kind of arty, but getting something to display is the first step.
I have an Arduino UNO but would get something more powerful if needed.
Thanks for reading,
Totoro
4  Topics / Science and Measurement / Re: HELP me with buying a Digital Oscilloscope. Bandwidth selection on: May 29, 2013, 03:53:55 pm
pete,
At the risk of keeping this off-topic, a quick follow-up. There is a review of the Saleae 8-channel unit here: http://www.eevblog.com/2013/03/09/eevblog-436-saleae-usb-logic-analyser-review-teardown/
5  Topics / Science and Measurement / Re: HELP me with buying a Digital Oscilloscope. Bandwidth selection on: May 14, 2013, 03:14:42 pm
If this is your first 'scope, and given the uses for it you mention, my advice is to get a decent analog unit on ebay. I have an inexpensive DSO and an old Tektronix analog and I use the Tek far more than the DSO. The reason? Mainly because the persistence of the analog scope allows me to see the spikes and glitches in much better detail. DSOs with persistence are coming down in price but you're looking at about 7-800$. You can find a good analog scope, e.g., Hameg or Tektronix 2-ch 50-60MHz for less than 100$ and you'll learn a lot about how scopes work.
And you can add the Saleae logic analyzer mentioned above and still come out spending less than a cheap, entry-level DSO.
My two cents, anyway.
6  Topics / Science and Measurement / Re: ESR meter with Arduino on: May 14, 2013, 02:06:17 pm
Hi Baravantan,
To answer your last question, yes, I have measured what seem to be good values in the milliOhm range. I have a 100mOhm precision resistor and have measured many capacitors with what appears to be reasonable and repeatable results.
I took a quick look at your code and all appears to be OK with the actual calcESR routine. I didn't look at your PCB layout so I can't say more than that in my proto-board build I used the schematic exactly as in the original post EXCEPT that I used a 10microFarad cap and a 110Ohm resistor in the pulse circuit (47micro and 100 Ohm in the original).
I did notice in testing that the whole thing is very sensitive to the declared supply voltage and the value of this resistor. And I noticed in your code the following...

double Vin_LO = 4700; // milliVolts
uint16_t Rs_LO = 110; // Ohms

Are you actually using a 110 Ohm resistor? And is your supply voltage really only 4,7 V? Unless these (and the Vref voltage) are well defined, the calculation can be very non-linear.
Anyway, hope this helps.
7  Topics / Science and Measurement / Re: ESR meter with Arduino on: April 11, 2013, 02:19:02 pm
Wow, what timing! You posted while I was composing. Please read my update.
I think your simulation is too simplified. I would be interested in your opinions if you would try mine.
8  Topics / Science and Measurement / Re: ESR meter with Arduino on: April 10, 2013, 03:36:17 pm
Hi bseishen,

If you read my original text (kept intact, below) then I am sorry. I 'double-thinked' myself into some confusion. I will try for a better take.
First, the Schottky diodes only limit the maximum voltage available to the DUT. Here's what happens. The transistor Q1 turns on and a rising wave edge goes through R8 and is pretty much unaffected by C2/C1. So, R8 is effectively in series with the DUT. This forms a simple voltage divider and the rising wave edge sort of shelves at the voltage determined by the divider formed by R8 and the DUT. For a DUT with, say, 100 milliOhms, that is a pretty small voltage, i.e., a few milliVolts. Since we're dealing with capacitors here, there is some continuing charging that will mess up the measurement if we wait too long to make it. I put together a LTSpice model to play with this. Attached is a closeup of a pulse from a sample run with a DUT of 100uF and .1 Ohm ESR. The yellow trace is the R8 side of C2 and the blue is the DUT side. (I had looked at the same thing on a 'scope and the simulation agrees really well. I don't know why it didn't sink in earlier. It is interesting to do a run with a resistor as DUT. The 'shelving' is more apparent.)
So, pretty much ignore what I said before. Part of my confusion was from using a different power source after changing the diodes. This shows that the value for Vcc in the code is quite critical for consistent and linear results. Also, it is now apparent how two ranges work by adjusting the voltage divider.
I hope this helps. My understanding is better, anyway.

---- here is the original text ----
I went back and really looked at this as well as reading the original document by Dr. Le Hung (link in szmeu's first post). I have to admit that after looking closely, I really don't understand this completely either. Clearly, the pulse can only have an amplitude determined by the schottky forward breakdown. In my circuit I used germanium diodes and that was about 300mV. I just swapped them for 1N5822 (as in the orignal schematic) and now have a pulse of 220mV and my calibration is way off. What seems apparent now, is that the voltage specified in the code as the 'supply' voltage, i.e., 5V, is just a number. I mean that it has to be adjusted to correspond to something that, well, I don't know exactly what it specifies. Dr. Le Hung calls the pulses current pulses. There must be something to that since the two ranges do work (there is a factor of ten, approximately, difference when the pulse 'comes from' the 100 vs. 1000 Ohm resistor).
Try playing with the voltage value and see if you can dial something in. I haven't tried that yet but it will be my next step to try and figure this out.
I am first a software guy and the hardware part of this is now not as clear as I thought. Maybe someone else can add to this.
9  Using Arduino / Displays / Re: Help needed with 16x2 LCD Displaytech 162A on: March 16, 2013, 03:33:03 pm
Hi again,
Yeah, it looks like you should be calling the lcd constructor with LCD pins 4,6,11,12,13,14 or for your assignments arduino pins 12,10,5,4,3,2. And I think the LCD pin 5 needs to be tied low.
-Totoro
10  Using Arduino / Displays / Re: Help needed with 16x2 LCD Displaytech 162A on: March 16, 2013, 03:07:22 pm
Hi durpex,
I don't have the spec for the LCD here but something does look odd. You have pin 6 on the LCD connected to pin 10 on the arduino, but no where in the code are doing anything with pin 10.
(?)
- Totoro
11  Using Arduino / Displays / Re: Dewpoint in F° conversion ? on: March 16, 2013, 02:52:26 pm
Hi GD,
Since your temperature is in celcius, just calculate the dew-point with the temp and humidty values (don't try to convert the humidity). Then just covert the  dew point result to F.
12  Topics / Science and Measurement / Re: ESR meter with Arduino on: January 25, 2013, 01:59:05 pm
Sreg,
Great to hear you got it working!
You mentioned above that you return -1 when millVolts is zero. I wondered why, so I took a look at your code. You have helped me to avoid a bad thing, the potential divide-by-zero bug. Thank you!
- Totoro
13  Topics / Science and Measurement / Re: ESR meter with Arduino on: January 24, 2013, 07:01:20 pm
bobale,
Sorry, I am just a breadboard/point-to-point/proto-board type. My main need for an ESR meter is to troubleshoot old audio gear and test equipment.

14  Topics / Science and Measurement / Re: ESR meter with Arduino on: January 24, 2013, 05:29:38 pm
Sreg,
First, just to be sure we're on the same wavelength, short pins 1 and 2 on CN1 (on szmeu's schematic) together and put the  device-under-test (DUT) between these shorted pins and ground. For now, just ignore the possibility for a four-wire setup (actually three wire with the circuit from szmeu).
OK, you've done that. Now, with a 30mV pulse across your DUT, you can do the math and you should have approx. 600milliOhms +/- for the DUT. This assumes that at top of the 100 Ohm resistor, R8, (where it connects to the emitter of Q1) you see a 5V pulse.
If that's the case, then you may want to make sure that the oversampling is set up correctly for your device. You may need to change some of the register set stuff in the original code. This stuff...
  sbi(ADCSRA,ADPS2);
  cbi(ADCSRA,ADPS1);
  sbi(ADCSRA,ADPS0);
Refer to the datasheet for your device and the Atmel document that szmeu mentions.
Then again, it could be something simple like the discharge transistor, Q2, is always on. Or you didn't change the value of Vref in the code. You mention the internal ref on your device is 2.56V. In the code it's 1.1.
This is all just guesses on my part. Maybe you have checked all this stuff. My 2 (euro) cents worth, anyway.
Good luck!
- Totoro
15  Topics / Science and Measurement / Re: ESR meter with Arduino on: January 23, 2013, 06:13:13 pm
I am happy to post my code. You can download it from here.
http://vondervotteimittiss.com/belfry/downloads/ESR_Meter.ino.zip
Just keep in mind, it is a work in progress. As it stands, it works with the 'high-current' resistor in the circuit (the 100 ohm resistor which is actually 110 ohm in my circuit and in my code I refer to this as the low range).
As I mentioned, the schematic I used is the same as szmeu originally posted. (OK, not exactly. I use a 110 ohm resistor, because I had one, and a 10microFarad capacitor, because I had one. Adjust the resistor value accordingly in the code.) The pulse generation part of the circuit as szmeu posted is really elegant and needs no change.
The only change I made is in the display. In my breadboard, I use a three-digit, seven-segment display and have programmed the Arduino drive it. (Adjust the SEG_ON/OFF, DIG_ON/OFF defines as appropriate for your display setup and anode/cathode digit switching transistors.)
I am currently working on getting the 'low-current' mode (the 1000 ohm resistor), what in my code is the high range, to work. That should let me measure higher values of ESR, as szmeu suggested.
Please keep in mind that I am new to micro-controller programming! If you have any questions about the code, I'll try to answer as best I can.
And if you have any suggestions how I can improve, please let me know.
Thanks for your interest.
- Totoro
Pages: [1] 2