SPIKE-RT C API Reference [Japanese]
An RTOS-based software platform for LEGO® Education SPIKE™.
読み取り中…
検索中…
一致する文字列を見つけられません
spikeapi::Battery クラス

#include <Battery.h>

公開メンバ関数

 Battery (void)=default
 
uint16_t getCurrent (void) const
 
uint16_t getVoltage (void) const
 
bool hasError ()
 

詳解

SPIKE バッテリークラス

構築子と解体子

◆ Battery()

spikeapi::Battery::Battery ( void )
default

コンストラクタ

引数
-
戻り値
-

関数詳解

◆ getCurrent()

uint16_t spikeapi::Battery::getCurrent ( void ) const
inline

電流取得 バッテリーの電流を取得する

引数
-
戻り値
電流[mA]

◆ getVoltage()

uint16_t spikeapi::Battery::getVoltage ( void ) const
inline

電圧取得 バッテリーの電圧を取得する

引数
-
戻り値
電圧[mV]

◆ hasError()

bool spikeapi::Battery::hasError ( )
inline

インスタンス生成が正常にできたかどうかを確認するための共通メソッド Batteryでは複数生成が問題ないので、常にfalseを返す


このクラス詳解は次のファイルから抽出されました: