Page 1 of 1

NXC OVERLOAD!

Posted: 30 Dec 2010, 02:15
by dudmaster
Hello,

I have been working on a TextEdit v8 [see The Current Version] and i got to over 1090 lines, and it freezes my NXT when downloading. Why?

Re: NXC OVERLOAD!

Posted: 30 Dec 2010, 04:22
by m-goldberg
Why, indeed. Could it be that your program has reached the size where it will no longer fit in your NXT's memory?

Re: NXC OVERLOAD!

Posted: 30 Dec 2010, 04:47
by mattallen37
Try removing some programs and such from the NXT, and then try again.

Re: NXC OVERLOAD!

Posted: 30 Dec 2010, 14:44
by dudmaster
I have the compiler status turned on, and it just "forgets" to download the program, and that causes the NXT to freeze

Re: NXC OVERLOAD!

Posted: 30 Dec 2010, 17:26
by m-goldberg
I can not conceive how not downloading a program could have any effect on the NXT brick whatsoever. If nothing is downloaded at the end of a compilation, then surely the NXT brick's state is exactly what is was before the you did the compilation. Why would the NXT "freeze" if nothing changed?

On the other hand, having a download fail before it was complete might be a real problem. Are you sure that this isn't what is happening?

Re: NXC OVERLOAD!

Posted: 31 Dec 2010, 04:34
by muntoo
dudmaster wrote:Hello,

I have been working on a TextEdit v8 [see The Current Version] and i got to over 1090 lines, and it freezes my NXT when downloading. Why?
Try compiling first, then download the .rxe file. Go to Edit->Preferences->General->Save compiler output, and check it.

My SnakeWorm v1.0 has ~2K lines, and nxtboy_iii's NXT War Game* is huge. You can prevent the code from getting too large by setting the optimization level of the compiler to 2. Do this by: Edit->Preferences->Compiler->NBC/NXC->Optimization Level to "2".

Also I've seen a timeout option somewhere. I'll update with more info soon.
EDIT: Go to Edit->Preferences->Compiler->Common and increase the Timeout value until it compiles properly.

*Disclaimer: Not as good as COD. Mmmm... fish.

Re: NXC OVERLOAD!

Posted: 31 Dec 2010, 17:35
by dudmaster
I have already set it to Level 2.



*Fish with hot-sauce!

Re: NXC OVERLOAD!

Posted: 31 Dec 2010, 18:50
by muntoo
dudmaster wrote:I have already set it to Level 2.
Did you try the timeout? Set it to 99, or something:
muntoo wrote:Also I've seen a timeout option somewhere. I'll update with more info soon.
EDIT: Go to Edit->Preferences->Compiler->Common and increase the Timeout value until it compiles properly.

Re: NXC OVERLOAD!

Posted: 01 Jan 2011, 18:54
by dudmaster
What does that do?