Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
MSComm
Message
De
07/06/2001 20:52:06
 
 
À
Tous
Information générale
Forum:
Visual Basic
Catégorie:
Produits tierce partie
Titre:
MSComm
Divers
Thread ID:
00516720
Message ID:
00516720
Vues:
42
Hi!!!

I have this code to send an init-string to a modem then waiting for the response OK...

Dim Buffer$
Dim Settings As Variant

MSComm1.CommPort = 2
MSComm1.Settings = "57600,N,8,1"
MSComm1.Handshaking = 0
MSComm1.InputLen = 0
MSComm1.PortOpen = True
MSComm1.Output = "ATZ" & vbCrLf
Do
DoEvents
Buffer$ = Buffer$ & MSComm1.Input
Loop Until InStr(Buffer$, "OK" & vbCrLf)
txtModemOutput.Text = Mid$(Buffer$, InStr(Buffer$, "OK" & vbCrLf), 2) & vbNewLine
End Sub

The problem is : The OK answer never come.. The modem always return me exactly what I send to him... Can somebody help me on that???

Thx!

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Bonjour!

J'ai un code permettant d'initialiser un MSComm et d'attendre la réponse ok...

(voir le code plus haut)

Le problème est que la reponse ne vient jamais... Le modem me revoit toujours exactement ce que je lui ai envoyé. Quelqu'un peu m'aider la dessus?

Merci! ;)
Répondre
Fil
Voir

Click here to load this message in the networking platform