Serin2 multi wait?


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2007
    Posts
    4

    Question Serin2 multi wait?

    Is it possible to have multiple waits in a serin2 command? Looking for this OR that.
    Something like this;
    SerIn2 modem_in, 396, 500, loop, [wait($80) or wait($40),length,STR idstring\length]
    I know the syntax is insane but I wasn’t sure how else to ask.

    Thanks in advance for the help!

    Chris

  2. #2
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Nope, there's no such existing things, but i think you could use something like this
    Code:
    		SerIn2 modem_in, 396, 500, loop,[ByteA]
    		if ByteA=$80 or ByteA=$40 THEN
    			SERIN.. the rest of the process	
    			endif
    Probably i would prefer to use the hardware USART to prevent some data lost... like length
    HTH
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  3. #3
    Join Date
    Feb 2007
    Posts
    4


    Did you find this post helpful? Yes | No

    Default

    Steve,

    Great idea, that should do the trick.

    Thanks!

    Chris

Similar Threads

  1. Can't read sequential addresses in external EEPROM
    By tjkelly in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 18th February 2010, 14:46
  2. GPS $GPRMC to PIC16F684. Need help with SERIN2
    By xnihilo in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 27th November 2009, 09:47
  3. Getting SERIN2 to work?
    By BobPigford in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 22nd July 2009, 20:10
  4. HARDWARE I2C SAMPLE CODE question
    By Michael Wakileh in forum Code Examples
    Replies: 2
    Last Post: - 16th June 2009, 21:07
  5. SERIN2 digit parsing
    By skimask in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 7th January 2007, 23:15

Members who have read this thread : 1

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