Fixed bug, simplified switchboard.write