Show Posts
Pages: 1 ... 37 38 [39] 40 41 ... 267
571  Using Arduino / Sensors / Re: LM35 not showing expected temperature. on: May 30, 2014, 12:44:51 pm
it is neither logical nor a good practice to write analogRead (5) instead of analogRead (A5)

That may be true, but it's not what you said earlier....

Quote
You have to write :
analogRead(A1) ;

.... which is not true.

572  Using Arduino / Sensors / Re: LM35 not showing expected temperature. on: May 30, 2014, 10:39:05 am
analogRead(A1) ;

My working code is:

Code:
// read the temp
        rawVal=analogRead(5);//Connect LM35 on Analog 5
        temp=(500 * rawVal) /1024;
573  Using Arduino / Sensors / Re: LM35 not showing expected temperature. on: May 30, 2014, 10:00:27 am
Then perhaps it's warmer than you think  smiley-grin

And you have it powered from the 5v? Might be an idea to post a circuit diagram and even a photo of the setup.
574  Using Arduino / Sensors / Re: LM35 not showing expected temperature. on: May 30, 2014, 09:51:48 am
You sure you're on analog 1?- the first pin is 0.
575  Using Arduino / Motors, Mechanics, and Power / Re: Simple DC Motor Contol? on: May 29, 2014, 12:35:46 pm
You're probably right Mark- I took "external" to mean over and above the Arduino power, ie supplying the motor direct. But it does read more like he means external supply into Arduino, and power to motor from Arduino. As you say, that's folly.
576  Using Arduino / General Electronics / Re: SCR vs saturated transistor as switch on: May 29, 2014, 12:11:11 pm
Thanks for the input guys.

One closing question: the circuit I attached a few posts earlier is going to drain the battery through R1 and the NC Trigger switch. Seems to me it would be better to have an NO switch "above" the gate, so there's no power consumption under normal conditions..

So my question: if I did that would I need a pull-down (>>R1) on the gate to make sure it didn't energise from stray atmospherics? I'm asking this thinking along the lines of an Arduino input needing to be forced one way or the other: is the SCR gate susceptible to stray signals?
577  Using Arduino / Programming Questions / Re: This code fro 2 Servo and 2 motors on: May 29, 2014, 11:05:52 am
The motor speed is controlled by an analogWrite rather than the digitalWrite you are using.

You didn't show your circuit: hopefully you're not driving the motors directly from the Arduino pins but have some transistors in there or an h-bridge driver chip? And don't forget the fly-back diode.

Regarding the servos, don't forget they take a while to get to their destination, so the way you coded it, the second servo gets its command to move before the first one is finished. So you could put a delay between the two servo writes.
578  Using Arduino / General Electronics / Re: SCR vs saturated transistor as switch on: May 29, 2014, 10:04:58 am
Quote
if you switch a DC voltage source with  an SCR, there is no easy way to turn it off again.

Although if - heaven forbid- one was building a a bomb timer, that would actually be the whole point. I hasten to add, I'm not building a bomb.

I found the attached circuit for an alarm- where the lower switch sets it off and of course it stays on even if the perp shuts the window. I've just built exactly that circuit to show my son when he gets in from his shift.
579  Using Arduino / General Electronics / SCR vs saturated transistor as switch on: May 29, 2014, 07:35:10 am
My son's a paramedic / firefighter, studying further in fire engineering with the UK's IFE.

Seems one of his books has an article on timing devices (like in bombs and stuff.... scary), and it talks of an SCR. Knowing that I as his father am all-knowing  smiley-grin he asked me what an SCR is and of course I have nfc. So I Googled it (which is arguably what Hugh should have done in the first place).

It seems to me that an SCR is functionally similar to a saturated transistor. Is that true? It's a diode with a switch line, and is either open or closed, just like a transistor with the base saturated or off.

If (that's true)
{why / how would one choose between the two}
else
{what did I miss?}

TIA,

Jim

EDIT: I guess a key part is that it's a rectifier, so it's a switch which converts AC to DC as well as being a switch. ...

YET MORE EDIT: And perhaps this is the good bit, it stays on even if the gate current dies?
580  Using Arduino / Motors, Mechanics, and Power / Re: Simple DC Motor Contol? on: May 29, 2014, 06:32:28 am
I do use a external battery supply with 6 batteries. I also do connect to GND.

That makes no sense in the light of your original post:

Quote
I made a circuit by connecting the two wires to 5V and GND

581  Using Arduino / Programming Questions / Re: CODE for ESC on: May 29, 2014, 02:46:16 am
So should I wait while it conected ?

No, I think as Robin2 said:

Quote
You will need to read the instructions for your ESC
582  Using Arduino / General Electronics / Re: LM317 voltage regulator R2 is getting very hot? why? on: May 29, 2014, 02:08:31 am
Not difficult at all and as ever, GIYF.

How ironic.... I had to Google what that meant.

583  Using Arduino / Project Guidance / Re: Changing the program on: May 28, 2014, 10:13:39 pm
As AWOL and Henry_Best say it's difficult to give meaningful help in the total absence of any detail, but these tutorials might help. (I say "might", since I have no idea what motor you have or what you want to do.)

This one is very basic. Just switch the pin on and off or PWM it with analogWrite() for speed control.

This uses  293D H-bridge for direction control.

YMMV. E&OE.
584  Using Arduino / General Electronics / Re: I'd like to understand an experience I had on: May 28, 2014, 01:03:48 am

Not to be confused with an aeronautical ground loop in a taildragger...
585  Using Arduino / Programming Questions / Re: Inputting a whole number with a fraction on: May 28, 2014, 12:58:49 am
Quote
Reverse Polish Notation like the old HP calculators

Still the best way.....
Pages: 1 ... 37 38 [39] 40 41 ... 267