The following forum(s) have migrated to Microsoft Q&A (Preview): Developing Universal Windows apps!
Visit Microsoft Q&A (Preview) to post new questions.

Learn More

 locked
UWP Barcodescanner DataReceived Event not firing RRS feed

  • Question

  • Hi,

    we try to develop an application that recieves data from a barcodescanner on a windows mobile handheld. (Honeywell DolphinCT50)

    We used the sample from https://msdn.microsoft.com/en-us/library/dn792060(v=winembedded.81).aspx to get started with the scanner part.

    The problem occurse when we trigger the scan. The light of the scanner switches on, but dispite there is a barcode in front of the scanner we get no datarecieved event. The typical beep is missing too, thought that might be something we have to implement after we recieved the data.

    Trying to find the problem we installed the above sample an the handheld but discovered that it shows the same problem.

    We tested other events:

    TriggerPressed and TriggerReleased work. ErrorOccurred did not fire, so there is either a problem too, or there is not error.

    For those who want to test the sample, remember to activate PointOfService-support in the packages or add it manually to the manifest as stated on the website, otherwise the app won't even find the scanner.

    In case the website is removed in the future here is a small version of the relevant code:

    Async Function GetBarcodeScanner(dataRecievedCallback As TypedEventHandler(Of Windows.Devices.PointOfService.ClaimedBarcodeScanner, Windows.Devices.PointOfService.BarcodeScannerDataReceivedEventArgs), releaseDeviceRequestCallback As EventHandler(Of Windows.Devices.PointOfService.ClaimedBarcodeScanner)) AS Task(Of Windows.Devices.PointOfService.ClaimedBarcodeScanner)
    
    Dim retVal As Windows.Devices.PointOfService.ClaimedBarcodeScanner = Nothing
    
    Dim scanner As Windows.Devices.PointOfService.BarcodeScanner = Await Windows.Devices.PointOfService.BarcodeScanner.GetDefaultAsync()
    If scanner IsNot Nothing Then
         retVal = Await scanner.ClaimScannerAsync()
         If retval IsNot Nothing Then
               AddHandler retVal.ReleaseDeviceRequested, releaseDeviceRequestCallback
               AddHandler retVal.DataReceived, dataRecievedCallback
               retVal.IsDecodeDataEnabled = True
               If Await retVal.EnableAsync() Then
                    Return retVal
               End If
         End If
    End If
    
    Return Nothing
    End Function

    Edit:

        The handheld is currently at Windows 10 Mobile Enterprise 10586.218


    • Edited by derdev Monday, August 21, 2017 10:41 AM
    Monday, August 21, 2017 10:11 AM

Answers

  • @derdev,

    There are several variables that could be impacting your experience.  Lets start with the basic functionality of the scanner.  Honeywell includes and application named ScanDemoW10 on this device to demonstrate the functionality of the scanner and configure its settings.  You will find this application under All Programs.  Does the ScanDemoW10 app work using the physical scan buttons on the side of the Dolphin CT50?  Be sure to try the same barcode that you attempted in the issue reported above.  You may need to enable the symbology if it is not reading, see #2 below.  If this app is not functioning, please contact Honeywell for assistance.

    Honeywell provides very useful documentation that you can use to help you troubleshoot further.
    https://www.honeywellaidc.com/en/-/media/en/files-public/technical-publications/computers/dolphinct50/CT50-W10-EN-QS.pdf

    Some additional things to consider:

    1. What symbology is the barcode that you are attempting to read? 

    2. Make sure that the symbology you are scanning is enabled in Symbology Settings (p37)

    3. Does ScanDemoW10 read the barcode that you reference in the issue above?

    4. Open Messaging App and place cursor in text edit area then press the scan button.  If the decoded barcode is inserted then the scanner is in Wedge Mode Profile which simply places the decoded data into the keyboard buffer and this will not work with the PointOfService.Barcode APIs.

    5. Make sure that the scanner is NOT configured in Wedge Mode Profile when using the PointOfService.BarcodeScanner APIs (p39)

    Please let us know the results of your testing.  

    Terry Warwick
    Microsoft

    • Marked as answer by derdev Thursday, August 24, 2017 7:19 AM
    Tuesday, August 22, 2017 2:13 PM
  • Hi Terry,

    thanks for the advice.

    As stated in the linked documentation it is necessary to place a configuration file in at least one of two locations mentioned in the document (p.39).

    After doing so our applicaton started working as expected.

    Since an example is given in the document (p.41) and it probably applies only to a specific device family we spare the details of the syntax.

    We decided to configure the profile so that it is applied automatically. Otherwise it might be necessary to call ClaimedBarcodeScanner.SetActiveProfileAsync(NameOfYourProfile), to activate one of the configured profiles.

    You might want to check for already existing profiles with BarcodeScanner.GetSupportedProfiles().

    And for the curious to answer your questions:

    We were aware of the ScanDemoW10 app. It worked as expected.  The symbology of the barcodes we tested is ean13 and code 128. Other Apps with textinput only receive the barcodes while the ScanDemoW10 app is running in background.


    • Marked as answer by derdev Thursday, August 24, 2017 7:19 AM
    • Edited by derdev Thursday, August 24, 2017 9:03 AM
    Thursday, August 24, 2017 7:18 AM

