|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#9
|
|||
|
|||
|
Re: UDP Recieving Problems
Can you post the complete output of the console where you are getting the "Robots don't quit" message.
To help point you in the right direction in the mean time: That message means there is an uncaught exception and it bubbled up to the system level. If it is an uncaught IO exception it should tell you a line number as well, but it probably has to do with your something within the udp() function. Are you sure the parameter to connector.open is correct? I believe you should be using a "datagram" protocol instead of a "data" protocol. For example A datagram connection for accepting datagrams on port 1234 "datagram://:1234" A datagram connection for sending to a server on port 1234: "datagram://123.456.789.12:1234" And it also looks like you never instantiate the Datagram variable "data", so its null when you call data.readUTF, and null when you use it as a param in receive(data). But that should throw a null point exception, and you should be seeing that in the console. If you don't that's because the program is failing before it gets to that line, which case your problem lies where you open your connection to the datagram (or maybe you do instantiate it somewhere and I just didn't notice it). You mentioned that you have a java applet that works. Is that written using the same version of JavaME that is running on the cRIO? My guess is that you copied your code from the applet to the CRIO, however, if the code was written under different java environments it will not be able to run on the cRIO without modification. Hope that helps. Kevin Last edited by NotInControl : 26-05-2012 at 00:54. |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|