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) Atmel Studio 6.2 win 10 error compiling (Read 12719 times)
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Atmel Studio 6.2 win 10 error compiling
Oct 11th, 2015 at 10:16am
Print Post  
Hi guys after a while absent i want to program something there is my sketch
Code (C++)
Select All
//Main Library for controller BT or USB PS3PAD
#include <PS3BT.h>
//#include <PS3USB.h>

// Library for Controlling Motors
#include <HBridge.h>
#include <usbhub.h>

// Light file
//#include "BMW_Z4_Light_TEST.h"

USB Usb;
USBHub Hubl(&Usb);
BTD Btd(&Usb);
PS3BT PS3(&Btd,0x00, 0x09, 0xDD, 0x50, 0x8F,0xC6);

//USB Usb;
//PS3USB PS3(&Usb);

int x = 200;

HBridge hb1;				//

void setup()
{
	Serial.begin(115200);
	Usb.Init();
	if (Usb.Init() == -1)
	{
		Serial.print(F("\r\nOSC did not start"));
		while(1); //halt
	}
	Serial.print(F("\r\nPS3 Bluetooth Library Started"));

	hb1.setEnablePins(3,9);
	hb1.setControlPins(40,41,42,43);
}

void loop()
{
	/*THE MANIN PROGRAM*/
	Usb.Task();
	if(PS3.PS3Connected)
	{
		MotorOnePWM();
		Serial.print(F("Polaczony"));
	}
}

/*Motor PWM*/
void MotorOnePWM()
{
	//Go Forward With L2
	if ((PS3.getAnalogButton(L2))&&!(PS3.getAnalogButton(R2)))
	{
		hb1.PWMA(PS3.getAnalogButton(L2));
		hb1.movePWMAForward();
	}

	//Go Backward With R2
	if ((PS3.getAnalogButton(R2))&&!(PS3.getAnalogButton(L2)))
	{
		hb1.PWMA(PS3.getAnalogButton(R2));
		hb1.movePWMABackward();
	}

	//Motor Stop
	if ((PS3.getAnalogButton(L2))&&(PS3.getAnalogButton(R2)))
	{
		hb1.motorAStall();
	}

	//hb1.motorAOFF();

	//Left
	if(PS3.getAnalogHat(RightHatX)<90)
	{
		hb1.PWMB(x);
		hb1.turnBRight();
	}

	//Right
	if(PS3.getAnalogHat(RightHatX)>160)
	{
		hb1.PWMB(x);
		hb1.turnBLeft();
	}

	//OFF /Reset
	hb1.motorOFF();

}
 



on win 7 arduino 1.6.5 and 1.0.5 r2 and atmel and event visual studio dont give me errors 
but when i try to compile same project on win 10 atmel studio 6.2 i get loots of errors, sketch is compiling whitout problems on arduino 1.6.5 and 1.0.5 r2 under win 10 but when i try to compileing it under 
Atmel studio with arduino 1.6.5 plugin i get this error 
Code
Select All
Compiling 'BMW_Z4' for 'Arduino/Genuino Mega w/ ATmega2560 (Mega 2560)'
	Process: "{runtime.tools.avr-gcc.path}\bin\avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=165 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\mega" W_Z4.cpp" -o W_Z4.cpp.o"
Error compiling 


