Using Arduino board to control Parallax Altimeter Module
Crossways
Posts: 8
I saw a Altimeter module with LCD readout on Hack a Week. I have a Arduino Duemilanove experimenters kit that I am somewhat familiar with, and noticed that the project seemed to provide the needed software for a Arduino, as well ad the BOE.
I purchased the LCD and MS5607 Altimeter Module from Parallax, and downloaded two zip files: Arduino 1.0 Code for the Altimeter Module & Arduino Pre-release Version Code for the Altimeter.
Now the fun begins, and I'm in way over my head. Here are my problems:
1. When I try to open the downloaded zip files using my Arduino Sketch program (I don't know what else to use), the unzipped file: (IntersemaBaro.h) comes in, but the Sketch program states: (27: error, IntersemaBaro.h: No such file or directory)
2. When I try to bring in the other file by double clicking on the zip file: (Altimeter Arduino 10. ino), the Sketch program states: (Processing can only open its own sketches & other files ending in (.pde).
Trying unconventional approaches, I open it in Word then pasted it into the Sketch program along with the earlier (IntersemaBaro.h), I get: (21: error: Arduino.h: No such file or directory). I don't know where Arduino.h comes from.
If there isn't a easy way to program the Arduino board, I'm out of luck. Any ideas would be greatly appreciated.
I purchased the LCD and MS5607 Altimeter Module from Parallax, and downloaded two zip files: Arduino 1.0 Code for the Altimeter Module & Arduino Pre-release Version Code for the Altimeter.
Now the fun begins, and I'm in way over my head. Here are my problems:
1. When I try to open the downloaded zip files using my Arduino Sketch program (I don't know what else to use), the unzipped file: (IntersemaBaro.h) comes in, but the Sketch program states: (27: error, IntersemaBaro.h: No such file or directory)
2. When I try to bring in the other file by double clicking on the zip file: (Altimeter Arduino 10. ino), the Sketch program states: (Processing can only open its own sketches & other files ending in (.pde).
Trying unconventional approaches, I open it in Word then pasted it into the Sketch program along with the earlier (IntersemaBaro.h), I get: (21: error: Arduino.h: No such file or directory). I don't know where Arduino.h comes from.
If there isn't a easy way to program the Arduino board, I'm out of luck. Any ideas would be greatly appreciated.
Comments
Thanks for your help. You may have me 9 miles down the road. I moved both files into my eariler Arduino folder, which has drivers etc., and I was able to call up the (Altimeter Arduino 10.ino) file which was great. Only now I get the message; (C:users\Dave\downloads\ardoino-0018\arduino-018\hardware\arduino\cores\arduino/mai n.cpp:10 undefined reference to 'Loop') I know you're going to tell me I'm a sloppy housekeeper :-)
When I scan the loaded code, I don't see a Loop region. I'm not sure if I need to add the (IntersemaBaro.h) file. I just have the feeling, with your help, I'm really close to having this work.
1. My Arduino software is installed here C:\Documents and Settings\Martin\My Documents\arduino-1.0.1, but that shouldn't be an issue if yours is elsewhere.
2. I downloaded the Arduino sample from http://learn.parallax.com/sites/default/files/content/kickstart/code/Altimeter_Arduino_10.zip and opened the zip file.
3. I extracted the Altimeter_Arduino_10 folder to C:\Documents and Settings\Martin\My Documents\Arduino\Altimeter_Arduino_10
4. I double clicked on Altimeter_Arduino_10.ino and the Arduino IDE loaded. I was able to compile it without a problem. Since I don't own the altimeter module I can't test it.
I hope this helps.
Here's the deal –
1. When I follow your instructions, and double click on the Arduino 10 unzipped file, it opens Arduino Sketch and says - “processing can only open its own Sketches & other files ending in (.pde)”
2. If I double click on the other file (IntersemaBaro.h) it opens in Wordpad and there is a lot of code there. If I take that code and paste it into the Sketch program – when I go to verify/compile, it highlights a line: #include <util/delay.h> Near the bottom is says: (21: error: Arduino.h: No such file or directory).
3. Are both file needed in Sketch?
4. What about the (.pde) file type it keeps asking for?
5. And, the (Arduino.h) file it seem to want?
Any ideas would be helpful.
Let's start here. The two file types are not compatible. You're using a pre-release Arduino IDE (version 0018 is astoundingly ancient), but the example is written for 1.0 and later.
Download the latest version of the IDE, and use that version instead for any files that end with .ino.
The other issues may clear up, or be easier to tackle, once this is done.
-- Gordon
You both hit the nail on the head. I went out and downloaded the latest verison and it compiled without error. I uploaded it, and the Tx/Rx leds blink like crazy, so I know it loaded. It doesn't work, but now at least I know the whole chain works. Thank you both for you comments & Martin for his patience.
I remember something on the Hack a Week video about changing a couple of things in the code, so I'm going back to view that again. I can't thank you enough for the help, now I have a fighting chance.
You will need to select the 'Go Advanced' button that is to the right of the 'Save' button.
EDIT: The 'Prefix' is what you'll need to change.
Paul