Need help with delay function

are you overflowing the int, make it a long instead??

~q