and with the arduino 1.0.5 r2 i get this 
Code
Select All
Compiling 'BMW_Z4' for 'Arduino Mega 2560 or Mega ADK'
BMW_Z4.ino:13: error: 'USB' does not name a type
BMW_Z4.ino:14: error: 'USBHub' does not name a type
BMW_Z4.ino:15: error: 'BTD' does not name a type
BMW_Z4.ino:16: error: 'PS3BT' does not name a type
BMW_Z4.ino:23: error: 'HBridge' does not name a type
BMW_Z4.ino:In function 'void setup()'
BMW_Z4.ino:28: error: 'Usb' was not declared in this scope
BMW_Z4.ino:36: error: 'hb1' was not declared in this scope
BMW_Z4.ino:In function 'void loop()'
BMW_Z4.ino:43: error: 'Usb' was not declared in this scope
BMW_Z4.ino:44: error: 'PS3' was not declared in this scope
BMW_Z4.ino:In function 'void MotorOnePWM()'
BMW_Z4.ino:55: error: 'PS3' was not declared in this scope
BMW_Z4.ino:55: error: 'L2' was not declared in this scope
BMW_Z4.ino:55: error: 'R2' was not declared in this scope
BMW_Z4.ino:57: error: 'hb1' was not declared in this scope
BMW_Z4.ino:62: error: 'PS3' was not declared in this scope
BMW_Z4.ino:62: error: 'R2' was not declared in this scope
BMW_Z4.ino:62: error: 'L2' was not declared in this scope
BMW_Z4.ino:64: error: 'hb1' was not declared in this scope
BMW_Z4.ino:69: error: 'PS3' was not declared in this scope
BMW_Z4.ino:69: error: 'L2' was not declared in this scope
BMW_Z4.ino:69: error: 'R2' was not declared in this scope
BMW_Z4.ino:71: error: 'hb1' was not declared in this scope
BMW_Z4.ino:77: error: 'PS3' was not declared in this scope
BMW_Z4.ino:77: error: 'RightHatX' was not declared in this scope
BMW_Z4.ino:79: error: 'hb1' was not declared in this scope
BMW_Z4.ino:84: error: 'PS3' was not declared in this scope
BMW_Z4.ino:84: error: 'RightHatX' was not declared in this scope
BMW_Z4.ino:86: error: 'hb1' was not declared in this scope
BMW_Z4.ino:91: error: 'hb1' was not declared in this scope
Error compiling
 


this sketch compile perfect, whitout any problem on arduino programs but in atmle studio i get tons of problems
Here is the verbose for 1.6.5 plugin
Code
Select All
Compiling 'BMW_Z4' for 'Arduino/Genuino Mega w/ ATmega2560 (Mega 2560)'
Build folder: 2560
Summary: Header=1 Prototypes=4 Imports=3
Additional Defines:
Architecture Tools: {runtime.tools.avr-gcc.path}/bin/
Sketchbook: file:///C:/Users/Michał/Dropbox/Android
Core Include Paths
Include Path 'C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino'
Include Path 'C:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\mega'
"{runtime.tools.avr-gcc.path}/bin/avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=165 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\mega" W_Z4.cpp" -o W_Z4.cpp.o"
Nie można odnaleźć określonego pliku
	Process: "{runtime.tools.avr-gcc.path}\bin\avr-g++" -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=165 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" -I"C:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\mega" W_Z4.cpp" -o W_Z4.cpp.o"
Error compiling 



  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #1 - Oct 11th, 2015 at 10:17am
