Ralph,

I had the same problem as you. In the end I traced it to missing source line numbers in classfiles, and the warning of that turned off..

-Ben

Craig Setera wrote:

Ralph,

It sounds like you haven't set things up for debugging according to the directions in the documentation. Please check http://eclipseme.org/docs/configuring.html#step4

Craig

Ralph Cook wrote:

I seem unable to hit a breakpoint in a MIDlet.

I am fairly new to Eclipse and eclipseME, though not to Java or MIDlets. I have: win2000
    Eclipse 3.1.1
    eclipseME 1.5.0
    Sun's and SonyEricsson's J2ME SDKs

I am attempting to set debugging up on one of the example MIDlets that comes with Sun's SDK, as an exercise -- I also have issues with another MIDlet I'm working on, but I'm hoping solving this will help me solve that.

I disabled preverification on the project, on the theory that it wouldn't hurt and that it might cause a problem in the emulator -- it hasn't helped either way that I can tell.

In the Sun SDK, when I have the Games MIDlet configured to run the TilePuzzle program and tell it to debug, it crashes with the following console:

--- console log, sun SDK ---

Connecting to 127.0.0.1 on port 2800
Waiting for KVM...
Waiting for debugger on port 2595
Running with storage root DefaultColorPhone
Connected to KVM
Connection received.
Method............: 101657ec 'com/sun/cldc/i18n/j2me/UTF_8_Reader.read (virtual)' ALERT: Attempting to resume current thread

Stack Chunk.......: da457c
Frame Pointer.....: da4664
Current IP........: 101e4c13 = 101e4b50 + offset 195
Previous Frame....: da4624
Previous IP.......: 1021a866 (offset 11)
Frame size........: 10 (4 arguments, 6 local variables)
Argument[0].......: d9c1f4
Argument[1].......: d9926c
Argument[2].......: 0
Argument[3].......: 1
Local[4]..........: 0
Local[5]..........: 65
Local[6]..........: 0
Local[7]..........: 65
Local[8]..........: 0
Local[9]..........: 0

Method............: 10188c50 'java/io/Reader.read (virtual)' Stack Chunk.......: da457c
Frame Pointer.....: da4624
Current IP........: 1021a866 = 1021a85b + offset 11
Previous Frame....: da4604
Previous IP.......: 101e2b1f (offset 11)
Frame size........: 2 (1 arguments, 1 local variables)
Argument[0].......: d9c1f4
Local[1]..........: d9926c

Method............: 10163e1c 'java/io/InputStreamReader.read (virtual)' Stack Chunk.......: da457c
Frame Pointer.....: da4604
Current IP........: 101e2b1f = 101e2b14 + offset 11
Previous Frame....: da45e8
Previous IP.......: 101e67a7 (offset 193)
Frame size........: 1 (1 arguments, 0 local variables)
Argument[0].......: d9c470

Method............: 101677a4 'com/sun/midp/midletsuite/ManifestProperties.readLine (virtual)' Stack Chunk.......: da457c
Frame Pointer.....: da45e8
Current IP........: 101e67a7 = 101e66e6 + offset 193
Previous Frame....: da45b4
Previous IP.......: 101fbb43 (offset 63)
Frame size........: 7 (2 arguments, 5 local variables)
Argument[0].......: d9c580
Argument[1].......: d9c470
Local[2]..........: 62
Local[3]..........: a8
Local[4]..........: 158
Local[5]..........: 62
Local[6]..........: 0

Method............: 10174e7c 'com/sun/midp/midletsuite/JadProperties.partialLoad (virtual)' Stack Chunk.......: da457c
Frame Pointer.....: da45b4
Current IP........: 101fbb43 = 101fbb04 + offset 63
Previous Frame....: d3074c
Previous IP.......: 101e66e5 (offset 13)
Frame size........: 12 (4 arguments, 8 local variables)
Argument[0].......: d9c580
Argument[1].......: d9d0b0
Argument[2].......: 0
Argument[3].......: 7fffffff
Local[4]..........: d9c470
Local[5]..........: 0
Local[6]..........: 0
Local[7]..........: 0
Local[8]..........: 0
Local[9]..........: 0
Local[10]..........: 0
Local[11]..........: 0

