Important Update:

- Update Command port:
  - Simplified error handling
  - Provide error reply
- Added method GetNextParamGroup()
This commit is contained in:
Charl Wentzel
2019-01-10 11:46:41 +02:00
parent b679da9c29
commit 49294ab6b5
2 changed files with 129 additions and 131 deletions

View File

@@ -231,6 +231,11 @@ protected:
Param = &((*Param)->Next);
return Param;
}
inline TDeviceParamGroup * GetNextParamGroup( TDevice * Device, TDeviceParamGroup * LastParamGroup = NULL ) {
if (!Device) return NULL;
TDeviceParamGroup * ParamGroup = (LastParamGroup)? LastParamGroup->NextGroup : Device->FirstParamGroup;
return ParamGroup;
}
inline TDeviceParam * GetNextReadParam( TDevice * Device, TDeviceParam * LastParam = NULL ) {
if (!Device) return NULL;
TDeviceParam * Param = (LastParam)? LastParam->Next : Device->FirstParam;