serial Import, no Nulls?

R. Hillen mail at richard-hillen.de
Mon Aug 4 10:38:01 EDT 2003


Hi Sarah,
thank you very much for the tip; it worked. Fine.
(I better would have looked into the documentation!)

So it is possible for me to read 8-bit-Data incl. NULs from the serial 
port using Windows or Mac OS.
On Mac OSX I have from my old Mac-OS-days a serial stealth-adapter and 
found for it a OSX driver. But until now I didnt succeed in using it. 
Probably someone on the list knows more about it?

Richard Hillen

> Subject: Re: Serial Import, no Nulls?
> From: Sarah <sarahr at genesearch.com.au>
> To: use-revolution at lists.runrev.com
> Reply-To: use-revolution at lists.runrev.com
>
> Hi Richard,
>
> If you look at the script in the "Open Serial Port" button in my stack,
> you will see the following line:
>    open file thePort for text update
> Try changing this to:
>    open file thePort for binary update
>
> I haven't tried reading any data with nulls but this would be my best
> guess on how to fix the problem.
>
> Cheers,
> Sarah
> sarahr at genesearch.com.au
> http://www.troz.net/Rev/
>
>
> On Sunday, August 3, 2003, at 09:14  pm, mail at richard-hillen.de wrote:
>
>> Hello list,
>>
>> I try to get data from a measurement-device (Windows 98, RunRev 
>> 2.0.2.)
>> using the serial port Com1.
>>
>> If I send "S" over the serial port, the device respond sending 20 byte
>> in
>> the Range 0 .. 255.
>>
>> Using Sarahs helpfull example-stack I tried to get them with "read 
>> from
>> file com1 for 20".
>> Looking at "it" there were less than 20 chars, the bytes with value 0
>> were
>> missing.
>>
>> Any Ideas, how to get _all_ 20 bytes?
>>
>> Thanx in advance
>>
>> Richard Hillen.




More information about the use-livecode mailing list