analog to digital using an audrino...

is the audrino a better choice?

  • Stay analog

    Votes: 0 0.0%

  • Total voters
    2

Thread Starter

Xjsport95

Joined May 8, 2016
11
so I was using a set of relays to control a linera actuator, it gets a single 12v+ pulse to make it go until it hits a limit switch and stop, when pulsed again it travels in the opposite direction until it hits the limit then stops... A friend told me an audrino would be a better set up, I ordered on and am completely lost... I took a class on c++ years ago and figured it would come back to me but its not. any help would be greatly appreciated... Thanks
 

djsfantasi

Joined Apr 11, 2010
9,237
If that is the extent of your programming knowledge, there will be a learning curve. Until you can understand the simple example programs and can write your own "blink the LED" sketches, controlling your linear actuator won't be possible.

If you do understand programming, the Arduino solution is easy but you'll still need to supplement it with an analog driver for the sctuator.

Using a microcontroller is an excellent skill to have. Some will argue otherwise (there are two camps here that can't agree), but the Arduino is a good start

So, try to understand the LED sample program and try to modify it so that it blinks a pattern. Then, modify it to detect a push button or switch and illuminate the on board LED. Or use an external LED. Basically, learn by taking baby steps.
 

Thread Starter

Xjsport95

Joined May 8, 2016
11
The system I have now works fine. I'm curious if the audrino would prove a better system... I know how the setup I have now works im just stuck on setting up the other one... if it works better that's great, if not I'll stay with what I have now... if the new one doesn't work how I want it to I'm not out much $, plus it wld give me a tool I can learn on
 

OBW0549

Joined Mar 2, 2015
3,566
The system I have now works fine. I'm curious if the audrino would prove a better system... I know how the setup I have now works im just stuck on setting up the other one... if it works better that's great, if not I'll stay with what I have now... if the new one doesn't work how I want it to I'm not out much $, plus it wld give me a tool I can learn on
In what way is an Arduino-based system supposed to be "better" than what you've got now? What will it do that the present system will not? And do you actually need it to do those things?

Keep in mind that an Arduino-based system is not going to do anything until you learn how to program it.
 

Deleted member 115935

Joined Dec 31, 1969
0
Have you installed the arduino tools ?
They are on the arduino.cc web site.

Have look here,

https://www.arduino.cc/en/Guide/HomePage

Arduino is a family of compatible processor boards, and an included tool set ( IDE)
install the off line IDE from the options in the above link,

First start is to get the arduino powered up, and the on board led should flash.
this is the default program 'all' arduinos are sold with.
lovingly called blinky.


From the above link, you will get into the IDE.
Arduino has a slightly strange language if you have C++ ,

so a program to you and me is called a sketch, and the arduino IDE will be very forceful on its file / folder structure.

You will see arduino code has two sections,
the first one runs once on start up ,
its where you put the pin names you want for what pins,
start things like the serial link to talk to the computer et al.

The second bit runs constantly in a loop,
its where you put the actual code,

so something like

turn led on
wait a bit
turn led off
wait a bit

would run for ever, flashing the led on and off.

The actual arduino code is

// the loop routine runs over and over again forever:
void loop() {
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}

there are lots of built in examples and support on the web site,

reading the adc and writing to the dacs is just abut as easy,
with analogRead and analogWrite.

get in and give it a go,

As to why digital or analog.


If a processor can do the job, at a price you want, go digital, it gives you many more options,
 

GopherT

Joined Nov 23, 2012
8,009
The system I have now works fine.
I'm curious if the audrino would prove a better system.
So, you want to invest time and equipment to improve something that works fine while risking that the system is down for some period of time to set up the arduino?

Are you just thinking an arduino will be better just because it is not a relay? Or, do you have a strong desire to learn programming and microcontrollers with hopes of using arduinos in other applications where they are really going to improve something.
 

Deleted member 115935

Joined Dec 31, 1969
0
the original solution is "digital", implemented in relays.

as such, using ladder logic on a plc (avr) would be a natural extension of the original design.
you missed the bit
"If a processor can do the job, at a price you want, go digital, it gives you many more options"
 

Deleted member 115935

Joined Dec 31, 1969
0
The system I have now works fine. I'm curious if the audrino would prove a better system... I know how the setup I have now works im just stuck on setting up the other one... if it works better that's great, if not I'll stay with what I have now... if the new one doesn't work how I want it to I'm not out much $, plus it wld give me a tool I can learn on
Hows it going ?
 
Top