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 Arduino Constant = 10 on VS2012 (Read 2998 times)
Andres
Newbies
*
Offline


Posts: 1
Location: California
Joined: Dec 1st, 2012
Arduino Constant = 10 on VS2012
Dec 1st, 2012 at 10:26pm
Print Post  
I had a strange thing happen when first installing Visual Micro on VS2012. I am running Windows 7 and recently installed VS2012.
The steps are as follows:

1. Installed Visual Micro.
2. Opened existing and working code.ino in Arduino IDE and compiled OK.
3. Opened same code in VS 2012 as Arduino project.
4. Code failed with errors because the Arduino constant was set to 10 (I had Arduino Uno selected from the drop down.
Here is the compiler directive:

avr-g++ -c -g -Os -Wall -fno-exceptions -ffunction-sections -fdata-sections -mmcu=atmega328p -DF_CPU=16000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=10 -DVISUALMICRO_COMPILER_VER=1 

As you can see the Aduino constant was being set to 10 instead of 101.

I tried several things and cold not get the constant to the correct value. I finally changed the version.txt in the Arduino/lib directory from 1.0.1 to 100 and everything started working OK. After compiling and testing OK, I changed the version.txt back to 1.0.1 and it works OK now.

The setting now shows up as:

avr-g++ -c -g -Os -Wall -fno-exceptions -ffunction-sections -fdata-sections -mmcu=atmega328p -DF_CPU=16000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=100 -DVISUALMICRO_COMPILER_VER=1 


Not sure what happened, but just in case this happens to someone else.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Arduino Constant = 10 on VS2012
Reply #1 - Dec 1st, 2012 at 10:33pm
Print Post  
Thanks for the report. I'll look into that. 

One or two users have reported that first compile of the day or of a new project fails. It never happens to me but this might be related.

I think I will now be able to track this down and fix it for the next version.
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint