title: Difficult To Connect Thermal Printer via Web Bluetooth
body: <p>Right now I am developing web which has ability to connect thermal printer. I am using angular framework, and I successfully connect the thermal printer with USB using library <code>ng-thermal-printer</code>. But I want to my web also being able to connect thermal printer via web bluetooth which is BLE (Bluetooth Low Energy). As far as I know, BLE has specification in term of GATT and has services and characteristics in it.</p>
  <p>The progress I did so far, I can connect and send a value to the thermal printer device in a Service and a Characteristic, let's say Service with UUID AS and Characteristics with UUID AC, using my android phone with the help of application named <strong>nRF Connect</strong>. Targeting Service AS and send hexadecimal value at charateristic AC make me successfully print something on the thermal paper.</p>
  <p>But there is a problem. After knowing the right service and characteristic. I implemented it in my project. But, my chrome browser console showed error:</p>
  <ol>
  <li>Origin is not allowed to access any service... and it told me to add optionalServices when requestiDevice()</li>
  <li>After I added Service AS in property optionalServices, the console showed error DOMException: Connection failed for unknown reason.
  The errors showed both in chrome PC and chrome android.</li>
  </ol>
  <p>NB:</p>
  <ul>
  <li>I have enabled Experimental Web Platform features on chrome</li>
  <li>I have enabled Use the new permissions backend for Web Bluetooth on chrome</li>
  <li>I have enabled Allow invalid certificates for resources loaded from localhost. on chrome</li>
  <li>I have enabled Enable new USB backend on chrome</li>
  <li>I have used https.</li>
  </ul>
  <p>Additional question. is bluetooth connection that application nRF Connect used different from BLE? if so, why it displays services and characteristics?</p>