Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic problem with Serial.print (Read 4307 times)
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
problem with Serial.print
May 11th, 2013 at 6:53pm
Print Post  
sup guys long time no see today i was trying to upload a modifying sketch to mega but i get this error:
Code
Select All
Compiling 'encoder' for 'Arduino Mega 2560 or Mega ADK'
crtm2560.o : : In function `__vector_default':
(.vectors+0x5c)* : : relocation truncated to fit: R_AVR_13_PCREL against symbol `__vector_23' defined in .text.__vector_23 section in wiring.c.o)
avr-objcopy* : : r.elf': No such file
avr-objcopy* : : r.elf': No such file
Couldn't determine program size:
 


im geting this error if i change this line 
Code
Select All
Serial.print(encoder0Pos);
Serial.print("/");
 


to this its slight different
Code
Select All
Serial.print("Encoder POS = ");
Serial.println(encoder0Pos);
 

 
so what im doing wrong
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: problem with Serial.print
Reply #1 - May 11th, 2013 at 7:30pm
Print Post  
Hi,

Do you get the same error if you try to compile with the Arduino ide?

  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: problem with Serial.print
Reply #2 - May 11th, 2013 at 8:04pm
Print Post  
yes but if i change the line to this 
Code
Select All
Serial.println("Encoder POS = ");
Serial.print(encoder0Pos);
 


both arduina and VS dont display this error
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: problem with Serial.print
Reply #3 - May 11th, 2013 at 8:56pm
Print Post  
Okay, if you get the same error in the arduino ide then you can ask the question in the arduino.cc/forum where you will find clever people who know these answers  Grin
  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint