NXJ 0.4.0 Beta Bug Watch
Moderators: imaqine, 99jonathan, roger
NXJ 0.4.0 Beta Bug Watch
leJOS 0.4 is out! The big additions are:
- An amazing set of widgets and graphics classes in the java.microedition.lcdui package.
- NXT to NXT communications
Our main focus will now change from adding functionality to improving things. We have a list of bugs to squash and we also want to make NXJ a whole lot easier to install and use. So the big additions in the future will probably be:
- An Eclipse plugin that installs NXJ in one go and adds user friendly buttons and menu commands.
- A graphical menu interface for NXJ to replace the text only menu
0.4 isn't thoroughly tested, so if you find bugs or errors in our documentation, please let us know in this thread.
- An amazing set of widgets and graphics classes in the java.microedition.lcdui package.
- NXT to NXT communications
Our main focus will now change from adding functionality to improving things. We have a list of bugs to squash and we also want to make NXJ a whole lot easier to install and use. So the big additions in the future will probably be:
- An Eclipse plugin that installs NXJ in one go and adds user friendly buttons and menu commands.
- A graphical menu interface for NXJ to replace the text only menu
0.4 isn't thoroughly tested, so if you find bugs or errors in our documentation, please let us know in this thread.
nxjc.bat file
Hi, I be testing 0.4 beta release and notice (at least for me) an error in the file nxjc.bat:
does not have " to enclose CLASSPATH path, that caused for me an error when I try to compile. In the version 0.3 there are " enclosing CLASSPATH route, and that works fine, so i've changed that line to:
and all work for me.
javac -source 1.3 -target 1.1 -bootclasspath %NXJ_HOME%\lib\classes.jar;%CLASSPATH% %*
does not have " to enclose CLASSPATH path, that caused for me an error when I try to compile. In the version 0.3 there are " enclosing CLASSPATH route, and that works fine, so i've changed that line to:
javac -source 1.3 -target 1.1 -bootclasspath "%NXJ_HOME%\lib\classes.jar;%CLASSPATH%" %*
and all work for me.
Naguara, cosa tan wena!
I've had a problem accessing protected fields from a subtype. My seup was something like this
The value change from the subclass did not become visible in the superclass. I changed the code to use private properties and setters in the superclass, and that worked. I havnt had time to do further experimentation or a proper testcase yet, but hope to get that done tommorow if it hasnt been looked already at then.
Code: Select all
public class OuterClass{
private abstract class InnerSuperclass{
protected int value;
public void useValue(){
//Used value here
}
}
private class InnerSubclass{
public changeValue(){
value = 5;
}
}
}
The value change from the subclass did not become visible in the superclass. I changed the code to use private properties and setters in the superclass, and that worked. I havnt had time to do further experimentation or a proper testcase yet, but hope to get that done tommorow if it hasnt been looked already at then.
Just to confirm. I ran into this issue again today, and I had of course forgotten all about it, so took an hour to track the issue down inside my logging tool. The setup was, with non-related details remove:
The above code produced an error number 6 (NoSuchMethodError), when invocation reaced nxtOut.writeByte(....); Ive worked around it by saving a private reference to the instance in all classes that needs it, but its a very annoying bug to run into, since you dont really catch things that go against the java semantics when you look through your code
Code: Select all
public abstract class BaseChannel{
protected DataOutputStream nxtOut;
public BaseChannel(DataOutputStream nxtOut){
this.nxtOut = nxtOut;
}
}
public class SomeChannel extends BaseChannel{
public SomeChannel(DataOutputStream nxtOut){
super(nxtOut);
}
public writeAndReset(){
nxtOut.writeByte(....);
}
}
The above code produced an error number 6 (NoSuchMethodError), when invocation reaced nxtOut.writeByte(....); Ive worked around it by saving a private reference to the instance in all classes that needs it, but its a very annoying bug to run into, since you dont really catch things that go against the java semantics when you look through your code

Hi,
I am having a similar problem, see viewtopic.php?t=540.
Would you explain how you set a private reference, and to what?
Cheers,
Rupert
I am having a similar problem, see viewtopic.php?t=540.
Would you explain how you set a private reference, and to what?
Cheers,
Rupert
Trouble getting started
Hi
I'm new to Java and the NXT, and I am stuck on compiling my code.
At first javac could not be found but I fixed that problem by downloading a old SDK from http://www.sun.com
I still have two problems, I'm trying to use Eclipse and javac. When I try to compile my code I get an error message from Javac to say the source can't be found. How does Eclipse tell Javac the source file name?
Having failed with Eclipse I tried compiling the Tune example from the Maximum NXT book, and it appeared to compile OK, but insead of the Tune.lej file the book said I should get I got a Tune.class file. Can anyone help me get started please ?
Thank you
I'm new to Java and the NXT, and I am stuck on compiling my code.
At first javac could not be found but I fixed that problem by downloading a old SDK from http://www.sun.com
I still have two problems, I'm trying to use Eclipse and javac. When I try to compile my code I get an error message from Javac to say the source can't be found. How does Eclipse tell Javac the source file name?
Having failed with Eclipse I tried compiling the Tune example from the Maximum NXT book, and it appeared to compile OK, but insead of the Tune.lej file the book said I should get I got a Tune.class file. Can anyone help me get started please ?
Thank you
Help Compile still not working
Hi
When I tried to compile Tune.java the way the readme told me to do I got the message.
I don't know what is happening so can sombody please help me.
Thank you
When I tried to compile Tune.java the way the readme told me to do I got the message.
if "" == "" goto homeless
The system cannot find the batch label specified - homeless
I don't know what is happening so can sombody please help me.
Thank you
It Works!
Hi
Sorry I am replying so late, I was away.
I had set the NXJ_HOME variable
I found how to compile my code without getting all my error messages
I found the anwser on
http://www.bartneck.de/work/education/m ... index.html
I found out you don't have to use lejosjc.bat and nxjc.bat files.
Thanks for all your help
Sorry I am replying so late, I was away.
I had set the NXJ_HOME variable
I found how to compile my code without getting all my error messages
I found the anwser on
http://www.bartneck.de/work/education/m ... index.html
I found out you don't have to use lejosjc.bat and nxjc.bat files.
Thanks for all your help
About the reported bug with nxjc.bat not having quotation marks around classpath setting...
I run XP and have the same problem. You will not see the problem unless you have a classpath with white space inside it.
Try with CLASSPATH=.;C:\Program files\My\Little\Library
Problem solved the way the original bug reporter demonstrated.
bbagnall wrote:Can you tell me what operating system you are using? It works fine for Windows XP but I don't think we checked with other versions of Windows.
I run XP and have the same problem. You will not see the problem unless you have a classpath with white space inside it.
Try with CLASSPATH=.;C:\Program files\My\Little\Library
Problem solved the way the original bug reporter demonstrated.
Re: NXJ 0.4.0 Beta Bug Watch
where can I download this version
Who is online
Users browsing this forum: No registered users and 0 guests