Method............: 10167784 'com/sun/midp/midletsuite/ManifestProperties.partialLoad (virtual)' Stack Chunk.......: d30590
Frame Pointer.....: d3074c
Current IP........: 101e66e5 = 101e66d8 + offset 13
Previous Frame....: d30724
Previous IP.......: 101fbb03 (offset 8)
Frame size........: 4 (4 arguments, 0 local variables)
Argument[0].......: d9c580
Argument[1].......: d9d0b0
Argument[2].......: 0
Argument[3].......: 7fffffff

Method............: 10174e5c 'com/sun/midp/midletsuite/JadProperties.load (virtual)' Stack Chunk.......: d30590
Frame Pointer.....: d30724
Current IP........: 101fbb03 = 101fbafb + offset 8
Previous Frame....: d30700
Previous IP.......: 101fbc22 (offset 6)
Frame size........: 3 (3 arguments, 0 local variables)
Argument[0].......: d9c580
Argument[1].......: d9d0b0
Argument[2].......: 0

Method............: 10174e9c 'com/sun/midp/midletsuite/JadProperties.load (virtual)' Stack Chunk.......: d30590
Frame Pointer.....: d30700
Current IP........: 101fbc22 = 101fbc1c + offset 6
Previous Frame....: d306e0
Previous IP.......: 10215a7e (offset 62)
Frame size........: 2 (2 arguments, 0 local variables)
Argument[0].......: d9c580
Argument[1].......: d9d0b0

Method............: 10185034 'com/sun/midp/security/Permissions.readPermissionsTable (static)' Stack Chunk.......: d30590
Frame Pointer.....: d306e0
Current IP........: 10215a7e = 10215a40 + offset 62
Previous Frame....: d30684
Previous IP.......: 10215c1d (offset 21)
Frame size........: 17 (1 arguments, 16 local variables)
Argument[0].......: da2948
Local[1]..........: d9d7c4
Local[2]..........: d9d0b0
Local[3]..........: d9c580
Local[4]..........: d9c488
Local[5]..........: 0
Local[6]..........: 0
Local[7]..........: 0
Local[8]..........: 0
Local[9]..........: 0
Local[10]..........: 0
Local[11]..........: 0
Local[12]..........: 0
Local[13]..........: 0
Local[14]..........: 0
Local[15]..........: 0
Local[16]..........: 0

Method............: 10185054 'com/sun/midp/security/Permissions.isValidDomainName (static)' Stack Chunk.......: d30590
Frame Pointer.....: d30684
Current IP........: 10215c1d = 10215c08 + offset 21
Previous Frame....: d30660
Previous IP.......: 101f14e7 (offset 15)
Frame size........: 3 (2 arguments, 1 local variables)
Argument[0].......: da2948
Argument[1].......: 1010aa68
Local[2]..........: 0

Method............: 1016d8b0 'com/sun/midp/dev/DevMIDletSuiteImpl.create (static)' Stack Chunk.......: d30590
Frame Pointer.....: d30660
Current IP........: 101f14e7 = 101f14d8 + offset 15
Previous Frame....: d305f4
Previous IP.......: 101f14d7 (offset 62)
Frame size........: 21 (10 arguments, 11 local variables)
Argument[0].......: da2948
Argument[1].......: d9d7e8
Argument[2].......: d9d8bc
Argument[3].......: 10115c10
Argument[4].......: 0
Argument[5].......: 0
Argument[6].......: 1010aa68
Argument[7].......: 0
Argument[8].......: 0
Argument[9].......: 0
Local[10]..........: 0
Local[11]..........: 0
Local[12]..........: 0
Local[13]..........: 0
Local[14]..........: 0
Local[15]..........: 0
Local[16]..........: 0
Local[17]..........: 0
Local[18]..........: 0
Local[19]..........: 0
Local[20]..........: 0

Method............: 1016d890 'com/sun/midp/dev/DevMIDletSuiteImpl.create (static)' Stack Chunk.......: d30590
Frame Pointer.....: d305f4
Current IP........: 101f14d7 = 101f1499 + offset 62
Previous Frame....: d305c8
Previous IP.......: 101dec7d (offset 20)
Frame size........: 5 (5 arguments, 0 local variables)
Argument[0].......: da2948
Argument[1].......: d9d7e8
Argument[2].......: d9d8bc
Argument[3].......: 10115c10
Argument[4].......: 0

Method............: 1016224c 'com/sun/midp/main/Main.runLocalClass (static)' Stack Chunk.......: d30590
Frame Pointer.....: d305c8
Current IP........: 101dec7d = 101dec69 + offset 20
Previous Frame....: d305a4
Previous IP.......: 101de6fc (offset 116)
Frame size........: 3 (1 arguments, 2 local variables)
Argument[0].......: da2f34
Local[1]..........: 0
Local[2]..........: 0

