help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Serial port communication


From: Stefan Mahr
Subject: Re: Serial port communication
Date: Fri, 27 Feb 2015 23:06:03 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

>   scalar structure containing the fields:
> 
>     timeout = -1

> However when I try to read data from the port with srl_read(s1, 8), octave
> just keeps running and eventually stop to respond. Does anyone know what
> could cause this?

Timeout is set to -1, which means blocking mode. srl_read(s1,8) returns
once it reads 8 bytes from serial port.

Set timeout between 0 and 255 (0..25.5 seconds) before read if you don't
want blocking mode.

e.g.
  set(s1, 'timeout', 100);  wait max 1 second


Stefan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]