move the require inside of the return
put the Hardware.publish into a function on the scope
forgot to send the command
add a hardware properties table
pass the hardware status an object instead of an array of objects
remove duplicate code
more comments and tidy up the code