Go to Post I was thinking (dangerous I know) - EricH [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 10-02-2003, 20:32
Rickertsen2 Rickertsen2 is offline
Umm Errr...
None #1139 (Chamblee Gear Grinders)
Team Role: Alumni
 
Join Date: Dec 2002
Rookie Year: 2002
Location: ATL
Posts: 1,421
Rickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant future
Send a message via AIM to Rickertsen2 Send a message via Yahoo to Rickertsen2
Pbasic 2.5 syntax

does anybody know where i can find a pbasic 2.5 language reference. I can't find it on the parallax website! help!
__________________
1139 Alumni
  #2   Spotlight this post!  
Unread 10-02-2003, 20:51
FotoPlasma FotoPlasma is offline
\: |
no team
 
Join Date: Jul 2001
Rookie Year: 2001
Location: San Jose
Posts: 1,900
FotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond reputeFotoPlasma has a reputation beyond repute
Send a message via AIM to FotoPlasma
http://www.chiefdelphi.com/forums/pa...le&paperid=165
__________________
I played hacky sack with Andy Baker.

2001-2004: Team 258, The Sea Dawgs
2005: Team 1693, The Robo Lobos
  #3   Spotlight this post!  
Unread 10-02-2003, 20:54
rust710's Avatar
rust710 rust710 is offline
Registered User
#0862 (Lightning Robotics)
 
Join Date: Dec 2002
Location: Canton, MI
Posts: 103
rust710 is an unknown quantity at this point
Send a message via AIM to rust710
I don't think a full 2.5 code referance exsists. The only thing aviable is a PDF file included in the beta version that has the new syntax features. It should C:\Program Files\Parallax Inc\Stamp Editor v2.0 Beta 1\PBASIC Editor 2.0 Beta1.pdf. There is also a short cut in Start Menu->Programs->Parallax Inc->Stamp Editor 2.0 Beta 1->PBASIC Editor 2.0 Beta1.pdf.

Hope that helps.

<edit> Guess I was wrong. Oh well.</edit>
__________________
Andrew Radamis
Programmer on 862
info@lightingrobotics.com
  #4   Spotlight this post!  
Unread 10-02-2003, 21:50
Rickertsen2 Rickertsen2 is offline
Umm Errr...
None #1139 (Chamblee Gear Grinders)
Team Role: Alumni
 
Join Date: Dec 2002
Rookie Year: 2002
Location: ATL
Posts: 1,421
Rickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant future
Send a message via AIM to Rickertsen2 Send a message via Yahoo to Rickertsen2
Does anybody know anything about the new scratchpad syntax. could somebody please explain it to me.
__________________
1139 Alumni
  #5   Spotlight this post!  
Unread 10-02-2003, 22:22
rbayer's Avatar Unsung FIRST Hero
rbayer rbayer is offline
Blood, Sweat, and Code
no team (Teamless Orphan)
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Minnetonka, MN
Posts: 1,087
rbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of light
Send a message via AIM to rbayer
Quote:
Originally posted by Rickertsen2
Does anybody know anything about the new scratchpad syntax. could somebody please explain it to me.
It's the same as the old stuff. If you aren't familiar with that, check out the Stamp manual from Parallax's website. You should look for the PUT and GET commands.
__________________
New C-based RoboEmu2 (code simulator) available at: http://www.robbayer.com/software.php
  #6   Spotlight this post!  
Unread 12-02-2003, 20:36
Rickertsen2 Rickertsen2 is offline
Umm Errr...
None #1139 (Chamblee Gear Grinders)
Team Role: Alumni
 
Join Date: Dec 2002
Rookie Year: 2002
Location: ATL
Posts: 1,421
Rickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant futureRickertsen2 has a brilliant future
Send a message via AIM to Rickertsen2 Send a message via Yahoo to Rickertsen2
sorry this is my first time programming Pbasic. im mainly used to PHP and C++
__________________
1139 Alumni
  #7   Spotlight this post!  
Unread 14-02-2003, 22:57
Raven_Writer's Avatar
Raven_Writer Raven_Writer is offline
2004 Detroit & Pittsburgh Winners
AKA: Eric Hansen
FRC #0005 (RoboCards)
Team Role: Mentor
 
Join Date: Jan 2003
Rookie Year: 2002
Location: Melvindale
Posts: 1,549
Raven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really nice
Send a message via ICQ to Raven_Writer Send a message via AIM to Raven_Writer Send a message via MSN to Raven_Writer Send a message via Yahoo to Raven_Writer
Wasn't there supposed to be syntax highlight? I looked through everything, but nothing for highlighting. I also need a little bit of help. I shouldn't be asking this since I've done a comparision between the syntax, but how is switch used?
__________________
AIM: wisprmylastbreth
EMail: nightskywriter@gmail.com
Y!: synsoflife

"ai yoru ga" -- "Love the nights"
  #8   Spotlight this post!  
Unread 14-02-2003, 23:35
rbayer's Avatar Unsung FIRST Hero
rbayer rbayer is offline
Blood, Sweat, and Code
no team (Teamless Orphan)
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Minnetonka, MN
Posts: 1,087
rbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of light
Send a message via AIM to rbayer
Quote:
Originally posted by Raven_Writer
Wasn't there supposed to be syntax highlight? I looked through everything, but nothing for highlighting. I also need a little bit of help. I shouldn't be asking this since I've done a comparision between the syntax, but how is switch used?
Parallax has said from the beginning that the alpha/beta versions won't have syntax highlighting but the final version will.

There is no "switch" command. There is a SELECT...CASE...ENDSELECT structure, which does the same thing. Ie:

SELECT counter
CASE 0 TO 100
'do stuff
CASE 101 TO 200
'do other stuff
CASE 201 TO 255
'do even more other stuff
CASE ELSE
'stuff to do if none of the previous cases match
ENDSELECT

There's other things you can put after CASE also (such as a single number or an operator and a number (ie >5)), but the above code is the basics.

--Rob
__________________
New C-based RoboEmu2 (code simulator) available at: http://www.robbayer.com/software.php
  #9   Spotlight this post!  
Unread 14-02-2003, 23:37
Raven_Writer's Avatar
Raven_Writer Raven_Writer is offline
2004 Detroit & Pittsburgh Winners
AKA: Eric Hansen
FRC #0005 (RoboCards)
Team Role: Mentor
 
Join Date: Jan 2003
Rookie Year: 2002
Location: Melvindale
Posts: 1,549
Raven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really nice
Send a message via ICQ to Raven_Writer Send a message via AIM to Raven_Writer Send a message via MSN to Raven_Writer Send a message via Yahoo to Raven_Writer
Quote:
Originally posted by rbayer
Parallax has said from the beginning that the alpha/beta versions won't have syntax highlighting but the final version will.

There is no "switch" command. There is a SELECT...CASE...ENDSELECT structure, which does the same thing. Ie:

SELECT counter
CASE 0 TO 100
'do stuff
CASE 101 TO 200
'do other stuff
CASE 201 TO 255
'do even more other stuff
CASE ELSE
'stuff to do if none of the previous cases match
ENDSELECT

There's other things you can put after CASE also (such as a single number or an operator and a number (ie >5)), but the above code is the basics.

--Rob
D'oh...all well, sorry about that. I thought I mixed it up. Can you do "CASE > 4" or just "CASE pw_12 > 4"?
__________________
AIM: wisprmylastbreth
EMail: nightskywriter@gmail.com
Y!: synsoflife

"ai yoru ga" -- "Love the nights"
  #10   Spotlight this post!  
Unread 14-02-2003, 23:44
rbayer's Avatar Unsung FIRST Hero
rbayer rbayer is offline
Blood, Sweat, and Code
no team (Teamless Orphan)
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Minnetonka, MN
Posts: 1,087
rbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of light
Send a message via AIM to rbayer
Quote:
Originally posted by Raven_Writer
D'oh...all well, sorry about that. I thought I mixed it up. Can you do "CASE > 4" or just "CASE pw_12 > 4"?
The first one is legal (CASE >4). The second is not legal syntax. Here's a good way to thing of the operators: imagine taking the SELECT variable/expression (from SELECT expr) and putting it immediately in front of the thing after CASE. ie
SELECT p1_y
CASE <127
...
can be thought of as an if with predicate p1_y<127.
__________________
New C-based RoboEmu2 (code simulator) available at: http://www.robbayer.com/software.php
  #11   Spotlight this post!  
Unread 15-02-2003, 08:56
Raven_Writer's Avatar
Raven_Writer Raven_Writer is offline
2004 Detroit & Pittsburgh Winners
AKA: Eric Hansen
FRC #0005 (RoboCards)
Team Role: Mentor
 
Join Date: Jan 2003
Rookie Year: 2002
Location: Melvindale
Posts: 1,549
Raven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really niceRaven_Writer is just really nice
Send a message via ICQ to Raven_Writer Send a message via AIM to Raven_Writer Send a message via MSN to Raven_Writer Send a message via Yahoo to Raven_Writer
So, SELECT / CASE is just like a easier IF/THEN statement in a way....nifty.
__________________
AIM: wisprmylastbreth
EMail: nightskywriter@gmail.com
Y!: synsoflife

"ai yoru ga" -- "Love the nights"
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PBASIC language syntax WizardOfAz Programming 14 30-04-2003 10:23
PBasic 2.5 vs. 2.0 Anthony Kesich Programming 6 09-02-2003 22:06
Broken PBASIC 2.5 Complier? Mike Yan Programming 12 01-02-2003 09:11
RoboEmu 1.09 (supports PBASIC 2.5) rbayer Programming 22 21-01-2003 17:22
PBASIC 2.5 answer from Parallax JasonS Programming 6 07-01-2003 19:21


All times are GMT -5. The time now is 22:44.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi