IF..THEN syntax


Closed Thread
Results 1 to 40 of 53

Thread: IF..THEN syntax

Hybrid View

  1. #1
    Join Date
    Oct 2006
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Wow! Have you read John Iovine's book? Well, I got the program from his book "Pic Robotics". Correct me if I'm wrong but I think the <bold>William Gray Walter</bold> whom you're referring to passed away in 1977?

  2. #2
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by scaenix View Post
    Correct me if I'm wrong but I think the <bold>William Gray Walter</bold> whom you're referring to passed away in 1977?
    Right, which would have made it hard to have written something in PBP.
    But he did make the original "Turtle" robot that supposedly John based it on.

    Got the .LST file, and it's worse than I thought. You have PBP version 2.03. (extremely old)

    If you look at the version history
    http://www.melabs.com/support/upgrade.htm#History

    version 2.04 corrected a problem in 2.03 ...
    IF..THEN..ELSE..ENDIF didn't always generate GOTO macro.

    And as I look through the .LST file ... Every IF statement has an error.
    Can't imagine how PBP even got off the ground with those kinds of errors.

    Sorry, I don't see any way to make it work with 2.03
    <br>
    DT

  3. #3
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Darrel Taylor View Post
    Right, which would have made it hard to have written something in PBP.
    But he did make the original "Turtle" robot that supposedly John based it on.

    Got the .LST file, and it's worse than I thought. You have PBP version 2.03. (extremely old)

    If you look at the version history
    http://www.melabs.com/support/upgrade.htm#History

    version 2.04 corrected a problem in 2.03 ...
    IF..THEN..ELSE..ENDIF didn't always generate GOTO macro.

    And as I look through the .LST file ... Every IF statement has an error.
    Can't imagine how PBP even got off the ground with those kinds of errors.

    Sorry, I don't see any way to make it work with 2.03
    <br>
    The IF...THEN... might not generate a goto macro like he has it in the program:
    if x>255 then skp

    but how about
    if x > 255 then goto skp

    It sounds logical anyways...and I don't see the word 'goto' in any of the if/then statements

  4. #4
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Logical Indeed!

    Good thought skimask.
    <br>
    DT

  5. #5
    Join Date
    Oct 2006
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Well, thanks anyway..our time in replying to the posts really helped. I already got the code compiled using PBP 2.46. Please don't ask me how I did it, just let me tell me that it really took my ingenuity to work..hehe. And with regards to the unfairness of the HEX file, I understand your situation and because of that, I became more resourceful in finding ways to compile my program without using any illegal credit cards or spending a dime. hehehe.. I hope we talk again on programming topics man! More power to you!

  6. #6
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by scaenix View Post
    ... I already got the code compiled using PBP 2.46. Please don't ask me how I did it, just let me tell me that it really took my ingenuity to work..hehe... I became more resourceful in finding ways to compile my program without using any illegal credit cards or spending a dime. hehehe..
    I hope we talk again on programming topics man!
    I don't think so!

    Hackers.... pffft.
    <br>
    DT

  7. #7
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by scaenix View Post
    Well, thanks anyway..our time in replying to the posts really helped. I already got the code compiled using PBP 2.46. Please don't ask me how I did it, just let me tell me that it really took my ingenuity to work..hehe. And with regards to the unfairness of the HEX file, I understand your situation and because of that, I became more resourceful in finding ways to compile my program without using any illegal credit cards or spending a dime. hehehe.. I hope we talk again on programming topics man! More power to you!
    Quote Originally Posted by Darrel Taylor View Post
    I don't think so!

    Hackers.... pffft.
    <br>
    Yep, and while he's at it, maybe he can run downtown and grab a whole bag of 'no help' from me either...I mean, really, a $25 upgrade, and yet buying parts to make stuff...Jeeze...

  8. #8
    Join Date
    Oct 2006
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by skimask View Post
    Yep, and while he's at it, maybe he can run downtown and grab a whole bag of 'no help' from me either...I mean, really, a $25 upgrade, and yet buying parts to make stuff...Jeeze...


    Well man, pls read my reply to the post. I didn't know people in this forum could be so judgmental. Judging me by my words without asking me what they mean...now what could you call that?

  9. #9
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by scaenix View Post
    Well man, pls read my reply to the post. I didn't know people in this forum could be so judgmental. Judging me by my words without asking me what they mean...now what could you call that?
    You told us ... "Please don't ask me how I did it,"

    I don't know how you could have done it legaly, so I have no other choice but to assume it wasn't.
    <br>
    DT

  10. #10
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by scaenix View Post
    Well, thanks anyway..our time in replying to the posts really helped. I already got the code compiled using PBP 2.46. Please don't ask me how I did it, just let me tell me that it really took my ingenuity to work..hehe. And with regards to the unfairness of the HEX file, I understand your situation and because of that, I became more resourceful in finding ways to compile my program without using any illegal credit cards or spending a dime. hehehe.. I hope we talk again on programming topics man! More power to you!
    Quote Originally Posted by scaenix View Post
    Well man, pls read my reply to the post. I didn't know people in this forum could be so judgmental. Judging me by my words without asking me what they mean...now what could you call that?
    Well, I double-dawg dare you to give me or others a feasible, reasonable, logical, and legal explanation as to how you 'got the code compiled using PBP 2.46' and 'became more resourceful in finding ways to compile my program (hehehe)' when you stated and provided proof that you had PBP 2.03 (legally or not) and didn't have the means or funds to acquire a more recent version, or at least (with validating receipt or other suitable proof-of-purchase paperwork) the much cheaper upgrade.

  11. #11
    Join Date
    Oct 2006
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Darrel Taylor View Post
    I don't think so!

    Hackers.... pffft.
    <br>

    hacker?

    no man, im not what you think I am. Anyone caught hacking in my country would be fined for $2000 and as I have said, I don't have money to set up a credit card account, so how much more pay for $2000!

Similar Threads

  1. Endless supply of 'syntax error's.
    By BitHead in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 14th December 2009, 20:21
  2. Replies: 0
    Last Post: - 1st September 2008, 07:03
  3. Math operations & Syntax?
    By kevj in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 23rd February 2008, 01:40
  4. Need help with I2C syntax problem?
    By Michael Wakileh in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 19th July 2007, 19:11
  5. Syntax error PIC16F684
    By milestag in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 21st September 2005, 18:54

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts