Is there a reason why the update fn in hardware_controller requires a SELECT then and UPDATE. Should it not just be compressed into a single update?