Moved constants and function declarations to header file