To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.javaOpen lugnet.robotics.rcx.java in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / Java / 177
176  |  178
Subject: 
Re: What is exception "StackOverflowError" in method "<clinit>"
Newsgroups: 
lugnet.robotics.rcx.java
Date: 
Thu, 23 May 2002 12:58:25 GMT
Viewed: 
4169 times
  
"fredsiva" <frederic.siva@wanadoo.be> writes:

Yes, you are both right (Thanks anyway)
1. TextLCD.print() works perfectly when called from simple programs
2. My code is most probably using too deep calls (Why is this not covered in
the 10/10 'Core' book of Bagnall)

BUT, QUESTION FOR YOU ALL:

From the following sample code,
how can you explain that the failing instruction
      TextLCD.print(title) in menuChoice2()
suddently works if you call another method of the same class before ?
Is there some caching or inline code triggered in some way ?

The first time a method is called the class gets initialized,
and the stack overflow happened in the initialization method
<clinit>, so nothing mysterious there.

While you debug my code (hey, LEGO is a game no ?), I am searching why
another big program starts one of my motors very very slowly without me
asking for it, I guess I am now facing a memory corruption or something like
that.

If your program uses a lot of memory (less than 3K free)
this is a side effect of writing to memory.

Jürgen

--
Jürgen Stuber <stuber@loria.fr>
http://www.loria.fr/~stuber/



Message is in Reply To:
  Re: What is exception "StackOverflowError" in method "<clinit>"
 
(...) Yes, you are both right (Thanks anyway) 1. TextLCD.print() works perfectly when called from simple programs 2. My code is most probably using too deep calls (Why is this not covered in the 10/10 'Core' book of Bagnall) BUT, QUESTION FOR YOU (...) (23 years ago, 22-May-02, to lugnet.robotics.rcx.java)

5 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR