- CVI 정보나눔(www.cvi.kr)
- 스터디
- 질문답변
질문,답변
글 수 1,629
CVI에서 64 bit 형 정수를 사용할려고 합니다.
다른데서는 long long이나 INT64 등으로 선언하면 되는데
CVI 에서는 어떻게 선언해야 될 지 모르겠네요.
sizeof(int) = 4
sizeof(long int) = 4
로 나옵니다.
64 bit 형 정수를 사용하고 싶습니다. CVI는 아예 64 bit 형 정수를 지원하지 않나요?
다른데서는 long long이나 INT64 등으로 선언하면 되는데
CVI 에서는 어떻게 선언해야 될 지 모르겠네요.
sizeof(int) = 4
sizeof(long int) = 4
로 나옵니다.
64 bit 형 정수를 사용하고 싶습니다. CVI는 아예 64 bit 형 정수를 지원하지 않나요?
허창원
자답이군요
64 bit 형 자료형은 CVI 7.0에서부터 지원할 거라고 합니다.
이전 버전에서는 지원하지 않는다네요.
64 bit 형 자료형은 CVI 7.0에서부터 지원할 거라고 합니다.
이전 버전에서는 지원하지 않는다네요.
구철회
CVI 7.0의 데이터 타입에 관한 내용입니다. 참고하세요.
C Data Types
The following table shows the data types allowed in LabWindows/CVI.
Type Size Minimum Maximum
char 8 –128 127
unsigned char 8 0 255
short 16 –32,768 32,767
unsigned short 16 0 65,535
int; long int 32 –231 231 – 1
__int64 64 –263 263 – 1
unsigned int 32 0 232 – 1
unsigned __int64 64 0 264 – 1
unsigned long 32 0 232 – 1
float 32 –3.40282E+38 3.40282E+38
double; long double 64 –1.79769E+308 1.79769E+308
pointers (void *) 32 N/A N/A
enum 8, 16, or 32 –231 231 – 1
The size of an enumeration type depends on the value of its enumeration constant. In LabWindows/CVI, characters are signed, unless you explicitly declare them unsigned. The types float and double conform to 4-byte and 8-byte IEEE standard formats.
C Data Types
The following table shows the data types allowed in LabWindows/CVI.
Type Size Minimum Maximum
char 8 –128 127
unsigned char 8 0 255
short 16 –32,768 32,767
unsigned short 16 0 65,535
int; long int 32 –231 231 – 1
__int64 64 –263 263 – 1
unsigned int 32 0 232 – 1
unsigned __int64 64 0 264 – 1
unsigned long 32 0 232 – 1
float 32 –3.40282E+38 3.40282E+38
double; long double 64 –1.79769E+308 1.79769E+308
pointers (void *) 32 N/A N/A
enum 8, 16, or 32 –231 231 – 1
The size of an enumeration type depends on the value of its enumeration constant. In LabWindows/CVI, characters are signed, unless you explicitly declare them unsigned. The types float and double conform to 4-byte and 8-byte IEEE standard formats.
CVI 6까지는 ANSI C에서 정해놓은 데이터 타입에 대해서만 지원하는 것 같습니다.
그 이상은 편법을 쓰야될 것 같은데, 그런 방법은 저도 아직 생각해보지 않아서 정확한 답변을 못드리겠네요...
C++ 문법을 이용할 수만 있다면, 그런 데이터 타입을 클래스로 정의해서 쓰면 쉬운데 말이죠...
방법이 없진 않을 겁니다. 누구 아시는분??