Sending Ball Position over Bluetooth

Hi, this is my first time posting here so apologizes if anything is done wrong. I was trying to make an app where on my phone there is a ball that I am able to move around freely, and my second phone also has a ball that moves in sync (or relatively close to in sync) with the first phone. However after some trials I am able to send text over Bluetooth but when I try to send the balls x position to the second phone the controlling phone app crashes. I’ve tried sending the balls position as text and as an integer but nothing seems to help.

To give you an idea of what I’m trying to do is have one phone, held my me controlling a small red ball and the other phone on the ground for my cat to try and get the “laser” controlled by the my phone.

Any help would be appreciated, and apologizes for my grammar.

Well, if you are able to send text, the crash possibly occurs after text receipt rather than during. We need to see your Blocks to guide you further but if the sent data is being split (into x/y ordinates), that might be the area of failure.

This sounds like trying to send faster than BlueTooth can handle, a mismatch between frequent tilt updates and slower transmit capacity.

Try restricting the tilt events to just updating some global variables, and leave data transmission initiation to a medium frequency Clock timer feeding the global values to BlueTooth. Tweak the Clock Timer interval to find the best interval to the mean between responsiveness and blabber.