use macros for true and false
add debugging output