ROBOTC.net forums
http://www.robotc.net/forums/

Write Debug Sream doesn't seem to work
http://www.robotc.net/forums/viewtopic.php?f=62&t=5251
Page 1 of 1

Author:  fretless_kb [ Wed Dec 12, 2012 11:38 pm ]
Post subject:  Write Debug Sream doesn't seem to work

I can write Strings, but when I try to format an int as output I get garbage.
for instance:
writeDebugStreamLine("Starting...");

works fine I get the string Starting...

But If I try a simple formatted output with Int's I get garbage.
hours =1;minutes =2;seconds=3;
writeDebugStreamLine("\n%d:%d:%d ",hours,minutes,seconds);
yielded
-515:0:3369

it should be 1:2:3

What's up with writedebugstring?

Author:  amcerbu [ Thu Dec 13, 2012 2:47 am ]
Post subject:  Re: Write Debug Sream doesn't seem to work

I'm not sure the new line escape sequence \n is supported. I could well be wrong, but try removing that and see if the bug persists.

Author:  tfriez [ Thu Dec 13, 2012 4:41 pm ]
Post subject:  Re: Write Debug Sream doesn't seem to work

This is specifically a bug in the ROBOTC for Arduino system. Because the Atmel/ATMEGA processors use only two-byte indices for the VM, whereas all other platforms (excluding PIC) use four-byte.

We should have a fix for this early next week in BETA form.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/