Print Post  
and here is the 1.0.5 r2 verbose
Code
Select All
Compiling 'BMW_Z4' for 'Arduino Mega 2560 or Mega ADK'
Build folder: file:///C:/Users/Michał/AppData/Local/V.Micro/Arduino/Builds/BMW_Z4/mega2560
Summary: Header=1 Prototypes=4 Imports=3
Additional Defines:
Architecture Tools: D:\Program Files\arduino-1.0.5-r2\hardware\tools\avr\bin\
GCC: 4.3.2
Sketchbook: file:///C:/Users/Michał/Dropbox/Android
Core Include Paths
Include Path 'D:\Program Files\arduino-1.0.5-r2\hardware\arduino\cores\arduino'
Include Path 'D:\Program Files\arduino-1.0.5-r2\hardware\arduino\variants\mega'
All import libraries will be re-compiled
D:\Program Files\arduino-1.0.5-r2\hardware\tools\avr\bin\avr-g++ -c -g -Os -fno-exceptions -ffunction-sections -fdata-sections -Wall -mmcu=atmega2560 -DF_CPU=16000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=105 -I"D:\Program Files\arduino-1.0.5-r2\hardware\arduino\cores\arduino" -I"D:\Program Files\arduino-1.0.5-r2\hardware\arduino\variants\mega" -o p.o"  p"
BMW_Z4.ino:3:19: warning: PS3BT.h: No such file or directory
BMW_Z4.ino:2:21: warning: HBridge.h: No such file or directory
BMW_Z4.ino:3:20: warning: usbhub.h: No such file or directory
BMW_Z4.ino:13: error: 'USB' does not name a type
BMW_Z4.ino:14: error: 'USBHub' does not name a type
BMW_Z4.ino:15: error: 'BTD' does not name a type
BMW_Z4.ino:16: error: 'PS3BT' does not name a type
BMW_Z4.ino:23: error: 'HBridge' does not name a type
BMW_Z4.ino:In function 'void setup()'
BMW_Z4.ino:28: error: 'Usb' was not declared in this scope
BMW_Z4.ino:31: warning: only initialized variables can be placed into program memory area
BMW_Z4.ino:34: warning: only initialized variables can be placed into program memory area
BMW_Z4.ino:36: error: 'hb1' was not declared in this scope
BMW_Z4.ino:In function 'void loop()'
BMW_Z4.ino:43: error: 'Usb' was not declared in this scope
BMW_Z4.ino:44: error: 'PS3' was not declared in this scope
BMW_Z4.ino:47: warning: only initialized variables can be placed into program memory area
BMW_Z4.ino:In function 'void MotorOnePWM()'
BMW_Z4.ino:55: error: 'PS3' was not declared in this scope
BMW_Z4.ino:55: error: 'L2' was not declared in this scope
BMW_Z4.ino:55: error: 'R2' was not declared in this scope
BMW_Z4.ino:57: error: 'hb1' was not declared in this scope
BMW_Z4.ino:62: error: 'PS3' was not declared in this scope
BMW_Z4.ino:62: error: 'R2' was not declared in this scope
BMW_Z4.ino:62: error: 'L2' was not declared in this scope
BMW_Z4.ino:64: error: 'hb1' was not declared in this scope
BMW_Z4.ino:69: error: 'PS3' was not declared in this scope
BMW_Z4.ino:69: error: 'L2' was not declared in this scope
BMW_Z4.ino:69: error: 'R2' was not declared in this scope
BMW_Z4.ino:71: error: 'hb1' was not declared in this scope
BMW_Z4.ino:77: error: 'PS3' was not declared in this scope
BMW_Z4.ino:77: error: 'RightHatX' was not declared in this scope
BMW_Z4.ino:79: error: 'hb1' was not declared in this scope
BMW_Z4.ino:84: error: 'PS3' was not declared in this scope
BMW_Z4.ino:84: error: 'RightHatX' was not declared in this scope
BMW_Z4.ino:86: error: 'hb1' was not declared in this scope
BMW_Z4.ino:91: error: 'hb1' was not declared in this scope
Error compiling
 


Could it be because VM plugin dont recognize my folder name? Can any one advice?
« Last Edit: Oct 11th, 2015 at 10:19am by THX_RoG »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #2 - Oct 11th, 2015 at 10:44am
Print Post  
Hi,

1) 1.0.5
Please remove the commented includes such as //#include "BMW_Z4_Light_TEST.h" and see if it works.

2) 1.6.5
Please confirm you have configured 1.6.5 as the Arduino 1.6 application in Visual Micro?

Thanks

  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #3 - Oct 11th, 2015 at 11:49am
Print Post  
Tim@Visual Micro wrote on Oct 11th, 2015 at 10:44am:

1) 1.0.5
Please remove the commented includes such as //#include "BMW_Z4_Light_TEST.h" and see if it works.


2) 1.6.5
Please confirm you have configured 1.6.5 as the Arduino 1.6 application in Visual Micro?


1)
there are my var to control light so if i use it or not it should not have that big impact on the sketch.

2)
yes, u mean there were i put arduino 1.6.5, then yes they are the same.
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #4 - Oct 11th, 2015 at 12:30pm
Print Post  
Hi,

For 1.6.5, I am asking the name of the app you have selected in Visual Micro. The options are 1.0.x, 1.5, 1.6?

