mirror of
https://github.com/eddyem/apogee_control.git
synced 2026-03-20 16:51:01 +03:00
fixed some errors
This commit is contained in:
@@ -129,6 +129,25 @@ CamParams *getCamParams(std::string & msg){
|
||||
return ∥
|
||||
}
|
||||
|
||||
/**
|
||||
* return camera info
|
||||
* Don't forget to call FREE!!!
|
||||
* @param pid, vid - device PID and VID
|
||||
*/
|
||||
char *ApnGlueGetInfo(int *pid, int *vid){
|
||||
if(pid || vid){
|
||||
uint16_t v = 1, p = 2, d = 3;
|
||||
alta->GetUsbVendorInfo(v, p, d);
|
||||
if(pid) *pid = p;
|
||||
if(vid) *vid = v;
|
||||
}
|
||||
std::string str = alta->GetInfo();
|
||||
char *writable = new char[str.size() + 1];
|
||||
std::copy(str.begin(), str.end(), writable);
|
||||
writable[str.size()] = '\0';
|
||||
return writable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Open camera device and assign it to variable <alta>
|
||||
* IT DON'T WORK WITH MULTIPLE CAMERAS SIMULTANEOUSLY!
|
||||
@@ -588,6 +607,8 @@ int ApnGlueReadPixels(unsigned short *buf, int nbuf, char whynot[]){
|
||||
return altaerr;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
******************************** FILTER WHEEL ********************************
|
||||
*/
|
||||
|
||||
@@ -153,6 +153,7 @@ int ApnGlueExpDone();
|
||||
void ApnGlueExpAbort(void);
|
||||
int ApnGlueStopExposure();
|
||||
int ApnGlueReadPixels(unsigned short *buf, int nbuf, char whynot[]);
|
||||
char *ApnGlueGetInfo(int *pid, int *vid);
|
||||
|
||||
// Wheel
|
||||
int ApnGlueWheelOpen(unsigned int id, Apn_Filter type);
|
||||
|
||||
Reference in New Issue
Block a user