Fixed array[-1] in saveWind
Added debugging messages to some functions and #define DEBUG 0=No messages 1=Some messages 2=All messages