Read ¶ ReadObject (Method) ReadObjectByAddress (Method)
Search ¶ GetObject (Method) GetObjectToWrite (Method)
Write ¶ WriteObject (Method) WriteObjectByAddress (Method)
Library Information ¶ GetLibVersion (Function) GetLibVersionNumber (Function) IsLibReleased (Function)
GetLibVersion (FUN) ¶ FUNCTION GetLibVersion : VERSION This function has been automatically generated from the project information. InOut: Scope Name Type Return GetLibVersion VERSION
GetLibVersionNumber (FUN) ¶ FUNCTION GetLibVersionNumber : DWORD This function has been automatically generated from the project information. InOut: Scope Name Type Return GetLibVersionNumber DWORD
IsLibReleased (FUN) ¶ FUNCTION IsLibReleased : BOOL This function has been automatically generated from the project information. InOut: Scope Name Type Return IsLibReleased BOOL
ObjectDictionary ¶ Iterators ObjectIterator (FunctionBlock) Current (Property) MoveNext (Method) ObjectDictionary (Property) Reset (Method) SubObjectIterator (FunctionBlock) Current (Property) MoveNext (Method) Object (Property) Reset (Method)
Iterators ¶ Iterators for simple iterating through the ObjectDictionary of a slave. ObjectIterator (FunctionBlock) Current (Property) MoveNext (Method) ObjectDictionary (Property) Reset (Method) SubObjectIterator (FunctionBlock) Current (Property) MoveNext (Method) Object (Property) Reset (Method)
ObjectIterator (FB) ¶ FUNCTION_BLOCK ObjectIterator IMPLEMENTS IObjectIterator Helps to iterate through the objects of an ObjectDictionary. For using this iterator property ObjectIterator.ObjectDictionary must be set to the IObjectDictionary interface. This interface can be retrieved from the CANopenDevice instance. After setting the Object Dictionary interface the iterator points in front of the first element of the Object Dictionary (==> property ObjectIterator.Current is 0). The iterator can be moved to the next element by calling the ObjectIterator.MoveNext method. If ObjectIterator.MoveNext returns TRUE the object can be retrieved by calling Property ObjectIterator.Current . The iterator can be set back in front of the first element by calling ObjectIterator.Reset . Example Following example iterates through all objects in an Object Dictionary an increments a counter. METHOD CountObjects VAR_INPUT END_VAR VAR_OUTPUT udiObjectCount : UDINT ; udiSubObjCount : UDINT ; END_VAR VAR ObjIterator : _3SCSS.ObjectIterator ; SubObjIterator : _3SCSS.SubObjectIterator ; itfCurObj : _3SCSS.IODObject ; itfCurSubObj : _3SCSS.IODSubObject ; END_VAR //Link Object Iterator to Object Dictionary ObjIterator.ObjectDictionary := _itfOD ; //Go through all objects WHILE ObjIterator.MoveNext () DO itfCurObj := ObjIterator.Current ; //Note: No NULL check necessary here because MoveNext returned TRUE. udiObjectCount := udiObjectCount + 1 ; //Link SubObjIterator with current Object SubObjIterator.Object := itfCurObj ; //Go through all SubObjects WHILE SubObjIterator.MoveNext () DO itfCurSubObj := SubObjIterator.Current ; udiSubObjCount := udiSubObjCount + 1 ; END_WHILE END_WHILE Properties: Current ObjectDictionary Methods: MoveNext Reset Structure: Current (Property) MoveNext (Method) ObjectDictionary (Property) Reset (Method)