3d VR Headset
Übersicht

Erren3DBetreff: 3d VR Headset |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
Hallo,
ich hoffe hier finde ich Hilfe. Will nen Cybermaxxhelm mit BB ansteuern. Leider ist mein C++ bei 2% und ich bekomm das mit der Anbindung an Blitz nicht hin. Hier was ich hab: int AutoDetectComPort(void); Auto-Detects CyberMaxx on COM1 though COM4 returns COM0_ID if not found else COM1_ID though COM4_ID; Parameters: NONE BOOL OpenCom(const char*); Opens selected comm port and looks for CyberMaxx. Auto-Detect calls OpenCom for each port. If port opened successfully and CyberMaxx found, function returns TRUE else comm port is closed and return value is FALSE; Parameters: COM1,...,COM4; BOOL ReadFromPort(void); Reads data from port. Use Get_PYR(...) to access the data. Returns TRUE if successful. Void Get_PYR(int*, int*, int*); Get Pitch, Yaw, Roll respectively +45<->-45, 359<->0, +45<->-45 char* Get_Version(void) Returns firmware version, else NULL if device not found BOOL HardReset(void); HardReset sets CyberMaxx to power up default state BOOL Set9600(void); Sets port and CyberMaxx to 9600 bps (default) BOOL Set19200(void); Sets port and CyberMaxx to 19200 bps BOOL SetHysteresisOn(void); Sets hysteresis on (prefered) BOOL SetHysteresisOff(void); Sets hysteresis off (default) BOOL CheckSumOn(void); Enables checksum on. If error occured, then last valid packet will be used. BOOL CheckSumOff(void); Enables checksum off (default) char GetDataMode(void) Returns data transmission mode. BINARY_MODE - faster (default) ASCII_MODE - slower, used for debug void SetDataMode(char) Sets data transmission mode. Same as above char GetTransMode(void) Returns SAMPLE_UPON_REQUEST (default) or CONTINOUS_SAMPLE_MODE void SetTransMode(char) Sets transmission Mode. Same as above void SetSamplingRate(int rate); Sets CyberMaxx packet sampling rate. MINPACK <-> MAXPACK increments of 5 default rate is 40 pps int GetSamplingRate(void) Returns current sampling rate that CyberMaxx is set to. int GetCurrentSpeed(void) Returns current comm port speed. 9600 or 19200 int GetPortId(void) Returns port number to which CyberMaxx is attached. COM1_ID,...,COM4_ID if found, else COM0_ID Sample code: // CyberMaxx 2.0 Win95 & NT SDK // Copyright (©) 1996 VictorMaxx Technologies, Inc // Author: Robert J. Gebis // Date: 6 March 96 Ver 1.0 #include <conio.h> #include <iostream.h> #include "CyberMaxx.h" // This has to be linked with MaxxCom.lib // to use MaxxCom.dll void main(void) { MaxxCom CyberHMD; int Pitch, Yaw, Roll; // Start by connecting to the CyberMaxx if( !CyberHMD.AutoDetectComPort()) { // ERROR CyberMaxx not Found exit(-1); } // These are optional CyberHMD.SetHysteresisOn(); // turn on the hysteresis filter to minimize jittering char version[10]; strcpy( version, CyberHMD.Get_Version()); CyberHMD.SetSamplingRate(50); // Used only in continous mode // defailt is 40 packets/s // This is how you read while( !_kbhit()) { // if the CyberMaxx has supplied data, this returns true if( CyberHMD.ReadFromPort()) { CyberHMD.Get_PYR(&Pitch, &Yaw, &Roll); // Read data cout << "Pitch -> " << Pitch << endl; cout << "Yaw -> " << Yaw << endl; cout << "Roll -> " << Roll << endl << endl; } else { cout << "Error" << endl; } } // go until a key is hit } // end of main und ein Beispiel: von meinen decls .lib "maxxcom.dll" AutoDetectComPort#() OpenCom$(port$) Get_PYR%(p*, y*, r*) aber ich bin zu Blöd, glaube ich . Darum bitte ich um Hilfe. Gruß Micha |
||
![]() |
Jan_Ehemaliger Admin |
![]() Antworten mit Zitat ![]() |
---|---|---|
hm, sieht nicht so aus, als ob es noch unter XP und Win 2000 Läuft, weil sich hier eine Menge in der Com port Logic geändert hat, gegenüber Win 95 & NT
du solltest mal schauen, ob du ein moderneres SDK findest, wie gesagt,das ding ist eher was für Hacker geworden, mit der Zeit. |
||
between angels and insects |
Erren3DBetreff: Läuft unter XP |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
Also die beiliegende Anwendung läuft problemlos unter XP.
Nur mein C++ ist zu schlecht um das an BB anzupassen. Gruß |
||
Übersicht


Powered by phpBB © 2001 - 2006, phpBB Group