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
Hot Topic (More than 8 Replies) Error compiling using Arduino 1.5.7 (Read 9969 times)
marc
Junior Member
**
Offline


Posts: 12
Location: Belgium
Joined: Jan 29th, 2012
Error compiling using Arduino 1.5.7
Sep 18th, 2014 at 5:58pm
Print Post  
Hello,

Using Arduino 1.5.7 gives me a compiling error.
Compiling without using Visual Studio, no problems
Using version 1.5.6-r2 no problems
I am using the latest version of Visual Micro (1407.10 sp2)
I also did a reset of the user interface and a reload of the tool chain.
What could be the problem?

Regards,

Marc

-------------------------------------------------------------------

Compiling 'Blink' for 'Arduino Mega w/ ATmega2560 (Mega 2560)'
Build folder: file:///C:/Users/Marc/AppData/Local/VMicro/Arduino/Builds/Blink/mega_atmega2560
Summary: Header=1 Prototypes=3 Imports=0
Additional Defines: VISUALMICRO_COMPILER_VER=1;
Architecture Tools: C:\arduino-1.5.7/hardware/tools/avr/bin/
GCC: 4.8.1
Sketchbook: file:///C:/Users/Marc/Documents/Arduino
Core Include Paths
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino'
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\variants\mega'
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=157 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino" -I"C:\arduino-1.5.7\hardware\arduino\avr\variants\mega" pp" -o pp.o" -DVISUALMICRO_COMPILER_VER=1
Error compiling

-------------------------------------------------------------------
« Last Edit: Sep 18th, 2014 at 6:01pm by marc »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #1 - Sep 18th, 2014 at 7:33pm
Print Post  
Hi,

Thanks for the clear report. This is a known issue for a couple of users who have other applications installed that conflict with the current version of cygwin.exe (that is part of the Arduino Ide tool chain).

The 1.5.7 Arduino includes a new gcc toolchain that works slightly differently to previous versions on windows. We initial found that the toolchain could not locate the cygwin because the Arduino Ide installs it into two different folders.

When Visual Micro runs the tool chain it ensures that the PATH environment variable is extended to include the location of the Arduino Ide/cygwin program. (fyi: the PATH change is localized to the execution of the tool chain and is not written back to your Computer>Environment settings)

This has worked for most people but it doesn't work if your pc already has a folder in the global or user PATH environment variable.

In the next release Visual Micro will append the Arduino cygwin location to the PATH variable so that the Arduino version of cygwin takes priority, during the compile, over any other software on your pc.

The should be an sp3 with a fix shortly or you can use this info to add the arduinoexe folder to your PATH.

Thanks
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #2 - Sep 20th, 2014 at 11:45am
Print Post  
  
Back to top
IP Logged
 
marc
Junior Member
**
Offline


Posts: 12
Location: Belgium
Joined: Jan 29th, 2012
Re: Error compiling using Arduino 1.5.7
Reply #3 - Sep 21st, 2014 at 7:44am
Print Post  
Hello,


Still the same problem.


************************************************

Compiling 'Blink' for 'Arduino Mega w/ ATmega2560 (Mega 2560)'
Build folder: file:///C:/Users/Marc/AppData/Local/VMicro/Arduino/Builds/Blink/mega_atmega2560
Summary: Header=1 Prototypes=3 Imports=0
Additional Defines: VISUALMICRO_COMPILER_VER=1;
Architecture Tools: C:\arduino-1.5.7/hardware/tools/avr/bin/
GCC: 4.8.1
Sketchbook: file:///C:/Users/Marc/Documents/Arduino
Core Include Paths
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino'
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\variants\mega'
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=157 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino" -I"C:\arduino-1.5.7\hardware\arduino\avr\variants\mega" pp" -o pp.o" -DVISUALMICRO_COMPILER_VER=1
Error compiling

*********************************************

Regards,


Marc
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #4 - Sep 21st, 2014 at 4:04pm
Print Post  
Thanks for the feedback. I will try setting the working directory instead of the path. I will also report it to Arduino because it shouldn't be so cumbersome. A simple part of the build process running the gcc programs!

Can you please show your PATH from windows environment variables so I can try to replicate. 

Thanks

More shortly.
  
Back to top
IP Logged
 
marc
Junior Member
**
Offline


Posts: 12
Location: Belgium
Joined: Jan 29th, 2012
Re: Error compiling using Arduino 1.5.7
Reply #5 - Sep 24th, 2014 at 5:50pm
Print Post  
Hello,

