ja-jp_commands:reference:ictd
文書の過去の版を表示しています。
Ictd()
Ictd()は設定値を読み込んだ後、入力の立ち上がりごとに現在値を減らします。
bool Ictd(uint8_t counter_id, bool CD, bool LOAD, int32_t PV)
コマンド
| コマンド | 引数 | 戻り値 | 動作 |
|---|---|---|---|
Ictd(counter_id, CD, LOAD, PV) | uint8_t counter_id — カウンタ番号。uint8_tの範囲のため0 ~ 255を使用可能bool CDbool LOADint32_t PV — 設定値 | bool | 設定値を読み込んだ後、入力の立ち上がりごとに現在値を減らします。 |
使用例
bool Ictu(uint8_t counter_id, bool CU, bool RESET, int32_t PV); bool Ictd(uint8_t counter_id, bool CD, bool LOAD, int32_t PV); bool Ictud(uint8_t counter_id, bool CU, bool CD, bool RESET, bool LOAD, int32_t PV); int32_t IgetCount(uint8_t counter_id); void IsetCount(uint8_t counter_id, int32_t value); bool IctudDownState(uint8_t counter_id);
注意事項
- 従来の0~31固定制限は削除されました。ただし引数型が
uint8_tのため、最大IDは255です。 - メモリ不足でカウンタ状態を確保できない場合、カウンタコマンドは
falseまたは0を返します。 - 一度作成したカウンタ状態はプログラム実行中保持されます。
ja-jp_commands/reference/ictd.1788785589.txt.gz · 最終更新: by 127.0.0.1
