Device describe

This commit is contained in:
Paul Hollinsky
2018-10-24 12:51:04 -04:00
parent 419fc2fc73
commit 95dce1c429
4 changed files with 219 additions and 193 deletions
+9
View File
@@ -268,4 +268,13 @@ bool icsneo_transmitMessages(const neodevice_t* device, const neomessage_t* mess
return false;
}
return true;
}
bool icsneo_describeDevice(const neodevice_t* device, char* str, size_t* maxLength) {
if(!icsneo_isValidNeoDevice(device))
return false;
*maxLength = device->device->describe().copy(str, *maxLength);
str[*maxLength] = '\0';
return true;
}