For 1.0.5 can you please open the arduino ide and click file>preferences and confirm what you have entered for the  sketchbook location?

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


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #5 - Oct 11th, 2015 at 12:41pm
Print Post  
a ok now i get it 1,6,5 is on the 1,6 and in both arduino version i have the same location folder and in vm its the same so its something with vm probably, i now u where having some problems with file names, did u manage to get it to work?
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #6 - Oct 11th, 2015 at 1:24pm
Print Post  
Most users seems to be working okay with a wide variety of arduino ide's. That includes windows 10 users. 

You have the same confg working on win7 so it must be a version issue somewhere

I can say that if you see "{runtime.tools.avr-gcc.path}" when trying to compile this means that Visual Micro does not believe that it has to apply some new rules that we published in arduino 1.6.2 version and above.

I suggest you download the current release of the arduino ide as a ZIP and unload into somewhere other than your program files\arduino installation. That way we will have a clean arduino 1.6 ide. Don't forget to change the location in the visual micro ide locations dialog.

Please also confirm the visual micro version you are using from tools>options>visual micro>version + minor. Do this for both your win7 and win10 installations.

It would also be more helpful to see the full build output which you can email. To switch on full output enable "tools>options>visual micro>compiler>show build proeprties". Then click "Build>clean solution" then build and email the output to info [at] visualmicro.com

Confirm the name(s) and folder paths of libraries that contain PS3BT.h, HBridge.h, UsbHub.h

Confirm the expected libraries appear in the "Project>add/import sketch library>user" list


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


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #7 - Oct 12th, 2015 at 5:35pm
Print Post  
ok output data is on the weight to you, and yes i have on win7 and win 10 the latest vm plugin the version nr is 1.1508.30
and atmel dont see my local usser lib, on both arduino versions and the updadate buttnon dont change a thing, 
on istalation i did get a window that says
Code
Select All
Visual Micro
Registry Key not found C:\Program Files (x86)\Visual Micro\Visual Micro for Arduino\,
Software\Microsoft\VisualStudio\10.0\AutomationOptions\LooklnFolders
 


and it poops 3 times can this bee the issue?
« Last Edit: Oct 12th, 2015 at 5:36pm by THX_RoG »  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #8 - Oct 12th, 2015 at 8:35pm
Print Post  
ok found one problem but now i get bit more problems.
Atmel Studio and VM one arduino 1.0.5 r2 compiler work perfect not a single error but 
now on the 1.6 i get bit more, i send you the output via email. And now i says that some 
file are missing, but it has
same sketch folder as the 1.0.5r2, so what he need now?
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #9 - Oct 14th, 2015 at 12:24pm
Print Post  
Can you please grab the current arduino release which is 1.6.5-r2 and try that thanks
  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #10 - Oct 14th, 2015 at 1:09pm
Print Post  
i have download the 1.6.5-r5.zip and i have same problem, 
can it be because i have one installed (its the 1.6.5-r5) and one is zip download (the1.0.5-r2). 
And on the 1.6.3 works fine, so i guess is something with my PC then?
« Last Edit: Oct 14th, 2015 at 1:59pm by THX_RoG »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #11 - Oct 14th, 2015 at 1:20pm
Print Post  
I don't think it's pc.

There error suggests that the file [arduino_ide]\hardware\platform.keys.rewrite.txt can't be found. If it is found visual micro should automatically use the new build system which knows about properties such as {runtime.tools.avr-gcc.path}

I suggest unpacking the zip of arduino 1.6.5r2 into a simple folder such as c:\arduino\arduino16 then configuring visual micro to look at that.
  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: Atmel Studio 6.2 win 10 error compiling
Reply #12 - Oct 14th, 2015 at 2:01pm
Print Post  
i try putting it to different locations but still i get this error,
Have another question dose VM read \AppData\Roaming\Arduino15\preferences.txt file? 
if so can it be that i have some problems reeding my users name?, i ask this
because on the booth Arduino IDE 1.0.5-r2 and 1.6.3 its reading the file corect and on 1.6.5-r2,
have this mark "�" and a folder where's nothing in it but only the preferences.txt file.
i try to copy the missing files to there but still i get this error
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12188
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Atmel Studio 6.2 win 10 error compiling
Reply #13 - Oct 14th, 2015 at 2:05pm
Print Post  
It might be that but I don't see a difference between 1.6.3 and 1.6.5
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint