Scanner as a PLC device
From PlcWiki
(Difference between revisions)
(One intermediate revision not shown) | |||
Line 1: | Line 1: | ||
- | + | '''Moved to confluence''' | |
+ | |||
+ | |||
+ | workplace.ScanCOM = /dev/null | ||
workplace.device.scanner1 = yes | workplace.device.scanner1 = yes |
Current revision as of 09:29, 7 November 2024
Moved to confluence
workplace.ScanCOM = /dev/null
workplace.device.scanner1 = yes workplace.device.scanner1.settings.name = Fixed scanner workplace.device.scanner1.settings.type = serial #workplace.device.scanner1.settings.type = keyboard #workplace.device.scanner1.settings.type = nordic workplace.device.scanner1.settings.tty = /dev/ttyS0 workplace.device.scanner1.settings.speed = 9600 workplace.device.scanner1.settings.log_file = /usr/local/plc/log/scanner1.log workplace.device.scanner1.settings.emulate_delim = yes workplace.device.scanner1.settings.sentence_timeout = 100 workplace.device.scanner1.settings.sentence_delim = 10 workplace.device.scanner1.settings.debug_mode = yes #workplace.device.scanner1.event.scannerinput = "^prefix(.+)suffix\r?\n?$" workplace.device.scanner1.event.scannerinput = "^\x02?(.+?)\x03?\r?\n?$" workplace.device.scanner1.event.scannerinput.input = [[:]]
workplace.device.scanner_nimmsta = yes workplace.device.scanner_nimmsta.settings.type = nimmsta workplace.device.scanner_nimmsta.settings.tty = /dev/ttyUSB_2_3 workplace.device.scanner_nimmsta.settings.log_file = /usr/local/plc/log/scanner_nimmsta.log workplace.device.scanner_nimmsta.settings.debug_mode = yes workplace.device.scanner_nimmsta.settings.sentence_delim = 13 workplace.device.scanner_nimmsta.settings.speed = 1000000 # workplace.device.scanner_nimmsta.settings.speed = 115200 workplace.device.scanner_nimmsta.settings.name = Nimmsta # workplace.device.scanner_nimmsta.settings.nimmsta_tag = CUSTOM workplace.device.scanner_nimmsta.event.scannerinput = "^[+]..ScanEvent....(.+?)\r?$" workplace.device.scanner_nimmsta.event.scannerinput.input = [[:]]
The new & simple way (since September 2013):
workplace.ScannerModel = Device
or
workplace.ScannerModel = Keyboard
or
workplace.ScannerModel = Nordic
or
workplace.ScannerModel = Nimmsta
If plc_scan does not work, update the plc_client_system package or try clever_scan.
New way adds a scanner device "scanner_dev". It is added as an "ADD" so if it is necessary redefine any parameter of this scanner must be redefined by the #map directive.