Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
FOPEN() on COM port under DOS
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00091336
Message ID:
00092059
Vues:
23
Bela,

We had very similar problems and as far as I can tell, you are doing the right things. After a lot of manipulations we had something that worked, the truth is that we did not really why. The we upgraded novell to 4.0x and it did not work anymore, whatever we tried. So we concluded that there is some incompatiblity between FPD and Novell when you use com ports.

Since then we intoduced Silverfox and have had no problems anymore. You do have to write a few things in C though.

HTH,

Marc



>Hi everybody!
>
>I have to communicate under DOS on comports!!
>So, I have the old FOX2.6DOS, but i never used this features. The two machines are installed correctly, I tested the phisical connection with Norton Commander, and the connection was good.
>I used the following program schema to send a character string over the cable: (simplified)
>Sender:
>m.string="anything"
>m.handle=fopen("COM2",12)
>if (m.handle)>-1
> m.count=fwrite(m.handle,m.string)
> =fclose(m.handle)
>endif
>
>Acceptor:
>m.handle=fopen("COM2",12)
>if (m.handle)>-1
> m.string=fread(m.handle)
> =fclose(m.handle)
>endif
>
>I started the acceptor program first on the other machine. The port openings are always succesfull, the handle numbers are always positive. But on the sender machine at the fwrite() row, a system write error occurs, stating : Errror writing the port COM2
>I issued the Mode Com2 9600,N,8,1 also all the two machines, but nothing changes.
>
>Can someone help me?
>
>TIA
>
>BB

If things have the tendency to go your way, do not worry. It won't last. Jules Renard.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform