J2ME UDP Datagram 3 Second Delay

G

gordonmcdowell

I have been working on a problem receiving UDP datagrams on an emulated
MIDP 2.0 phone. The datagrams are held for 3 seconds before the phone
can receive them.

A history of my trying to isolate this problem can be found at...
http://forum.java.sun.com/thread.jspa?messageID=3050861&#3050861

....but it basically is this:

When my WinXpSp2 box running Netbeans-4.0 simulating a MIDP-2.0 phone
(either any J2ME Wireless Toolkit 2.2 default phone, or any Motorola
SDK 4.2 for J2ME phone), regardless of CLDC-1.0 or CLDC-1.1, when this
emulated phone tries to receive a UDP datagram, the following line of
code...

dc.receive(receiveDatagram);

....takes 3 seconds to execute IF the datagram is coming from my other
PC. But if the datagram comes from the same PC that the emulation is
being run on, there is no delay.

But this problem appears to be J2ME specific because running a similar
receive-a-udp-datagram app in J2SE does NOT have any delay regardless
of where the datagram comes from.

J2ME has a bunch of tools in netbeans to simulate degraded network
performance. I haven't used those. Also if I use a toolkit to launch an
emulated cell phone outside of Netbeans, I get same delay. I can't
think of anywhere to narrow it down to other then the J2ME
implementation.

Has anyone tried receiving UDP datagrams with their J2ME app? Surely it
must be a very common activity. Has anyone seen such a delay? Has
anyone NOT seen such a delay on a simulated cellphone?
Thanks for any help. -Gord
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,225
Members
46,815
Latest member
treekmostly22

Latest Threads

Top