Refactor edison adaptor