VisualHMIステージング(システム)有効期限ロックとset_stage_pwd

freeFree Technical Resource

This content is free to read, suitable for basic learning and search traffic.

ステージ(リースロックマシン):合意された時間に自動ロック画面、パスワードを入力してロック解除します。許褚、分割払いに适する。システムシナリオは“有効期限前ロック”で、カスタムシナリオ(0 4)は“有効期限前ロック”です。

1.構成

工程 → 工程設定→分割使用:分割、分割数(最大10)、有効期限ロック画面 ID、各期間の有効期限とパスワードを有効にします。

VisualHMIステージング(システム)有効期限ロックとset_stage_pwdFigure

2.ロックインタフェースとシステムレジスタ

パスワード入力バインディング$SysStageEnterPwd(LW 02 0 5,UINT32)と現在番号バインディング$SysStageTimeLevel(LW 02 0 4,UINT16,Scale 1 Offset 1)の2つの数値コントロールがあります。

VisualHMIステージング(システム)有効期限ロックとset_stage_pwdFigure1

3.ステージ·タイム·パワーダウン·ストレージ(LUA)

システム·レジスタSysCfgCtrl 0 x 011A/SysCfgOption 0 x 011Bに書き込むには、次の手順が必要です。

function on_update slave vtype
  if vtype ==_LW then
    addr = 0 x 0210とaddr = 0 x 0218の場合、5つのステージング時間アドレスがあります。
      set_uint16 VT_LW、0x011B、1 5--ステージ設定パスワードを選択します。
      set_uint16_LW、0x011A、0x5501   - 保存する。
    End of Endシングル
  End of Endシングル
End of Endシングル

VisualHMIステージング(システム)有効期限ロックとset_stage_pwdFigure2

4.パスワード(読み書きのみ)

set_stage_pwd(level,pwd):レベル0~9はステージ1~10に対応し、pwdは数値パスワードです。初回使用時にRW領域にパスワードを書き込む(識別子ビット0 x 0 0 5 5重複防止初期化):

function on_init
  local _= get_uint16_RW、0x2000
  if_val ~= 0 x 0055 then
    set_uint32 VT_RW、0x0000、1111
    set_uint32 VT_RW、0x0002、2222
    set_uint32 VT_RW、0x0004、3333
    set_uint32 VT_RW、0x0006、4444
    set_uint32 VT_RW、0x0007、5555
    set_uint16 VT_RW、0x2000、0x0055
  End of Endシングル
  set_uint16_LW、0x011B、1 5
  set_uint16 VT_LW、0x011A、0x5502--set_stage_pwdの後のパスワードからロード
End of Endシングル

VisualHMIステージング(システム)有効期限ロックとset_stage_pwdFigure3

5.回復とスイッチ。

ステージング書き込みを復元SysCfg Ctrl = 0 x 5503;動的スイッチングはLW0200(ステージング0または1)+Saveを書き込むことで実現されます。ステージングを含むすべての書き込みRW/システムレジスタOperationは、SysCfgCtrl/SysCfgOptionとともに保存されます。

VisualHMIステージング(システム)有効期限ロックとset_stage_pwdFigure4

ステージコードは読まずに書く。ユーザーにパスワードを変更または初期化してもらいたい場合は、RW領域にコピーをミラーリングし、set_stage_pwdで同期してください。変更が完了するたびに、SysCfgCtrl 0x011A/SysCfgOption 0x011Bを調整して保存します。

整理自広州大彩科技开発(hmi-doc.gz-dc.com)“”,所有大彩科技。

Put this resource to use in a real project?

Go to the Tool Center for message parsing, CRC verification and device debugging, or submit your requirements for selection and integration advice.

Engineer Membership

Turn this article into actionable debugging resources

After activation, you can use advanced message parsing, resource pack downloads, code examples, engineering cases and priority technical support, suitable for real project delivery.

Unlimited Advanced Tools
Resource & Code Packs
Complete Engineering Case Library
Priority Technical Support

Leave a Reply

Your email address will not be published. Required fields are marked *.