« first day (1615 days earlier)      last day (3315 days later) » 

6:59 AM
@PlasmaHH Check Pringles containers you have lying around.
@PlasmaHH I really hate it when anonymous upvotes without explanation.
 
 
1 hour later…
8:17 AM
@jippie What I hate even more maybe are the "+1 to counter unexplained downvote"
 
 
3 hours later…
10:53 AM
stack egg? seriously? wtf?
 
 
5 hours later…
4:17 PM
@PlasmaHH It means you better have a good reason that will be obvious to others before you downvote. If you downvote for a trivial reason, somebody will come along and counter-vote you, which is a net win for the OP.
 
Hey guys
If any of you remember, I was in here a while ago asking questions about how to combine the pulses from two flow meters and read them independently.
I solved that problem by using an R-2R to drop the voltage of one flow meter by 25% and the other by 50%.
Now I wanted to read that combined pulse though a mic port on my pc/a tablet. The problem was the +5v from the mic did not have enough amperage for the flow meters. So I used a usb port for power.
Now the problem is getting the voltage from the flow meter pulses to the mic. I thought I needed to use an op-amp to create a voltage follower. That way I could control the voltage from the mic's +5v to the mic's GND with the voltage from the flow meters' combined pulses to the USB's GND.
I came up with this schematic:
http://www.digikey.com/schemeit/#1fwi
I got the parts in yesterday and it put it together. It did not work.
The R-2R seemed to work fine, reading the voltage between the R-2R output and the USB's GND gave me +0.02v when neither flow meters where on, +1.95v when flow meter 2 was on, and +3.24v when both were on.
However, reading between the op-amp's OUT and the mic's ground gives me -1.2v.
(forgot to mention that I got +0.95v when only flow meter 1 was on)
 
4:39 PM
@Mike Why is the op-amp output shorted to ground? And why is the op-amp positive supply not connected to a constant voltage source?
 
@ThePhoton Because I am guessing. I am very new to all this.
 
@Mike The V+ of the op-amp should be connected to a positive supply voltage.
The input of the op-amp should be connected to the input pins of the op-amp.
 
@ThePhoton ok so V+ should be connected directly to the USB's +5v
 
@Mike Also, read this before you continue:
134
Q: Rules and guidelines for drawing good schematics

Olin LathropWe see a lot of poorly drawn schematics here. A few times people have actually asked for critiques of their schematics. This question is intended as a single repository on schematic drawing rules and guidelines we can point people to. So the questions is, what do you think are rules and guidel...

 
@ThePhoton Sorry, I did my best with the schematic. I'll give that a read.
@ThePhoton Well I seemed to do OK on some of the points, others I fear my lack of understanding some of the basic concepts leads to my poor schematic.
 
4:49 PM
@Mike Mainly the way you have your voltage source connected makes it really hard to read the schematic.
 
@ThePhoton Hmm, OK. I'll see what I can do.
 
Make one most-positive rail across the top of the drawing, and one most-negative (0 in this case) voltage rail across the bottom. In your drawing, the closest net to the top is actually the most negative supply.
You could also just use ground symbols instead of drawing connections between all the ground pins.
 
@ThePhoton Gotcha
 
Putting supply signals upside-down is like trying to talk like Yoda in a work environment ;)
5
 
@W5VO Perfect analogy
 
5:06 PM
@W5VO Haha I never knew
OK, I updated it:
http://www.digikey.com/schemeit/#1fwi
Any better?
 
@Mike Much better. I assume V2 should actually be some kind of connector, though.
That part of your circuit is actually wrong. The output of the op-amp should be connected direcly to the inverting input. And also connected to the connector.
 
@ThePhoton err, like that?
 
Except connect the connector ground to ground, not to the same signal as the center pin.
Also, I haven't worked with a pc mic port, before, but according to this
there are three contacts, not two.
The +5V is not the same contact as the center (signal) contact.
You want to connect the op-amp output to the tip.
Connect the circuit ground to the sleeve.
And don't connect the ring, since you have an alternative source of +5 V.
 
I got confused around this as well. The connector to a tablet (ultimate goal) is a TRRS headset connector like this:
http://cdn.head-fi.org/a/af/af5786d7_head-fi.jpeg
So you have 2 +5Vs for left and right speakers, 1 +5v for mic, and 1 GND
 
5:20 PM
@ThePhoton As far as I know, the mic sits between the mic +5v and the GND. The mic changes the voltage and the sound card reads that.
 
@Mike In that case you need some kind of inductor/capacitor circuit to separate power from the audio signal. Since I don't know the details of how the connector is connected inside the tablet, I can't say exactly what circuit.
 
@ThePhoton damn, ok. I'll see what I can find out.
@ThePhoton Can you tell me what I should search for?
 
@Mike I searched "iphone headphone circuit" and maybe found some relevant stuff.
 
@ThePhoton It's actually an android tablet. Galaxy Note 8 (a freebie I got when I bought something else)
 
This is maybe what you want:
Just a basic ac-coupling capacitor.
Without knowing more, I don't promise it won't blow up your tablet.
 
5:25 PM
@ThePhoton Well, as long as I don't have too high of amperage/voltage I should be OK, right?
 
@Mike True, but I dunno if you know what the max current is. If you get it wrong and you're lucky, you'll just blow up your peripheral circuit.
 
@ThePhoton Damn, well that's a little scary. I'll test with my multimeter first to make sure I don't go over 5v.
@ThePhoton Yea I found this as well: forums.androidcentral.com/samsung-galaxy-s4/…
But first I have to find out what an "ac-coupling capacitor" is :)
 
@Mike That makes it look like you won't blow up your tablet.
But if you pull the signal too low, it will be interpreted as pushing a control button (like "play/pause" or "FWD").
 
@ThePhoton on my PC I was able to write a Java app that could read the raw signal from the mic port. Hopefully I can do the same with the tablet.
Damn, I just don't know enough to go from here.
@ThePhoton But you know what, what I am trying to do is basically the same as one of the credit card readers that attach to the headset port on phones and tables.
I wonder if I can find a schematic of one of those to see how it works.
I found this guy. Would I be able to replace the "Magnetic head" with my flowmeters and R-2R?
http://lekernel.net/scrapbook/old/images/cardreader_schema.png
nm, I still have the problem of not enough amperage...
 
5:52 PM
@ThePhoton Is there a way to simple increase the amperage?
 
@Mike Increase the gain of your op-amp circuit. Instead of just a follower circuit, use a gain of +2 or +10 non-inverting amplifier circuit.
 
@ThePhoton How will that help?
 
Because whatever voltage is produced by the sensor + ladder circuit, will be multiplied by the gain factor before being delivered to the output connector.
If you're happy with the voltage, but your op-amp isn't able to produce enough current to drive the load, then you can get a stronger op-amp, or use a transistor buffer:
 
@ThePhoton The problem is the headset port does not produce enough amperage. If it did, I wouldn't have to use the op-amp at all, right?
 
@Mike You aren't useing the headset power supply, you're using a USB power supply.
 
6:00 PM
@ThePhoton Right, but only because of the amperage problem.
 
It should be able to provide (IIRC) 200 mA without fuss.
@Mike Conservation of energy. You can't squeeze blood from a turnip.
 
@ThePhoton That's what I assumed. But I was hoping that I could somehow use the USB current to increase the amperage of the audio jack's current.
 
@Mike You don't need to. Just power your op-amp from the USB voltage and ignore the voltage supplied by the headphone jack.
 
@ThePhoton Showing my ignorance, but how does the current flow into the mic's GND if it doesn't come from the the mic's +5v?
 
@Mike It flows from the op-amp output through the signal pin to the tablet. Into the receiver circuit of the tablet, to ground on the tablet. Back through the ground wire to yoru circuit, where you connect it to your circuit's ground node.
 
6:05 PM
@ThePhoton With a TRRS headset port (like the one on a tablet) you don't have a signal pin (I don't think). Just a mic +5v and a GND.
 
@Mike It looks like the +5 V is fairly high impedance. Your circuit pulls it down to apply a signal.
So you can look at it this way:
current flows from the "mic" pin to the input of your op-amp. Through the op-amp to ground. Back to the ground pin and back to the tablet.
If it was supplying more current, it would be that much harder for your op-amp to pull it down.
 
@ThePhoton I thought the voltage from the flow meters goes to the input of the op-amp?
 
@Mike Yes, but that has nothing to do with the +5 V of the mic connector. Your op-amp is buffering one from the other.
 
(You should be able to edit and save that)
 
