views:

124

answers:

0

Hello,

I am working on a simple game using the mobile phone emulator in netbeans. The game works fine and the screen is updated when it needs to be. Whenever a ball moves, it sends the position of the ball to the other handset (in this case emulator).

But when ever anything goes outwards on the OutputStream on the bluetooth connection, it seems to slow up the full application.

The game canvas its self is a thread, and inside that it creates a bluetooth class thread. In the bluetooth class it listens for any incoming data.

Inside the same bluetooth class is a method for sending out on the bluetooth connection.

I thought i threaded this properly, but it lags a lot when anything is sent out. Anyone have any ideas as to what might be wrong and why output is slowing the application down?

thanks

~ Kyle.