Array and IF - THEN


Closed Thread
Results 1 to 10 of 10

Hybrid View

  1. #1
    Join Date
    Dec 2007
    Location
    Finland
    Posts
    191


    Did you find this post helpful? Yes | No

    Post Great!

    Hi Darrel,

    At the moment I don't have PBP2.60, still working with 2.50c.
    I was wondering what is benefit to upgrade to 2.60, but now I see it clearly
    This parse script is something new and ARRAYREAD -function is great.

    So in Mainloop, after DEBUGIN, I should call parse? Sounds so easy!
    Code:
    <code><font color="#000000">Mainloop:
        <b>DEBUGIN </b>1000, Mainloop, [<b>STR </b>Data_Array\4]
        <b>GOSUB </b>Parse
        <b>GOTO </b>Mainloop
    <b>END </b></code>
    PBP 2.60 will definitely be on my "Wish List".

    BR,
    -Gusse-
    Last edited by Gusse; - 22nd January 2010 at 23:56.

  2. #2
    Join Date
    Sep 2005
    Location
    Campbell, CA
    Posts
    1,107


    Did you find this post helpful? Yes | No

    Default

    Darrel,

    Perfect!

    I was just in the process of writing my own routines to do the same thing.
    I was comparing element 1 in an array with every element in the second array, then element 2 in the first array against every element in the second. If I found a match, I would increment the pointers to both arrays and compare again.
    What a mess that was!

    Of course, your routine is better/faster/smaller.

    Thanks!
    Charles Linquist

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


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Gusse
    So in Mainloop, after DEBUGIN, I should call parse? Sounds so easy!
    You got it! And hopefully it is...

    Quote Originally Posted by Charles Linquist
    I was just in the process of writing my own routines to do the same thing.
    I was working on a NMEA sentence parser, and Gusse's problem seemed to fit right in.

    I may have killed 3 birds with one stone

    Hope it works,
    Last edited by Darrel Taylor; - 23rd January 2010 at 05:20. Reason: Added original intent.
    DT

  4. #4
    Join Date
    Dec 2007
    Location
    Finland
    Posts
    191


    Did you find this post helpful? Yes | No

    Smile It is working!

    Quote Originally Posted by Darrel Taylor View Post
    You got it! And hopefully it is...


    I was working on a NMEA sentence parser, and Gusse's problem seemed to fit right in.

    I may have killed 3 birds with one stone

    Hope it works,
    Now I can confirm that Darrel's code is working well.
    Thank You very much!

    BR,
    -Gusse-
    Last edited by Gusse; - 25th February 2010 at 12:57.

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