@Mike Not without making an account.
 
6:10 PM
ugh, dumb.
Is what I have correct?
 
@Mike I think it will work and not blow anything up. I'm not clear on how much current the op-amp needs to sink in order to drive the output, so not sure how to select an opamp.
 
@ThePhoton I didn't realize that was a factor. I got this one: digikey.com/product-detail/en/0/296-1395-5-ND
 
@Mike It's probably not an issue --- based on the other circuits online you probably don't need more than a mA. But I'm not 100% sure.
Notice your op-amp can't take an input voltage above 3.5 V when Vcc is 5 V. Not sure if that is a problem.
 
@ThePhoton Did not notice that
OK, got it wired up.
Reading between GND and the GND pin on the headset jack I get +1.88V
 
@Mike You should have them connected together with a wire.
 
6:19 PM
the output from the R-2R and the + input is 3.24V
 
That's what it means when you put the ground symbol connected to the connector in your schematic.
@Mike Should be okay, but I don't know what kind of signal your sensors are making.
 
@ThePhoton Right. But I was guessing that the current flowing into the GND pin of the audio jack is what we want to measure.
 
@Mike Not sure why you'd measure that.
 
@ThePhoton That's what the sound card reads, right?
 
@Mike I would expect it to read the voltage on the "mic" pin. The ground pin is common between the mic and two speakers, so it would be a pain to sort out the mic signal from the speaker signals on that pin.
 
6:23 PM
Looks like I get the same reading between the mic pin and the op-amp output
 
I'm going to be out for a bit.
 
@ThePhoton Thanks for all your help!
I'll just leave this here:
So, when both flow meters are on (+5v from the pulse pin) I read +1.39V. When only flow meter 1 is connected: +2.15V. Only flow meter 2: +2.64V. Neither: 5.14V.
 
morning
 
@jippie Howdy
@ThePhoton It looks like the op-amp inverts the voltage. I was expecting +3.75V when both were on and +0V when both were off.
 
7:04 PM
whats wrong with you guys? Since days I leave you alone for a few hours and you all produce so much text! ^^
 
Only 'cause I need so much explained to me :P
 
@W5VO But listen people will, if intelligent things you say.
 
Can anyone explain to me what it means when an op-amp "sinks" a current?
 
sinking means current flows to there
like, you know, water analogy. kitchen sink.
 
@Mike Sink - the current flows into the OpAmp input. Source - current flows out of the OpAmp input.
 
7:18 PM
anyone use avr and can tell me if there is a automatic way to check if my pointer is to prog mem or data mem?
 
in C?
 
@Mike This has only to do with current direction (sign). Ideal OpAmp rules apply the same.
 
@PlasmaHH yes
 
@EwokNightmares I dont know much bout avr architecture, just that its harvard, and in C, you invoke UB anyways when converting between function and data pointers, so the type should tell you... in a lot of harvard architectures you can not tell by the value alon, so I dont know about avr specifically
 
So I have this circuit:
http://www.digikey.com/schemeit/#1fwi

The + Input on the op amp is +3.24v but I am reading +1.39V from the headset jack to the op-amp input. Shouldn't it also be +3.24V? I thought that is what a voltage follower did.
 
7:23 PM
@PlasmaHH thanks. think I'm going to keep track of it myself
 
@EwokNightmares are you trying to store function pointers in void*?
 
@PlasmaHH i'm storing pointers to data structures in both RAM and FLASH with different memory spaces
the function the data structure is given to must decide if the pointer is to a flash location or a ram location because it uses functions to read off flash
 
@EwokNightmares you seem to be doing weird things... just make sure that when your code depends on sizeof(void*) >= sizeof((void)(*)(void)) that it actually holds true for your architecture. there are many where this is not the case.
 
Actually, I think it makes sense... the headset jack provides +5.16V, the output of the op-amp is -3.77V. 5.16V - 3.77V = +1.39V.
 
@PlasmaHH I am drawing sprites on a display and the sprite must be created on the fly and stored into RAM if it is a text, and if it is a static icon/image then it is already existing in FLASH as a static sprite and accessed with flash read calls.
i have a sprite stack that has mixed sprites of both text and image
so the pointers are sitting in that stack and I decide what kind it is
 
7:31 PM
@EwokNightmares do you have the possibility to mmap flash memory into the data space?
 
