EthercatDevice_QECRXXUN01.getSystemPowerVoltage()

[EthercatDevice_QECRXXUN01]

描述

獲取從站裝置的 Vs 電壓值。(單位:V)

模組類別

class EthercatDevice_QECR11UN01;
/* RJ45 power [1, 1]. */
class EthercatDevice_QECR00UN01;
/* RJ45 power [0, 0]. */

格式

double getSystemPowerVoltage();

語法

EthercatDevice_QECR11UN01 slave;
slave.getSystemPowerVoltage();

回傳

Double:從站裝置的 Vs 電壓值。(單位:V)

範例

#include "Ethercat.h"

EthercatMaster master;
EthercatDevice_QECR11UN01 slave;

void setup(void) {
    Serial.begin(115200);
    while (!Serial);
    
    master.begin();
    slave.attach(0, master);
    master.start();

    Serial.println(slave.getSystemPowerVoltage());
}

void loop() {}

函式庫參考主頁面

86Duino 參考的文本是根據 Creative Commons Attribution-ShareAlike 3.0 License,部分文本是從 the Arduino reference 修改的。 參考中的代碼示例已發佈到公共領域。

發表評論

上部へスクロール