dcmi_get_version Prototype
Syntax
int dcmi_get_version(int card_id, int device_id, char* version_str, unsigned int version_len, int *len )
Function
Queries the chip driver version.
Parameter Description
Parameter |
Input/Output |
Type |
Description |
---|---|---|---|
card_id |
Input |
int |
ID of the Atlas 300T training card (model 9000). Query the supported IDs by referring to dcmi_get_card_num_list Prototype. |
device_id |
Input |
int |
Chip ID. The value is 0 (there is only one chip). Query the actually supported range by referring to dcmi_get_device_num_in_card Prototype. |
version_str |
Output |
char * |
Driver version. The space is allocated by the user. The size is 64 bytes. |
version_len |
Input |
unsigned int |
Length applied by a user for version_str. |
len |
Output |
int * |
Returns the length of the version number. |
Return Value
Type |
Description |
---|---|
int |
Results:
|
Exception Handling
N/A
Constraints
N/A
Calling Example
int ret = 0;
int len = -1;
int card_id = 0x56;
int device_id = 0;
unsigned char version_str[64] = {0};
ret = dcmi_get_version(card_id, device_id, version_str, 64, &len);
if(ret != 0) {
//todo: records logs
return ret;
}
...