Attempted to get it working on actual hardware. Ran into issues. Will debug later. I think it has to due with the arduino being a mega as opposed to an uno