interpolation code
Changed to using udp