All replies

  • @derdev,

    There are several variables that could be impacting your experience.  Lets start with the basic functionality of the scanner.  Honeywell includes and application named ScanDemoW10 on this device to demonstrate the functionality of the scanner and configure its settings.  You will find this application under All Programs.  Does the ScanDemoW10 app work using the physical scan buttons on the side of the Dolphin CT50?  Be sure to try the same barcode that you attempted in the issue reported above.  You may need to enable the symbology if it is not reading, see #2 below.  If this app is not functioning, please contact Honeywell for assistance.

    Honeywell provides very useful documentation that you can use to help you troubleshoot further.
    https://www.honeywellaidc.com/en/-/media/en/files-public/technical-publications/computers/dolphinct50/CT50-W10-EN-QS.pdf

    Some additional things to consider:

    1. What symbology is the barcode that you are attempting to read? 

    2. Make sure that the symbology you are scanning is enabled in Symbology Settings (p37)

    3. Does ScanDemoW10 read the barcode that you reference in the issue above?

    4. Open Messaging App and place cursor in text edit area then press the scan button.  If the decoded barcode is inserted then the scanner is in Wedge Mode Profile which simply places the decoded data into the keyboard buffer and this will not work with the PointOfService.Barcode APIs.

    5. Make sure that the scanner is NOT configured in Wedge Mode Profile when using the PointOfService.BarcodeScanner APIs (p39)

    Please let us know the results of your testing.  

    Terry Warwick
    Microsoft

    • Marked as answer by derdev Thursday, August 24, 2017 7:19 AM
    Tuesday, August 22, 2017 2:13 PM
  • Hi Terry,

    thanks for the advice.

    As stated in the linked documentation it is necessary to place a configuration file in at least one of two locations mentioned in the document (p.39).

    After doing so our applicaton started working as expected.

    Since an example is given in the document (p.41) and it probably applies only to a specific device family we spare the details of the syntax.

    We decided to configure the profile so that it is applied automatically. Otherwise it might be necessary to call ClaimedBarcodeScanner.SetActiveProfileAsync(NameOfYourProfile), to activate one of the configured profiles.

    You might want to check for already existing profiles with BarcodeScanner.GetSupportedProfiles().

    And for the curious to answer your questions:

    We were aware of the ScanDemoW10 app. It worked as expected.  The symbology of the barcodes we tested is ean13 and code 128. Other Apps with textinput only receive the barcodes while the ScanDemoW10 app is running in background.


    • Marked as answer by derdev Thursday, August 24, 2017 7:19 AM
    • Edited by derdev Thursday, August 24, 2017 9:03 AM
    Thursday, August 24, 2017 7:18 AM
  • Hi,

    I am having a similar issue. Have a Honeywell Dolphin 75 3 Windows 10 Iot and a 8620 ring scanner and the DataReceived event doesn't fire. It works fine in ScanDemoW10 app. I've downloaded a profile file from their site and put it into Documents/Profile folder, without success. Can you please explain to me what you have done to make it work? I've also  added in code the same symbologies that are enabled in the ScanDemo app. Thank you!

    Thursday, December 7, 2017 8:18 AM
  • @LaurentiuNeacsu,

    It is difficult to tell from your description what is happening in the code.  Please try using the sample code published to GitHub, here to help determine if there is an issue within your code or an issue with the way that the physical hardware is configured.

    https://aka.ms/pointofservice.sampleapp.barcodescanner

    Terry Warwick
    Microsoft

    Thursday, December 7, 2017 2:39 PM