Pages: 1 2 3 [4]   Go Down
Author Topic: analog input alters voltage... doesn't read properly  (Read 4832 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 25
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


You have to connect the CA to +5, and NO, doing so will NOT "overvolt and damage them" - unless you don't use a resistor!
When the LED is ON it's forward voltage is "3.5V"
So, the balance of the 5V will be across the resistor - 1.5V
That 1.5V across the resistor will determine the LED current
1.5V / 100Ω = 15mA


PERFECT i am starting to understand! Thank you for this confirmation, i had just read this:

http://answers.yahoo.com/question/index?qid=20100308024927AAg0UQI

And now I am going to put a 102 ohm resistor (brown - black - red - gold) [right ? hehe] on each ground wire for this display.



zzzz.. think i read this wrong- 4band vs 5 band resistors :/  guess brown black red gold is actually 1000 ohms lol

Looks like ill have to get to radioshack for some 80-100 ohm resistors...

How can I test that the resistors are working? Should i just use a spare LED? I don't want to fry a segment on this display...
« Last Edit: May 02, 2013, 07:54:40 pm by pcguru000 » Logged

Offline Offline
Edison Member
*
Karma: 64
Posts: 2465
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Get 100Ω (brown-black-brown) resistors - or my head will explode.

"How can I test that the resistors are working?"
The only way to KNOW is with a voltmeter.
+5 to CA, one lead of one resistor to any segment (cathode) with the other lead to Gnd.
There will be approx 1.5V across that resistor.

If the "spare" LED is a blue LED, you can use that.
If the "spare" LED is another colour then it will have a different forward voltage and skew the results.
Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Newbie
*
Karma: 0
Posts: 25
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Get 100Ω (brown-black-brown) resistors - or my head will explode.

"How can I test that the resistors are working?"
The only way to KNOW is with a voltmeter.
+5 to CA, one lead of one resistor to any segment (cathode) with the other lead to Gnd.
There will be approx 1.5V across that resistor.

If the "spare" LED is a blue LED, you can use that.
If the "spare" LED is another colour then it will have a different forward voltage and skew the results.


Sounds good thanks- yeah I was expecting that the spare would have to be a blue one, and I figured it'd have to be tested with voltmeter.

I'll check this out tomorrow. THANK YOU everyone.

Hopefully this solves the issues I was having initially w/ the analog input voltage being skewed once plugged into my bike.
Logged

UK
Offline Offline
Tesla Member
***
Karma: 104
Posts: 6347
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks. I had overlooked the fact that you can feed a small water pipe from a large one.

...R

Power transfer involves maximizing the product of voltage and current in the load. When you do the maths it turns out the maximum transfer is when the output impedance of one device matches the input impedance of the other. However, here we do not want to transfer power but transfer voltage. To do this requires that the output impedance be very small compared to the input impedance. With an arduino the input impedance is very high and if you supply it from an output impedance of 10K then you get virtually perfect voltage transfer.

The point about an impedance is that in most cases the value is frequency dependent so when quoting an impedance you should also specify the frequency where that impedance applies.

Logged

Offline Offline
Edison Member
*
Karma: 64
Posts: 2465
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hopefully this solves the issues I was having initially w/ the analog input voltage being skewed once plugged into my bike.

The analog trouble's solution will be changing the source/"Vin" to 9V.
Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Newbie
*
Karma: 0
Posts: 25
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thank you everyone!!! - I uploaded a updated version of my diagram to the OP. And also- check this out:



I am going to tweak the software a bit more to just stay blank in between gear shifts.

Other than that- this is ROCK solid, displays my gears accurately even at high RPMs.

Current code for those interested- http://pastebin.com/iGiK8iQy
« Last Edit: May 03, 2013, 09:22:46 pm by pcguru000 » Logged

Offline Offline
Edison Member
*
Karma: 64
Posts: 2465
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Glory!
Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

UK
Offline Offline
Tesla Member
***
Karma: 104
Posts: 6347
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Makes you wonder why they are not standard equipment.

...R
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 27
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

"why not standard equipment"
patent it and sell to bike mfr.
 Seriously, patentability is a squirrely thing.
message me for that strategy. You can get "pat pending" for $100. Move it onto a chip and approach a mfr
with a "black box." Hide the code in chip memory.

BTW, if you ride that thing - I hate to pee in the punch-bowl, but if you get in a serious accident, you can adapt the gizmo
to a wheel chair shifter.

Nice work though, all you had to do was tolerate some abuse.

AND - here is a plain english explanation of why an led needs a resistor.
An led has something called a "band-gap." It is like a dam holding water back. If you raise the water too far, (over voltage)
it will torrent over the dam and cause a tidal wave. A resistor limits the current flow, like a constriction in a pipe when you have the faucet all the way on.

An attempt...I'm sure will provoke laughs.


Logged

Pages: 1 2 3 [4]   Go Up
Jump to: