Good that you isolated the problem. You might want to add a "Delay (10)" or something along those lines to your main loop. Without some sort of delay, BMAX will take CPU utilization to 100% and this might cause applications and services to become cranky with you :)
Tim
Tim