code: function DevAdapter (controller) {
      this.id        = controller.svc;
      this.uid       = "//" + controller.svcopts.adapter + "/" + controller.svc + ":" +  controller.svcopts.port;;
      this.info      = 'HttpdAjax';
      this.debug     = controller.svcopts.debug;  // inherit debug from controller
      this.controller= controller;  // keep a link to device controller and TCP socket
      this.control   = 'http';
      this.cors      = controller.svcopts.cors || false;
      this.apikey    = parseInt (Math.random()*123456789876);  // should depend on user authentication
      
      // define root dir for html pages.
      if (controller.svcopts.rootdir !== undefined)  this.rootdir= controller.svcopts.rootdir;
      else  this.rootdir= path.join (__dirname, "../../www");
      
      this.Debug (1,"%s rootdir=%s", this.uid, this.rootdir);    
  }
docs: Adapter is an object own by a given device controller that handle nmeadata connection