@PlasmaHH perhaps but if so it is far advanced for me to attempt
I just know the avr workaround for harvard is to use program space macros
 
@PlasmaHH chat used to be pretty much always really busy a while ago.
 
@jippie so I came too late? darn.. has been quiet the last weeks...
 
@PlasmaHH probably a year, maybe a year and a half late
@PlasmaHH I'm happy to see it is getting busier again lately.
 
story of my life...
btw. using 5000µF/300V works fine for welding copper to pliers...
 
7:37 PM
@PlasmaHH picture or it didn't happen.
 
already ripped it of, I want to finish this thing ...
its a good indicator for knowing if your wife still cares about you when after the bang you hear a "honey, are you still alive?"
 
@PlasmaHH so much for a good weld if you can rip it of just like that.
 
not much contact surface I guess. and I have no idea how good copper is supposed to attach to whatever steel that thing is made of.
 
@PlasmaHH With a loud bang, the only thing that happens here are the cats that flee in a small space.
 
hehe. here they both do it too, but after a minute or so the older one is so curious and peeks into my door
 
7:46 PM
@PlasmaHH ... or, your chemistry got rusty.
 
@NickAlexeev that definetly too, and the pliers too ^^
good ones from my grandfather with 3kV insulation grips... or whatever they considered 3kV in the 50s ...
 
nice one
 
it compensates for time dilation between signals?
 
@jippie I was hoping for one with gravity wave detection built in. not this time. So I will wait for the next one :/
 
7:58 PM
@EwokNightmares First try to figure out yourself what it does. I'll explain it this thursday if you couldn't.
 
isn't "a patented electromechanical gravitational field sensor " a fancy word for accelerometer?
 
do accelerometers need to be patented?
 
they spend 9 days with it upside down and find the difference in drift and make a calibration factor for that and then detect when it is upside down to swap the factor
 
8:47 PM
Thanks to you guys, I got my flow meter signals mixed and can read them from my mic port!
I am guessing this has something to do with the sound card, but the pulses act weird. The flow meters have an off and on state so I expected to see a square wave.
It looks like something in the sound card is pulling them down.
It also causes the amplitude of the waves to decrease somewhat as the pulse rate increases.
 
@Mike Somewhere there is ac coupling (high-pass filtering) with too high a cut-off.
 
@ThePhoton No idea what that means, sorry.
 
@Mike There is a capacitor in series with your signal path, and the value is too low.
 
@ThePhoton Anything I can do about it?
It would be easier if the flowmeters sent a single pulse instead of switching state. Is there a way to do this?
Or, if the voltage oscillated instead of remaining constant.
 
9:03 PM
@Mike how do you mix them? I missed the discussion
 
I used an R-2R:
http://www.digikey.com/schemeit/#1fwi
@jippie An op-amp allows me to use power from a USB port to control the current for the audio-jack.
 
@Mike smart solution
 
@jippie Credit goes to W5VO and The Photon
 
@Mike You could use an R-3R network and take the credit yourself ;o)
 
@jippie haha woahhhh
Is there any component that can turn a change of start (e.g. from 0v to 5v or 5v to 0v) into a single pulse?
 
9:09 PM
@Mike are you trying to use sound card input as makeshift oscilloscope? it is heavily ac coupled, no chance for square waves
 
@PlasmaHH Kind of. I want to be able to read the pulses from my flow meters.
 
@PlasmaHH @Mike could use a capacitor in parallel with a resistor in the feedback line of the opamp to compensate the AC coupling somewhat.
 
The problem is, they don't send out a single pulse like I thought. They change state (switch from 0v to 5v) as the wheel turns.
 
I think it could be solved in hardware to make the analog signal easier to process, but then you have more complex hardware to worry about.
 
@Mike what about converting them to sine waves of different frequencies and modulate them?
 
9:13 PM
@PlasmaHH That sounds like it could work.
would have to use a FFT or something to figure out which frequency was present?
@PlasmaHH I have no idea how I would convert them to sine waves, however.
 
yep, nothing too fancy for software to do
 
or you frame both signals with a multiplexter. As long as you have some sort of frame to sync to, you can subsequently sample both signals
 
I have no idea how the signals look like, so hard to tell... guess you dont have a scope at hand?
 
@PlasmaHH Nope, sorry. I want to get one actually. Any good suggestions?
 
