NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.
Support Forum » Unexpected Symbol in the Code? ERROR problem
December 25, 2011 by wadaltmon |
I set up the temperature sensor code exactly as it said in the tutorial, and went back and checked it to make sure it was correct. It gave me loads of errors on the command prompt after the "make" command was entered. However, when I put two "{" before the first void and two "}" after the end of the code, there were only two errorr left. One only occured once, another occurred many times in the code. The first one said "17:error:expected identifier or '(' expected before '{' " Next one, which came up many times in one "make" command entry, said: "error: stray '246' in program" Can anyone tell me the solution to these problems? Regards, Dalton |
---|---|
December 26, 2011 by Rick_S |
Which tempsensor code are you using? The correct file should require NO changes to run. The only thing that is required to change is the makefile to configure it to your specific system. The program istelf is correct. Now, with that in mind, there are two tempsensor folders tempsensor and tempsensor_edu. Make sure you are in the folder tempsensor. The files in tempsensor_edu are incomplete and are there for people who want to try to write their own code rather than using the pre-written files. This can be a learning challange but can also be a good learning stepping stone. Especially since the completed program is there for reference. If you are trying to compile the program in tempsensor and getting errors, then there is most likely something else wrong. You should revert the code back to it's original state (re-download if needed). Make sure when you unzip the file that you Keep the folder structure intact. This is important as the makefile references files that are not in the tempsensor folder and it has to know where they are. If you still are having problems, post a screenshot of your errors and it will help us better diagnose what is going on. Rick |
December 26, 2011 by wadaltmon |
Hi Rick, I was using the tempsensor_edu folder to file in my code. Is the makefile itself incomplete? I was typing in the code as I followed the guide. No, I was not using the original tempsensor folder in my coding. Perhaps I should check it over with that one. Thank you, Dalton |
December 26, 2011 by Rick_S |
I'm pretty sure the Makefile is standard in that folder. The only thing you should have to do with it is edit the communication settings per the guide which you will have to do for the full tempsensor folder as well. Rick |
Please log in to post a reply.
Did you know that a flyback diode is important when driving a motor or any inductive load? Learn more...
|