Method............: 101621ac 'com/sun/midp/main/Main.main (static)' Stack Chunk.......: d30590
Frame Pointer.....: d305a4
Current IP........: 101de6fc = 101de688 + offset 116
Previous Frame....: 0
Previous IP.......: 1
Frame size........: 3 (1 arguments, 2 local variables)
Argument[0].......: d3087c
Local[1]..........: da2f34
Local[2]..........: d9d920

VM status:
Instruction pointer.: 101e4c13 (offset within invoking method: 195)
Next instruction....: 0x4
Frame pointer.......: da4664
Local pointer.......: da463c
Stack size..........: 256; sp: da4678; ranges: d30598-d30798;da4584-da4784;
Contents of the current stack frame:
   da463c: d9c1f4 (lp)
   da4640: d9926c
   da4644: 0
   da4648: 1
   da464c: 0
   da4650: 65
   da4654: 0
   da4658: 65
   da465c: 0
   da4660: 0
   da4664: da4624 (fp)
   da4668: 1021a866
   da466c: da4638
   da4670: 101657ec
   da4674: da457c
   da4678: 0 (end of frame) (sp)
Execution stack contains 760 items: d3087c da2f34 d9d920 0 1 d30594 101621ac d30590 0 da2f34 0 0 d305a4 101de6fc d305b8 1016224c d30590 0 da2948 d9d7e8 d9d8bc 10115c10 0 d305c8 101dec7d d305dc 1016d890 d30590 0 da2948 d9d7e8 d9d8bc 10115c10 0 0 1010aa68 0 0 0 0 0 0 0 0 0 0 0 0 0 0 d305f4 101f14d7 d30608 1016d8b0 d30590 0 da2948 1010aa68 0 d30660 101f14e7 d30674 10185054 d30590 0 da2948 d9d7c4 d9d0b0 d9c580 d9c488 0 0 0 0 0 0 0 0 0 0 0 0 d30684 10215c1d d30698 10185034 d30590 0 d9c580 d9d0b0 d306e0 10215a7e d306f4 10174e9c d30590 d9c580 d9c580 d9d0b0 0 d30700 101fbc22 d30714 10174e5c d30590 d9c580 d9c580 d9d0b0 0 7fffffff d30724 101fbb03 d30738 10167784 d30590 0 d9c580 d9d0b0 0 7fffffff d9c518 a 1017ec1c d30590 0 0 0 0 0 d9c580 d9d0b0 0 7fffffff d9c470 0 0 0 0 0 0 0 d3074c 101e66e5 d30760 10174e7c da457c 0 d9c580 d9c470 62 a8 158 62 0 da45b4 101fbb43 da45c8 101677a4 da457c 0 d9c470 da45e8 101e67a7 da45fc 10163e1c da457c 0 d9c1f4 d9926c da4604 101e2b1f da4618 10188c50 da457c 0 d9c1f4 d9926c 0 1 0 65 0 65 0 0 da4624 1021a866 da4638 101657ec da457c 0 Execution completed.
85469 bytecodes executed
3 thread switches
738 classes in the system (including system classes)
10218 dynamic objects allocated (607936 bytes)
3 garbage collections (539608 bytes collected)
Execution completed.
85469 bytecodes executed
3 thread switches
738 classes in the system (including system classes)
10218 dynamic objects allocated (607936 bytes)
3 garbage collections (539608 bytes collected)


--- end of Sun console log ---

In the SonyEricsson SDK, if I do NOT set a breakpoint, the app runs -- puts up a set of tiles on the emulated phone screen that you can try to rearrange into words. If I set a breakpoint at, say, the constructor for the midlet class, the breakpoint is never reached and there is no crash. It just appears to hang. I left it once for 10 minutes or so, to make sure it wasn't just an execution speed problem, but my cpu is not soaked and it never seems to get to the breakpoint. Setting two breakpoints didn't help; neither did disabling both breakpoints.

Does anyone have suggestions as to what I might try next (and next and next)?

rc


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Eclipseme-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/eclipseme-users



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Eclipseme-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/eclipseme-users



--
Ben Hutchison

Lead Developer
Playscape Games
http://www.playscapegames.com


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Eclipseme-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/eclipseme-users

Reply via email to