Skip to main content

Bluetooth Error Handling

1 reply [Last post]
mobilecoder
Offline
Joined: 2008-02-11
Points: 0

Bluetooth has the following Exceptions (JSR 82 see http://java.sun.com/javame/reference/apis/jsr082/ )

BluetoothConnectionException
BluetoothStateException
ServiceRegistrationException

Is it possible to detect when a Bluetooth device moves out side of the range of another?

With a device having moved outside of the range, trying to communicate with that device will result in a null pointer exception. Is it possible to know that the device has moved outside the range?

Having moved outside the range for a few seconds the device moves back within range, can this some how be detected, and the original connection re-established?

Is their some way to define that if a device has moved outside the range for a predetermined amount of time that the device is now no longer available?

Also is it possible to detect if a device that you are in communication with suddenly dies, i.e. switched off by the user, interrupted by another application etc.

If none of this is available is JSR82, can you recommend any other implementations that provide some or all of this functionality.

Thanks in advance for any insight you may have on this.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Hinkmond Wong

phonemeadvanced@mobileandembedded.org wrote:
> Bluetooth has the following Exceptions (JSR 82 see http://java.sun.com/javame/reference/apis/jsr082/ )
>
> BluetoothConnectionException
> BluetoothStateException
> ServiceRegistrationException
>
> Is it possible to detect when a Bluetooth device moves out side of the range of another?
>
> With a device having moved outside of the range, trying to communicate with that device will result in a null pointer exception. Is it possible to know that the device has moved outside the range?
>
> Having moved outside the range for a few seconds the device moves back within range, can this some how be detected, and the original connection re-established?
>
> Is their some way to define that if a device has moved outside the range for a predetermined amount of time that the device is now no longer available?
>
> Also is it possible to detect if a device that you are in communication with suddenly dies, i.e. switched off by the user, interrupted by another application etc.
>
> If none of this is available is JSR82, can you recommend any other implementations that provide some or all of this functionality.
>
> Thanks in advance for any insight you may have on this.
> [Message sent by forum member 'mobilecoder' (mobilecoder)]
>

Hi mobilecoder,

I'm forwarding your e-mail questions to the feature@phoneme.dev.java.net
forum. They should be able to help you on that mailing list instead of
the advanced@phoneme.deva.java.net mailing list.

Hinkmond

---------------------------------------------------------------------
To unsubscribe, e-mail: advanced-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: advanced-help@phoneme.dev.java.net