Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

serial communication

2 posts in Pocket PowerBuilder Last posting was on 2012-11-26 12:51:02.0Z
Eric Posted on 2012-11-23 11:31:57.0Z
From: Eric <pigexpert@agrisyst.com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:16.0) Gecko/20121026 Thunderbird/16.0.2
MIME-Version: 1.0
Newsgroups: sybase.public.pocketpowerbuilder
Subject: serial communication
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <50af5ead$1@forums-1-dub>
Date: 23 Nov 2012 03:31:57 -0800
X-Trace: forums-1-dub 1353670317 172.20.134.152 (23 Nov 2012 03:31:57 -0800)
X-Original-Trace: 23 Nov 2012 03:31:57 -0800, vip152.sybase.com
Lines: 9
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.pocketpowerbuilder:12546
Article PK: 262414

Serial communication works fine with the local external function
"WriteFile".

We now need to send a "non printable" character STX and ETX.

Anyone solved this problem?

Thanks
Eric


"Marco Diers" Posted on 2012-11-26 12:51:02.0Z
From: "Marco Diers" <diers(at)sf-datentechnik_no_spam_dot_de.removeme>
Newsgroups: sybase.public.pocketpowerbuilder
References: <50af5ead$1@forums-1-dub>
In-Reply-To: <50af5ead$1@forums-1-dub>
Subject: Re: serial communication
Lines: 1
MIME-Version: 1.0
Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
Importance: Normal
X-Newsreader: Microsoft Windows Live Mail 14.0.8117.416
X-MimeOLE: Produced By Microsoft MimeOLE V14.0.8117.416
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <50b365b6$1@forums-1-dub>
Date: 26 Nov 2012 04:51:02 -0800
X-Trace: forums-1-dub 1353934262 172.20.134.152 (26 Nov 2012 04:51:02 -0800)
X-Original-Trace: 26 Nov 2012 04:51:02 -0800, vip152.sybase.com
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.pocketpowerbuilder:12547
Article PK: 262413

Hi Eric,

you have to use blob. We do it this way ...

// external function
FUNCTION BOOLEAN WriteFile_blob ( ulong handle, &
blob buffer, &
long numBytesToWrite, &
REF long NumBytesWritten, &
long LNull) &
LIBRARY "coredll.dll" &
ALIAS FOR "WriteFile"
---
BLOB lblb_ascii
lblb_ascii = toANSI ( char ( 2 ) ) // 2 = STX
ll_write = len ( lblb_ascii )
lb_ok = writeFile_Blob ( iul_fileHandle, lblb_ascii, ll_write, ll_written,
ll_overlapped )

Marco


"Eric" <pigexpert@agrisyst.com> schrieb im Newsbeitrag
news:50af5ead$1@forums-1-dub...

> Serial communication works fine with the local external function
> "WriteFile".
>
> We now need to send a "non printable" character STX and ETX.
>
> Anyone solved this problem?
>
> Thanks
> Eric