GetConfiguredModuleCount

獲取已配置裝置的數量。

語法

KsError GetConfiguredModuleCount(
     int* Count
);

參數

Count:已配置裝置的數量。

回傳值

如果此函式執行成功,會回傳 errNoError,否則會傳回錯誤碼。如需更多有關錯誤碼的資訊,請參閱 KsError 清單。

可用的 EtherCAT 狀態

ecatOffline, ecatInit, ecatBoot, ecatPreOP, ecatSafeOP, ecatOP

範例

複製
int count = 0;
nRet = GetConfiguredModuleCount(&count);

使用需求

  RT Win32
最低支援版本 4.0 4.0
標頭檔 ksapi.h ksapi.h
程式庫 KsApi_Rtss.lib KsApi.lib

參見

AddModuleConfiguration

GetModuleConfiguration

RemoveModuleConfiguration