daten über Bluetooth übertragen

OP #2420968
Lesenswert?

hallo ;
ich habe ein programm geschrieben für hinderniserkennung über kinect 
Kamera.
ich wollte die entfernung zwischen das kamera und Hindernis über 
bluetooth oder RS232 zu einem Mikrokontroller übertragen.das programm 
ist im visual studio 2010 geschrieben.ich habe versuch mit diesem keinem 
program:

using namespace System;
using namespace System.IO.Ports;
using namespace System::Threading;





namespace System.IO.Ports;
//using namespace System::IO::Ports;
using namespace System.IO.Ports.SerialPort;

 SerialPort Serial;

 Serial.PortName = "COM4";
 Serial.BaudRate = 9600;
 Serial.DataBits = 8;
 Serial.StopBits.One;
 Serial.ReadTimeout = 500;
 Serial.WriteTimeout = 500;

Serial.Open();
 if (Serial.IsOpen)
 {
 Serial.Write("mm",depthMD( point.x, point.y ));
 Serial.Close();


aber leider bekomme ich immer diese Fehler Meldungen:

1>main.cpp(98): error C2143: syntax error : missing ';' before '.'
1>main.cpp(98): error C2143: syntax error : missing ';' before '.'
1>main.cpp(105): error C2059: syntax error : '.'
1>main.cpp(107): error C2143: syntax error : missing ';' before '.'
1>main.cpp(107): error C2143: syntax error : missing ';' before '.'
1>main.cpp(109): error C2065: 'SerialPort' : undeclared identifier
1>main.cpp(109): error C2146: syntax error : missing ';' before 
identifier 'Serial'
1>main.cpp(109): error C2065: 'Serial' : undeclared identifier
1>main.cpp(111): error C2065: 'Serial' : undeclared identifier
1>main.cpp(111): error C2228: left of '.PortName' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(112): error C2065: 'Serial' : undeclared identifier
1>main.cpp(112): error C2228: left of '.BaudRate' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(114): error C2065: 'Serial' : undeclared identifier
1>main.cpp(114): error C2228: left of '.DataBits' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(117): error C2065: 'Serial' : undeclared identifier
1>main.cpp(117): error C2228: left of '.ReadTimeout' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(118): error C2065: 'Serial' : undeclared identifier
1>main.cpp(118): error C2228: left of '.WriteTimeout' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(120): error C2065: 'Serial' : undeclared identifier
1>main.cpp(120): error C2228: left of '.Open' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(121): error C2065: 'Serial' : undeclared identifier
1>main.cpp(121): error C2228: left of '.IsOpen' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(123): error C2065: 'Serial' : undeclared identifier
1>main.cpp(123): error C2228: left of '.Write' must have 
class/struct/union
1>          type is ''unknown-type''
1>main.cpp(124): error C2065: 'Serial' : undeclared identifier
1>main.cpp(124): error C2228: left of '.Close' must have 
class/struct/union
1>          type is ''unknown-type''


Ich bedanke mich Im Voraus für eure Hilfe

Antwort schreiben

Bitte melde dich an, um einen Beitrag zu schreiben.

oder

Mit Google-Account einloggen

Die Registrierung ist kostenlos und dauert nur eine Minute.

Jetzt registrieren