Using the barcode reader
Typically, scanned barcodes are entered into the currently selected text field of the app that is in the foreground.