PATH settings:

C:\Users\Marc>path
ogram Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;c:\Program Files (x86)\NVIDIA ;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Broadcom\Broadcom 802.11\Driver;C:\Program Files\WIDCOMM\Bluetooth Software\;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files (x86)\Common Files\Ulead Systems\MPEG;C:\Program Files (x86)\Common Files\DivX Shared\;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files\IVI Foundation\VISA\Win64\Bin\;C:\Program Files (x86)\IVI Foundation\VISA\WinNT\Bin\;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Users\Marc\AppData\Roaming\npm;C:\Program Files (x86)\nodejs\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Windows Kits\8.0\Windows Performance Toolkit\;C:\Program Files (x86)\QuickTime\QTSystem\;C:\FPC\2.4.0\bin\i386-Win32;C:\Program Files (x86)\Atmel\Flip 3.4.3




Regards,

Marc
« Last Edit: Sep 24th, 2014 at 5:52pm by marc »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #6 - Sep 24th, 2014 at 5:58pm
Print Post  
Thanks. It's interesting to see you have winavr installed. I will also try that to see if it causes the problem.

Arduino 1.5.7 contains a new updated avr toolchain so it will be something like this that is causing the wrong programs to be found on your pc. It might be that Visual Micro needs to set a working directory to either the arduino folder or the tool chain folder when attempting to run the build command. 

I know Visual Micro already sets the working directory however I can recall off the top of my head which folder it sets.

You should be able to replicate the error by running it in the windows cmd.exe

Code
Select All
C:\arduino-1.5.7/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD -mmcu=atmega2560 - F_CPU=16000000L -DARDUINO=157 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino" -I"C:\arduino-1.5.7\hardware\arduino\avr\variants\mega" pp" -o pp.o" -DVISUALMICRO_COMPILER_VER=1 



Would you please try adding the following to your Path statement as a test. I think you should add it to the start of the path variable

Code
Select All
C:\arduino-1.5.7/hardware/tools/avr/bin;C:\arduino-1.5.7 



Thanks
« Last Edit: Sep 24th, 2014 at 5:59pm by Tim@Visual Micro »  
Back to top
IP Logged
 
marc
Junior Member
**
Offline


Posts: 12
Location: Belgium
Joined: Jan 29th, 2012
Re: Error compiling using Arduino 1.5.7
Reply #7 - Sep 25th, 2014 at 7:44pm
Print Post  
Hello,

So far so good, it seems to work now, thx.

Verbose dump:

Compiling 'Blink' for 'Arduino Mega w/ ATmega2560 (Mega 2560)'
Build folder: file:///C:/Users/Marc/AppData/Local/VMicro/Arduino/Builds/Blink/mega_atmega2560
Summary: Header=1 Prototypes=3 Imports=0
Additional Defines: VISUALMICRO_COMPILER_VER=1;
Architecture Tools: C:\arduino-1.5.7/hardware/tools/avr/bin/
GCC: 4.8.1
Sketchbook: file:///C:/Users/Marc/Documents/Arduino
Core Include Paths
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino'
Include Path 'C:\arduino-1.5.7\hardware\arduino\avr\variants\mega'
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=157 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\arduino-1.5.7\hardware\arduino\avr\cores\arduino" -I"C:\arduino-1.5.7\hardware\arduino\avr\variants\mega" pp" -o pp.o" -DVISUALMICRO_COMPILER_VER=1
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-gcc" -w -Os -Wl,--gc-sections -mmcu=atmega2560 -o lf" pp.o"  "-LC:\Users\Marc\AppData\Local\VMicro\Arduino\Builds\Blink\mega_atmega2560" -lm
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-objcopy" -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 lf" ep"
"C:\arduino-1.5.7/hardware/tools/avr/bin/avr-objcopy" -O ihex -R .eeprom lf" ex"
Binary sketch size: 1.620 bytes (used 1% of a 258.048 byte maximum) (0,69 secs)
Minimum Memory Usage: 9 bytes (0% of a 8192 byte maximum)

Regards,

Marc
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #8 - Sep 26th, 2014 at 11:22am
Print Post  
Great thanks for testing it, must have been the winavr. I will force both the arduino tools and ide folders into the path during compile.
« Last Edit: Sep 26th, 2014 at 11:22am by Tim@Visual Micro »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Error compiling using Arduino 1.5.7
Reply #9 - Jan 11th, 2015 at 2:54am
Print Post  
Resolved in 1412.10 sp4 (beta)
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint