Information générale
Catégorie:
Produits tierce partie
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
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement