Lock control panel settings and disk write access.
(self, arg)
| 798 | |
| 799 | # ------------------------[ lock <pin> ]------------------------------ |
| 800 | def do_lock(self, arg): |
| 801 | "Lock control panel settings and disk write access." |
| 802 | if not arg: |
| 803 | arg = eval(input("Enter PIN (1..65535): ")) |
| 804 | self.cmd( |
| 805 | "@PJL DEFAULT PASSWORD=" |
| 806 | + arg |
| 807 | + c.EOL |
| 808 | + "@PJL DEFAULT CPLOCK=ON" |
| 809 | + c.EOL |
| 810 | + "@PJL DEFAULT DISKLOCK=ON", |
| 811 | False, |
| 812 | ) |
| 813 | self.show_lock() |
| 814 | |
| 815 | def show_lock(self): |
| 816 | passwd = self.cmd("@PJL DINQUIRE PASSWORD") or "UNSUPPORTED" |