@Mike I just ordered a rigol DS1054Z it seems a decent entry level one
 
9:16 PM
8 bit mux, 5 bits define a frame to sync to, 2 bit for the actual signal from the sensor and one bit for parity (= removing DC).
 
I can tell you that the voltage in the pulse pin from the flow meter switches from 0v to 5v as the wheel rotates.
@jippie I have no idea what this is :(
 
@Mike it is brilliant
 
@jippie Haha I'll take your word for it.
 
but as mentioned before, it complicates the input circuitry
 
Well, before we move forward, does anyone know of a way I could reliably pull out the pulses from the combined wave? It looks too noisy to me:
 
9:18 PM
time for bed.
 
 
@Mike calculate delta x(t) - x(t-1)
differentiate
the only thing you are interested in is the heigt of the edges and its timing
differentiate, followed by a windowing comparator like stage.
 
But the pulses overlap so the edges appear all over.
 
but the edges have specific heights.
unless every now and then pulses from two sensors are exactly at the same time.
You want to calculate the difference in amplitude between the current sample and the previous sample
if that difference is too low it is 'noise'
if the difference is medium it is a pulse from sensor #2
if the difference is high, it is a pulse from sensor #1
anyways, time for bed form me
 
some times it's tiny and sometimes it's huge
 
9:23 PM
enjoy your evening
 
gnight
 
@Mike do some statistics analysis, see what that comes up with.
night
 
I think I was goign down this route before. I have these timers but I don't remember what I was going to do with them:
http://www.mouser.com/ProductDetail/Texas-Instruments/NE556N/?qs=gb35HGp1gQKUkn%252b6zgU6RA%3d%3d&gclid=CPeurI_E08QCFQgxaQodYFIA2w

http://www.mouser.com/ProductDetail/Texas-Instruments/NE555P/?qs=rkhjVJ6%2f3EIf4CWgjIKuKQ%3d%3d&gclid=CNLc8qXE08QCFYNAaQodqDUAvg
 
you wanted to give them to me
 
@PlasmaHH Haha they are $0.50
 
9:31 PM
I have children, I am on a budget always ^^
btw I have not even looked at the links...
 
@PlasmaHH Haha I only have a 13mo old, so I can still spend a dollar here and there.
I remember read about about using 555 timers to generate a sine wave. Looking into that again.
 
more like square waves... maybe you wanted to use them as schmitt triggers?
I have ~50 555 lying around here... I needed a few and the total for 50 was less than the total for 10 ... so I ordered a bit more
if it wasnt offtopci I would post a "what fun things to do with 555" ...
olin would probably tell something like throw them away..
 
@PlasmaHH I don't know. I really don't know what I am doing with this stuff. I am just trying to google my way through this.
 
trying to understand some things onthe way would be beneficial
 
@PlasmaHH I defiantly trying to learn as much as I can. It's just very difficult when I have no foundation at all.
@PlasmaHH I've spent over a month on this now. At this point I really just want to get the stupid thing done lol
 
9:38 PM
sometimes backing away and reading some introductionary book is the right way
brb nose bleedin
 
9:50 PM
what a mess...
@Mike anyways, do you have any deadline or just a hobby project?
 
@PlasmaHH Just a hobby. Part of my kegerator. I want to be able to know the beer flow through the lines and have a little graphical interface.
 
@Mike then you probably have the time to step back and read a good book. think of it as if you want to build a foldable table, buy some expensive rich carpenters toolkit, but have no idea what the tools are other than the hammer and screwdriver. go through the toolbox manual, read about what the tools are and when to use them and for what.
 
@PlasmaHH tbh, I really don't have any desire to learn a bunch about EE. I just want to get this stupid thing done :P. I don't want to get the expensive toolkit, I want to go to Ikea
 
tz tz tz ;) the problem I have with ikea is that it never fits so I have to go to my carpenters toolkit and...
 
Exactly. I am considering just buying one of these, but I hate it because it is wayyyyyyy more hardware than I need for something so simple.
http://store.arduino.cc/product/A000069
But, I don't know how to use my carpenter's toolkit so that ugly Ikea furniture may have to do.
@PlasmaHH Here's a smaller cheaper version: sparkfun.com/products/12633
 

« first day (1615 days earlier)      last day (3315 days later) »