Minor changes to get this sine generator working