Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using bytes, Hexa and serial port from VFP
Message
From
26/10/2004 19:50:57
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00954721
Message ID:
00954737
Views:
15
Hi Ricardo,

I'm no expert in this stuff, but I just did my first medical device myself using a RS232 NULL modem cable and the MSCOMM control. If your cable is direct to the device then I giess that a NULL modem cable is needed.

For the control characters I just defined them like in the following:
    cACK = CHR(06)            && acknowledge
    cENQ = CHR(05)            && start session
and I simply included cENQ or cACK, etc.

Sorry, but I have no idea of 16 bit words or nibbles, but I take it these aren't just simple ASCII characters of two bytes per word.

good luck


>Hi!
>
>I need to communicate via RS-232 serial port with a medical device (COM1,9600,8,N,1)
>I'm using MSComm ActiveX.
>The scarce and raw documentation says: 0x51 single byte send to start communication and 0x55 as acknowledgment, i.e.
>
>How can I do this ?
>It is the MSComm the best method to communicate with a serial device ? Do you know alternative uses ?
>
>I need information to how can I operate a serial device using Hexa information and reading data stream in 16 bit word (I need to read the nibbles, low and high).
>Can I do this with VFP ? Do I need use other tool as C or C++ ?
>
>Links, articles, info, downloads, all will be welcomed.
>
>p.s. I'm using TRANSFORM(nValue,"@ 0") and TRANSFORM(0x51) and I couldn't have connected with the serial device successfully.
>It is seen that the information that I have sent from VFP the serial device does not understand.
>
>Thanks in advance
Previous
Reply
Map
View

Click here to load this message in the networking platform