|
Page 1 of 1
|
[ 7 posts ] |
|
nxtDisplay... strings cause Click of Death in 3.62
Author |
Message |
kfilar
Rookie
Joined: Fri Nov 19, 2010 3:34 pm Posts: 14
|
 nxtDisplay... strings cause Click of Death in 3.62
On 2 different bricks, the following code works fine in RobotC for Mindstorms +Tetrix 3.55, but causes the NXT Click of Death in 3.62: The following code, changing the line 1 parameter from a string to a string variable, fixes it: Could you shed some light on what's going on? Are you able to reproduce this? Thanks,
|
Wed Dec 25, 2013 2:29 pm |
|
 |
mightor
Site Admin
Joined: Wed Mar 05, 2008 8:14 am Posts: 3654 Location: Rotterdam, The Netherlands
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
A bug it may be, but why would you use nxtDisplayBigTextLine(1, "%s", "Test"); and not nxtDisplayBigTextLine(1, "Test"); ?
= Xander
_________________| Professional Conduit of Reasonableness| (Title bestowed upon on the 8th day of November, 2013) | My Blog: I'd Rather Be Building Robots| ROBOTC 3rd Party Driver Suite: [ Project Page]
|
Wed Dec 25, 2013 5:31 pm |
|
 |
kfilar
Rookie
Joined: Fri Nov 19, 2010 3:34 pm Posts: 14
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
Well, eliminating the "%s" is certainly how we'll fix our code.
That seems to be the only issue with 3.62 we've found so far.
FTC 6002
|
Fri Dec 27, 2013 12:19 pm |
|
 |
mightor
Site Admin
Joined: Wed Mar 05, 2008 8:14 am Posts: 3654 Location: Rotterdam, The Netherlands
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
It's deffo a bug, however, it's easy to work around it  = Xander
_________________| Professional Conduit of Reasonableness| (Title bestowed upon on the 8th day of November, 2013) | My Blog: I'd Rather Be Building Robots| ROBOTC 3rd Party Driver Suite: [ Project Page]
|
Fri Dec 27, 2013 12:46 pm |
|
 |
kfilar
Rookie
Joined: Fri Nov 19, 2010 3:34 pm Posts: 14
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
Easy to work around, but a nasty one though. Compiles just fine. It's only when your code runs across that statement that it goes into the click of death with very little to hint at what happened.
|
Sat Dec 28, 2013 10:08 am |
|
 |
Ford Prefect
Guru
Joined: Sat Mar 01, 2008 12:52 pm Posts: 1030
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
then you're quite lucky to have RobotC to program with, getting even "very little to hint at what happened". I just got a few steps of experience with "real" C. Here you do not even get the slightest hint when everything just dissolves into nothingness. 
_________________ regards, HaWe aka Ford #define S sqrt(t+2*i*i)<2 #define F(a,b) for(a=0;a<b;++a) float x,y,r,i,s,j,t,n;task main(){F(y,64){F(x,99){r=i=t=0;s=x/33-2;j=y/32-1;F(n,50&S){t=r*r-i*i;i=2*r*i+j;r=t+s;}if(S){PutPixel(x,y);}}}while(1)}
|
Sat Dec 28, 2013 10:28 am |
|
 |
mightor
Site Admin
Joined: Wed Mar 05, 2008 8:14 am Posts: 3654 Location: Rotterdam, The Netherlands
|
 Re: nxtDisplay... strings cause Click of Death in 3.62
Ford,
With remote gdb you can do it, but you'd have to learn how to use this very powerful (and hard to use) tool. ROBOTC's debugger is much easier to use. When I have issues like this, I will often leave "breadcrumbs" as I go through the program, using writeDebugStreamLine();
= Xander
_________________| Professional Conduit of Reasonableness| (Title bestowed upon on the 8th day of November, 2013) | My Blog: I'd Rather Be Building Robots| ROBOTC 3rd Party Driver Suite: [ Project Page]
|
Sat Dec 28, 2013 10:39 am |
|
|
|
Page 1 of 1
|
[ 7 posts ] |
|
Who is online |
Users browsing this forum: No registered users and 2 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|