Plugin Modification help
I am after advice on how to modify this Bluetooth-plugin such that it will reach to the BLE door opener that I have.

I have the following code that will toggle the door. But I am unsure as to what the best location and architecture is to put into the homebridge plugin.  

Thanks, I am new to NodeJS and homebridge.

```
noble.on('discover', function(peripheral) {
  console.log("hello world - discovered " +peripheral.advertisement.localName+ ": " + peripheral.uuid );
  if(peripheral.uuid == "568c300974984c9b96ea051f02a46fea")
  {
   peripheral.connect(function(error) {
     console.log('connected to peripheral: ' + peripheral.advertisement.localName);
     console.log('advertising the following service uuid\'s: ' + peripheral.advertisement.serviceUuids);
     peripheral.discoverServices(['1802'], function(error, services) {
       for (var i in services) {
        deviceInformationService =services[i];
        deviceInformationService.discoverCharacteristics(['2a06'], function(error, characteristics) {
          for (var i in characteristics) {
            console.log('  ' + i + " Service UUDI:"+characteristics[i]._serviceUuid+ ' uuid: ' + characteristics[i].uuid +" name:"+characteristics[i].name + " ServiceProperties:"+characteristics[i].properties);
          }
          var alertLevelCharacteristic = characteristics[0];
            console.log("The door just triggered, uncomment the lines below to actually make it open");
            // alertLevelCharacteristic.write(new Buffer([0x00,0x80,0x54,0x03,0xb3,0xf6,0x35,0x84]), true, function(error) {
            //   console.log('Door toggled');
            // });
            peripheral.disconnect()
         });
       }
     });
   });
  }
});
```