Edits to hardware.py