Arduino and Parallax GPS

Hey everybody, I am just starting to learn about microcontrollers for my senior project at my school. Right now, I have a Arduino Diecimila and a Parallax GPS to get me started. I saw the tutorial at the arduino.cc website and I connected the gps to a breadboard and to the arduino in the same fashion. When I uploaded that code, I got the errors:

o: In function loop': C:\Documents and Settings\Drew\My Documents\Arduino\sketch_081112c\applet/sketch_081112c.cpp:36: undefined reference to printByte'

Couldn't determine program size: C:\Documents and Settings\Drew\My Documents\arduino-0012-win\arduino-0012\hardware/tools/avr/bin/avr-size: 'C:\Documents and Settings\Drew\My Documents\Arduino\sketch_081112c\applet\sketch_081112c.hex': No such file

avrdude: can't open input file C:\Documents and Settings\Drew\My Documents\Arduino\sketch_081112c\applet\sketch_081112c.hex: No such file or directory
avrdude: write to file 'C:\Documents and Settings\Drew\My Documents\Arduino\sketch_081112c\applet\sketch_081112c.hex' failed

I have been searching on google for a while and I can't come up with anything. The Arduino software is 0012 Alpha and my computer is running Windows XP. Does anybody have any ideas? Thanks.

JeepFreak--

I think I would try changing the line

printByte(byteGPS);

to

Serial.print(byteGPS, BYTE);

I think that code is relying on an undocumented version 11 feature that went away.

Mikal

Hi,

Replace the printByte command with the new equivalent in version 012: serialWrite
Don't use Serial.print

Before you upload the programm to the board, disconnect the pins 0 and 1, because Arduino uses them to upload your code.
After uploading connect them again ( remember to first unplug Arduino from power) and your code should run.

Replace the printByte command with the new equivalent in version 012: serialWrite
Don't use Serial.print

Why? Serial.print(x, BYTE) calls serialWrite, but Serial.print is documented and I don't think serialWrite is.

Mikal

In my case, I really don't want to lose the Diecimila host connection to talk with the Serial stream from the Parallax GPS. So far, the Arduino Software.Serial library work good for me. (It was designed to allow RS232 type serial communication on non-uart pins using the Bit-Bang Method)

This does mean you need to write code in such a way that you don't "miss" incoming data... but it's not that hard.

Thanks for the help, this worked:

printByte(byteGPS);

to

Serial.print(byteGPS, BYTE);