Connecting an USB based QR Code Scanner to an Industrial Edge Device
This application examples shows how to connect a QR Code Scanner via USB to the Industrial Edge Device. The scanned QR Code will be sent to a PLC and displayed in an HMI Panel.
The application reads the QR Code provided by the scanner and publishes it on the IE Databus to the topic corresponding to the S7 Connector, which sends the data to the PLC. This topic needs to be created in the IE Databus in advance. Scanner type, plc tag, databus topic as well as databus credentials can be configured via an external configuration file.
- Industrial Edge App Publisher V1.1.5
- Docker Engine 18.09.6
- Docker Compose V2.4
- S7 Connector V1.1.11
- S7 Connector Configurator V1.1.14
- IE Databus V1.1.10
- IE Databus Configurator V1.1.24
- Industrial Edge Device V1.1.0-44
- QR Code Scanner: SIMATIC MV320
- TIA Portal V16
- PLC: CPU 1511 FW 2.8.3
The used TIA Portal project can be found in the miscellenous repository under the following name and is also used for several further application examples:
Further information about how to configure the S7 Connection to write data to the PLC can be found in the docs section
- Configure IE Databus
- Configure S7 Connection
You can find the further information about the following steps in the docs
- Configure QR Code Scanner
- Build application
- Upload app to Industrial Edge Managment
- Deploying application to Industrial Edge Device
Plug your SIMATIC MV320 Bar Code Scanner (or any other USB Scanner) to one of the USB Ports of your Industrial Edge Device.
Go to the TIA Portal Project, start the HMI Runtime and scan any available QR Code (e.g the following QR Code). A pop up will appear with the content of the scanned code.
You can also open the GBD datablock in the TIA Portal and check the content of the APP_QRCode variable in the app signals structure.
How to access the USB based QR Code Scanner inside the application as well as further details about the source code can be found in the implementation section.
- Accessing QR Code Scanner inside the application
- Publishing QR Code to the IE Databus
- Here is a link to the docs of this application example.
- You can find further documentation and help in the following links
Thanks for your interest in contributing. Anybody is free to report bugs, unclear documenation, and other problems regarding this repository in the Issues section or, even better, is free to propose any changes to this repository using Merge Requests.
Please read the Legal information.