Shop OBEX P1 Docs P2 Docs Learn Events
Getting Syntax error when I use word PIN — Parallax Forums

Getting Syntax error when I use word PIN

Ezra243Ezra243 Posts: 5
edited 2006-04-29 12:59 in BASIC Stamp
Newbie here.· Just starting with StampWorks Experiment Kit.· Installed latest editor v2.2.5.·
When I enter code for the first experiment:

'
[noparse][[/noparse] I/O Definitions ]

AlarmLed····· PIN····· 0··············· ' LED on P0

When I run the syntax checker, I get the message:

Expected ':' or end-of-line

and the word PIN is highlighted in blue

It's like it doesn't like the keyword PIN.

It seems that I can avoid using I/O definitions of the type PIN, but that is not in keeping with the "Writing Code like a PRO" style conventions.

What am I doing wrong?

Comments

  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-04-29 12:58
    Ezra -

    Add the following line to the beginning of your program:

    '{$PBASIC 2.5}

    (note the curley brackets) and that will take care of it. You can also use one of the short-cut buttons at the top of the PBASIC Editor interface to do the same thing. If you mouse-over each button, you will see which one to use. The PIN command was a PBASIC 2.5 addition.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • NewzedNewzed Posts: 2,503
    edited 2006-04-29 12:59
    On the tool bar, click Directive, then select PBasic 2.5.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sid Weaver
    Do you have a Stamp Tester yet?
    http://hometown.aol.com/newzed/index.html

    ·
Sign In or Register to comment.