Poll
Question: How can to input the sum of resistances from a circuit.
 How can to input the sum of resistances from a circuit. 0 (0%) resistance for input on arduino 0 (0%)
Total Voters: 0

 Pages: [1]   Go Down
 Author Topic: resistance for input on arduino  (Read 925 times) 0 Members and 1 Guest are viewing this topic.
Offline
Newbie
Karma: 0
Posts: 2
 « on: June 13, 2011, 08:07:33 am » Bigger Smaller Reset

Hi guys,
I have a problem with arduino mega ,
I want to measure the consumption of this circuit and I want to measure the resistance to find the watts
according to the formula W=V^2/R...

For example, when I press a switch not to see consumption 0 watts else if I press all the switches together
to see consumption 100mW..

I reached a point with this example >>>http://arduino.cc/en/Tutorial/AnalogInput<<<< but not potentiometer
I want to have the buttons.

with analogRead() function that read values ​​from 0-1023 expect when I press a button to reduce the values but
because the circuit has little resistance does not decrease much, going from 1023 to 1022 with all switches closed,
so I can not measure watts with the scale

for example, when I press one button to decrease from 1023 to 1000.
when I press two button to decrease from 1000 to 980.
when I press three button to decrease from 980 to 950 etc..
I do not care about the exact I just want to reduce the values when I press buttons

How to fix it;
Is there a function that will help me;
You know another way (again with resistance, not current sensor)
Tell me something!!!

Thanks guys and sorry for my bad english.
 Logged

Offline
Newbie
Karma: 0
Posts: 2
 « Reply #1 on: June 13, 2011, 08:15:40 am » Bigger Smaller Reset

4x 200 Ohm
1x 7 Kohm (9v decrese to 5-- for input to arduino
 circuit.jpg (82.72 KB, 768x480 - viewed 22 times.) Logged

Central MN, USA
Offline
Tesla Member
Karma: 72
Posts: 7171
Phi_prompt, phi_interfaces, phi-2 shields, phi-panels
 « Reply #2 on: June 22, 2011, 09:48:52 pm » Bigger Smaller Reset

Don't do it man. If your MEGA has teeth they'd be biting your hand right now. You have fed 9V to your MEGA where you should feed up to 5V. Stop!!!

Also the resistors for the LEDs are too small.
 Logged

 Pages: [1]   Go Up