Ardino CW Beacon Programming Problem

I was told by the people at Projects to ask over here.

I’m trying to build a Cw beacon using an Arduino UNO. I used an existing program used for a Balloon Beacon. I copied the .txt file and saved it as a .pde file.
When I try to open the file wile running Arduino Sketch 0022. I uninstalled Java ver 6 and reinstalled a fresh version off of their site, rebooted and I still have the same thing. I am running a windows 7 64 bit version on a HP HPE510y 6 processor computer, Arduino-0022, Java version 6 (newest ver.) with the exception of windows. I have uninstalled and reinstalled the programs + rebooted the machine. I broke out my laptop (32 bit) running WindowsXP SP3 and tryed that…same thing.

Here’s the program
http://hiwaay.net/~bbrown/keyedcwcode.txt

I get a multitude of Java errors and a blank screen.
Here’s the errors:

Exception in thread “AWT-EventQueue-0” java.lang.ArrayIndexOutOfBoundsException: 0
at processing.app.Sketch.setCurrentCode(Sketch.java:1106)
at processing.app.Sketch.load(Sketch.java:218)
at processing.app.Sketch.(Sketch.java:140)
at processing.app.Editor.handleOpenInternal(Editor.java:2114)
at processing.app.Editor.(Editor.java:308)
at processing.app.Base.handleOpen(Base.java:699)
at processing.app.Base.handleOpen(Base.java:664)
at processing.app.Base.handleOpenPrompt(Base.java:653)
at processing.app.Editor$5.actionPerformed(Editor.java:500)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
at javax.swing.AbstractButton.doClick(AbstractButton.java:357)
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1225)
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:1266)
at java.awt.Component.processMouseEvent(Component.java:6263)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
at java.awt.Component.processEvent(Component.java:6028)
at java.awt.Container.processEvent(Container.java:2041)
at java.awt.Component.dispatchEventImpl(Component.java:4630)
at java.awt.Container.dispatchEventImpl(Container.java:2099)
at java.awt.Component.dispatchEvent(Component.java:4460)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
at java.awt.Container.dispatchEventImpl(Container.java:2085)
at java.awt.Component.dispatchEvent(Component.java:4460)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Any help would be appreciated.

TNX Gary, KF9CM

I don't know, I copied into IDE -0021, compiled with just 1 error

Had to comment out this line, tone being a core command, and which you didn't seem to be using anyway: // int tone;

I found out the problem. Apparently when I saved the code with "Morse code.pde" I got Java errors. When I saved it with just " Morse.pde", it took with no Java errors. Java doesn't like spaces between words when saving.

The IDE does not like spaces as well - sticks in underscores.