As Richard says, if you don't want to block on IO then oSerialL is NOT
an option. This will only work if you have nothing else going on that
is in scripts. IF you have your actual work going on in Virtual
Circuits then blocking on incoming serial won't hurt you a bit. It is
difficult to achieve that state of nirvana however.
Your only option is to use some other communications mode. Only
oSerialPort will reliably do what you want, and truly the ONLY way to
achieve what you want is if all of your processing occurs in Virtual
Circuits and the only thing that you are doing with scripts is the
serial input.
DLC
rtstofer wrote:
> --- In oopic@yahoogroups.com, "patrickcastelein" <pat160@...> wrote:
>
>>Hi Dennis,
>>
>>yes, I've been reading that part of the manual over and over ...
>>The scary part is where it says : "...while the oSerialL Object is
>>waiting for incoming serial data, the program flow is stopped".
>>I don't want the program flow to stop, my program has other tasks
>
> to
>
>>do while it should receive the serial data in the background (event-
>>driven).
>>Is there a way this can be done ?
>>
>>Thank you,
>>Patrick
>
>
>
> When I first saw your posting I was going to jump in and tell you
> that oSerialL is the absolute worst possible implementation of serial
> IO when it comes to receiving. It is bit-banged and the internal
> machine just sits and waits for line transitions. It works ok for
> transmitting as long as the receiver is ready to go. You can work
> around this part.
>
> Even with flow control (which you MUST implement), you will wait for
> the next char to arrive whether it is in a few milliseconds or
> several months.
>
> You need to come up with another I/O strategy. Use oSerialL only for
> output and reserve oSerialPort for input/output. If that doesn't
> work, there are chips that convert from I2C or SPI to USART I/O. You
> can hang them on the LOCAL I2C bus or perhaps the SPI object will
> work.
>
> Richard
>
>
>
>
>
>
>
> Yahoo! Groups Links
>
>
>
--
------------------------------------------------------
Dennis Clark ooPIC Tech Support
www.oopic.com
------------------------------------------------------
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/oopic/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/oopic/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:oopic-digest@yahoogroups.com
mailto:oopic-fullfeatured@yahoogroups.com
<*> To unsubscribe from this group, send an email to:
oopic-unsubscribe@yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
No comments:
Post a Comment