Arduino Forum

Using Arduino => Installation & Troubleshooting => Topic started by: somewhereinusa on Dec 22, 2013, 02:18 pm

Title: compiling problem
Post by: somewhereinusa on Dec 22, 2013, 02:18 pm
I am new to Arduino, and coding. I have some projects I am working on and in the process I have searched the web and found similar projects to see how people go about coding things.  I have download many sketches that won't compile, even when the hardware is the same as mine. Projects that I can see a video of it actually working. I get lots of error messages like " 'Serial' was not declared in this scope" or " error: expected `}' at end of input" or  " a function-definition is not allowed here before '{' token" . I have also found things that I want to build and had the same problem.  If there is a problem with the code, which to me, it looks like there is, how did the OP get his project to work?

Thanks,
Dick
Title: Re: compiling problem
Post by: JimboZA on Dec 22, 2013, 02:26 pm
Just a guess, but they're probably not very good at version control. Maybe they save, compile fails or logic not good, make changes, it works, forget to save, they post the details of their success, attaching old (bad) version.
Title: Re: compiling problem
Post by: AWOL on Dec 22, 2013, 11:12 pm
Quote
I have download many sketches that won't compile, even when the hardware is the same as mine.

Yeah, I've seen a lot of stuff like that on Instructables too.
Title: Re: compiling problem
Post by: el_supremo on Dec 22, 2013, 11:21 pm
A lot of the code and videos that you can find on the net are quite old. They may have compiled without error on Arduino 022, for example, but not with 1.0.5

Pete