Je travaille sur un projet basé sur un FASTRACK SUPREME qui doit recevoir des commandes via une RS232 série. Le problème est: Lorsque j'utilise HyperTerm la commande ATDxxxxxxxxx; fonctionne bien. Lorsque j'utilise la bibliothèque CVI RS232, rien ne se passe. Est-il possible que ma commande reste bloquée dansEnvoi d'une commande ATD à un Fastrack Supreme via RS232 dans LabWindows/CVI
le tampon série? Voici mon code:
#include <ansi_c.h>
#include <cvirte.h>
#include <userint.h>
#include <rs232.h>
#include <utility.h>
#include <formatio.h>
#include <string.h>
int configurePort(void);
int sendCommand(void);
int port_open;
int error;
int main()
{
configurePort();
sendCommand();
return 0;
}
int configurePort()
{
port_open = 0;
error = OpenComConfig (4, "COM4",115200 ,0,8,1,0, -1);
if (error)
{
printf("Error!\n");
}
if (error == 0)
{
port_open = 1;
SetXMode (4, 0);
SetCTSMode (4, 0);
SetComTime (4, 0);
}
return 0;
}
int sendCommand()
{
char bufferWrite[100] ;
Fmt(bufferWrite,"%s","ATD0040761768027;");
ComWrt(4, bufferWrite, 18);
return 0;
}
Où est le problème? S'il vous plaît aider! Merci.