about to give up

Im an electrician and have programed many plc's but i cannot understand this code. Is there another way like ladder logic? All youtube help just shows me how to open examples or just start typing crazy words like boolean.

Is there another way like ladder logic?

No.

All youtube help just shows me how to open examples or just start typing crazy words like boolean.

Quit watching TV. Get a book.

Do you have the IDE installed. Have you at least managed to successfully upload the blink example. If you haven't used C before it can be quite a steep learning curve but not insurmountable.

A better method of learning is to come up with a project of your own and then, bit by bit work through each requirement.

If you've managed pic you have the capacity to learn C.

For topics that I never know where to start, I always get a "For Dummies" book. Ridicule them all you want, but they assume nothing and get you going in the right direction. They then point you on to bigger and better things and resources. Been reading them for 25 years and half my bookshelf is yellow.

Knowing very little about Arduino, I picked up a starter Kit and "Arduino for Dummies", probably about $50 total on amazon. I do have a small background in coding (programming), so picking up C++ after 15 years of not touching it wasn't that hard. This book briefly covers programming, but you can find other good resources on the C++ language out there.

One of my earlier programming courses was an Algorithm planning class. While this was in the 90's, we were using punch cards to program our machines. The teacher made us draw out flowcharts (your ladder logic) to plan our programs. We quickly learned that errors in the actual program were a hell of hard thing to diagnose and fix, so we learned to perfect our flowcharts to weed out logic errors.

Use your ladder logic to describe what you want to do, that's what you know. Use a free open source Flow chart program to help you do this. Then try to apply it, piece by piece, to the C++ language. You will quickly find that you will be able to write a good majority of the code just by tackling it in bits and pieces like this. The parts you can't figure out, you can research (here in the forums or other places), and somebody or something will point you in the right direction.

I would also look at your local community college, as they will offer intro to C++ courses. That may be your best bet for learning the basics of the language.

My coding skills aren't that far beyond (if even that) what an intro course would teach, and yet I can easily see the potential power of the Arduino, and it all seems to be within my grasp. My biggest weakness is the electronics side of it. That's this week's project. :)

KenF: If you've managed pic you have the capacity to learn C.

OP said pLc not pIc...

I would recommend C over C++ for a new programmer. C is usually presented with procedural approach while C++ is presented with an object oriented approach. C++ is a super set of C, meaning that anything written in C will run just fine with any C++ compiler.* In the Arduino world there are a few time that C++ pops up, usually in libraries. Any C book will do, even an ancient one. If you do go with C++, pick a book that presents the language in a procedural way first.

*You do need C++ if you are writing libraries.

MrsCrossRoads: *You do need C++ if you are writing libraries.

Not necessarily.

Note to AWOL: The tutorial for writing a library defines functions inside a constructor - a C++ feature. http://arduino.cc/en/Hacking/LibraryTutorial

start here

MrsCrossRoads: Note to AWOL: The tutorial for writing a library defines functions inside a constructor - a C++ feature. http://arduino.cc/en/Hacking/LibraryTutorial

Library != class.

Maybe this Thread planning and implementing a program would help.

...R

JimboZA: OP said pLc not pIc...

Ooops. My eyes are not as good as they once were.

What steps have you taken to learn C++ ?

PLC or ladder logic is a whole different mindset.

programming for the arduino is actually writing code and not just selecting coils and switches.

unfortunately, the Arduino has to be learned from the ground up unless that link to a ladder logic for the Arduino does what you need.

I would offer that at the cost of a brick, you have far surpassed the Arduino in many areas.

first, for under $100, you get relays, free plc software, 8 ins and 6 outs. you can add modules and expand as you need.

The Arudino offers a whole different level of peripherals, so the arduino has a much wider base of things you can do.

but, a simple brick will be UL approved and be designed by EE's who have already figured it out and have added the additional circuitry to make it solid as a brick.

If you are an electrician and want a hobby that will take 100 hours to feel like you can do stuff, then the Arduino would be a great hobby.

if you just need to get the lights working and control pumps and such a Kowo Click will get work done much faster.

When using an Arduino, you have to either piece together parts and then add wires, or design your own circuit board, lay out the parts you need, order it and then solder it together. figure another hobby all in itself.

Looks like the OP has given up.

…R

Robin2: Looks like the OP has given up.

I heard a rumour that he was about to. Guess it wasn't an idle threat after all.

Greensprings: Whats an OP , i fuggure by context clues it is the person asking the question

Original Poster

guess when he found out there were 10 types of people, he could not think in binary, only boolean.....

dave-in-nj: guess when he found out there were 10 types of people, he could not think in binary, only boolean.....

If you haven't learned binary by the time you're a hexager there's realy not much hope.