JVM Nokia

Da Wikipedia, l'enciclopedia libera.


Nokia JVM Bugs

Bug riscontrati sulla JVM Nokia, presente nel cellulare Nokia 6600 (v. firmware: 4.09.1)

  • Impossibile istanziare un Thread a cui e' associato un nome. La JVM crasha.


RFCOMM problems

There are some issues when using Bluetooth serial ports (and thus input stream method) on Series 60 & Series 80 devices (detected in models Nokia 6600 FW 4.09.1, Nokia 6260/6620/6670/7610/9300/ 9500 Communicator):

When the Bluetooth Serial Port Profile (RFCOMM protocol) is used, reading of incoming stream is sometimes interrupted with IOException. The read method of the InputStream class may throw an IOException if the other end has closed the stream while the IputStream is still reading it.

Another issue is that the InputStream cannot use bigger than 512 size of byte array when reading stream. Bigger byte array may crash the midlet.

SOLUTIONS: Solution to the IOException issue: Ensure that the InputStream.read() is finished before closing the output stream in the other end.

Solution to the stream size issue: Do not use bigger than 512 size of byte array. Read the input stream in a loop or keep the whole length of the stream under 512 bytes.

Generic workaround to both issues: Use L2CAP connection instead of SPP (RFCOMM) if appropriate. This is feasible when you have access to L2CAP protocol in both ends of your application (connections between two phones, for example).

Personal tools