title: Symbol Scanner not working as IBM Hand-Held USB
body: <p>I use Motorola Symbol Scanner DS9808 .
  I am able to scan the barcodes to notepad in normal mode.
  But when i enable the scanner in IBM Hand-Held USB mode by scanning the barcode available in LS2208 guide, i am no longer able to scan the barcodes to notepad . </p>
  
  <p>I see a new HID device under my Device Manager when i connect this scanner in IBM Hand-Held USB mode . </p>
  
  <p>Any help as in how i can go ahead debugging would be great</p>
  
  <p>Also i do not see much help online for the scanner support with javascript .</p>
  
  #
  
  <p>Comment</p>
  
  <p>Now i got hold of a LS2208 scanner and i followed the steps as mentioned earlier . 
  I am not able to send input to notepad etc when i use it as IBM Hand-Held USB .</p>
  
  <p>I tried to debug this issue myself and following is the information . Hope its useful
  I installed a tool on my laptop which monitors the input from USB devices .</p>
  
  <p>When I scan a 128A barcode whose value is 05 ,</p>
  
  <p>In Set Defaults Mode , </p>
  
  <p>When scanned the code , an input value of 05 is sent to notepad . 
  And in the tool the output is 
  000037: Bulk or Interrupt Transfer (UP), 26.10.2015 12:01:25.654 +0.008. (1. Device: USB Input Device) Status: 0x00000000
  Pipe Handle: 0x9cf8cd0 (Endpoint Address: 0x81)
  Get 0x8 bytes from the device
   00 00 00 00 00 00 00 00                           ........</p>
  
  <p>In IBM Hand-Held USB Mode,</p>
  
  <p>No input is sent to notepad .
   Output from the monitoring tool is 
   000005: Bulk or Interrupt Transfer (UP), 26.10.2015 11:22:57.112 +16.722. (1. Device: USB Input Device) Status: 0x00000000
  Pipe Handle: 0xdd77130 (Endpoint Address: 0x82)
  Get 0x40 bytes from the device
   09 10 03 00 30 35 00 25 0B 00 00 00 00 00 00 00   ....05.%........
   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00   ................
   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00   ................
   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00   ................</p>
  
  <p>From some of the blogs i see that we need some javascript code in a html which would make the scanner send input to textbox . But it did not work for me . </p>
  
  <p>Please let me know if Javascript supports any Scanner APIs which i need to import or if such code works only with C# .</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>&lt; html &gt;
    &lt; body onload = "DevMgrLoad();"
  onunload = "DevMgrUnload();" &gt;
    &lt; input type = "text"
  id = "ctl00_ContentPlaceHolder1_SKU" / &gt;
    &lt; /body&gt;
  &lt;head&gt;
  &lt;object id="DeviceMgr" classid="clsid:745A17A0-74D3-11D0-B6FE-00A0C90F57DA"&gt;&lt;/object &gt;
    &lt; script type = "text/javascript" &gt;
    function DevMgrLoad() {
      DeviceMgr.Initialize();
    }
  
  function DevMgrUnload() {
    DeviceMgr.Uninitialize();
  } &lt; /script&gt;
  &lt;script type="text/javascript
  " for="
  DeviceMgr " event="
  DeviceEvent(strEvent)
  "&gt;
    alert('mani for');
          var strEventName;
          var nsEvent;
             nsEvent = new ActiveXObject("
  eSpace.esNamespace ");
             nsEvent = nsEvent.ApplyXML(strEvent);
  
             strEventName = nsEvent.Name;
             
             if (strEventName == "
  Scanner.DataEvent ") 
             {
                 try
                 {
                     strEventName = nsEvent.PROPERTIES.Scanner.ScanData;        
                     document.activeElement.value =  strEventName;     
                     if (document.activeElement.id != "
  ctl00_ContentPlaceHolder1_SKU ")
                     {
                         var ctl = document.getElementById(document.activeElement.id);
                         ctl.value = '';
                         ctl.focus();
                     }
                     else
                     {
                            document.activeElement.fireEvent("
  onchange ");
                  }               
                 }
                 catch(exception)
                 {                 
                     // this occurs when the user scans a field that is not scannable
                     // ignore the error
                 }   
          }
             nsEvent = null;      
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;/html&gt;</code></pre>
  </div>
  </div>
  </p>