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) [Visual Studio 2010]Couldn't determine program size (Read 17768 times)
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
[Visual Studio 2010]Couldn't determine program size
Nov 3rd, 2012 at 9:02pm
Print Post  
hey guys have some problem with VS i cant build my solution im getting this error
Code
Select All
Compiling 'H-Bridge' for 'Arduino Mega 2560 or Mega ADK'
core.a(main.cpp.o)* : : In function `main':
main.cpp : undefined reference to `setup'
main.cpp : undefined reference to `loop'
avr-objcopy* : : ': No such file
avr-objcopy* : : ': No such file
Couldn't determine program size: 


on arduino its compiling without any issue and this is my second project in Vs and the last(fist) build without any problem can some one help
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #1 - Nov 3rd, 2012 at 9:42pm
Print Post  
Hi,

Thanks for registering, the arduino forum is very slow at times and it's also difficult to manage the threads.

Some questions...

Are you using arduino 1.0.1?

Have you tried to re-start vs?

Is your vm options pointing to the same arduino exe that compiles correctly?

Does your main sketch file include "void setup() {}" and "void loop() {}" functions?

Based on your answers I'll either have more questions or a solution

Thanks

ps: Please email or post the source of the H-bridge.ino or pde
« Last Edit: Nov 3rd, 2012 at 9:48pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #2 - Nov 3rd, 2012 at 10:26pm
Print Post  
wow that was quick 
yes im using arduino 1.0.1
yes restarting did int help
im using win7x64 VS2010 and win8x64 VS2012 and the same problem appear but not in arduino it take some time but it compile without any issue 
heh my code its not complete but still its a bit too large for insert here
i send it to you u want the code or the
  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #3 - Nov 3rd, 2012 at 10:37pm
Print Post  
THX_RoG wrote on Nov 3rd, 2012 at 10:26pm:
wow that was quick 
yes im using arduino 1.0.1 and have only one
yes restarting did int help
im using win7x64 VS2010 and win8x64 VS2012 and the same problem appear but not in arduino it take some time but it compile without any issue 
heh my code its not complete but still its a bit too large for insert here
i send it to you u want the code or the

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


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #4 - Nov 3rd, 2012 at 10:57pm
Print Post  
The entire sketch would be good by email. Please also include the .vcproj and other vs files if you can.

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


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #5 - Nov 4th, 2012 at 7:49am
Print Post  
i send it to you yesterday my complete file H-Bridge in rar
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #6 - Nov 4th, 2012 at 3:51pm
Print Post  
Hello, I found the problem. For some reason vm is rejecting the - in the name.

I'll fix that in the next release but for now close vs.

Rename the H-bridge folder to H_bridge

Rename the H-bridge.ino to h_bridge.ino

Delete all the .vcx  files in the folder (which are just vs files)

Then re-open the sketch and it will be fine
  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #7 - Nov 4th, 2012 at 6:37pm
Print Post  
heh your right (but the admin have always Right)
any whey THX for help
  
Back to top
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #8 - Nov 5th, 2012 at 1:16pm
Print Post  
Sup next bug :
if your project have the same name as your Arduino lib/example the VM wont compile
EXAMPLE
Code
Select All
...Arduino\libraries\USBHostShield\examples\PS3USB\PS3USB.ino

your VM project The same name PS3USB.ino
you get:
Compiling 'PS3USB' for 'Arduino Mega 2560 or Mega ADK'
Couldn't determine program size:
 

« Last Edit: Nov 5th, 2012 at 1:16pm by THX_RoG »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #9 - Nov 5th, 2012 at 1:35pm
Print Post  
3 questions

1) Does it compile okay in the arduino ide from exactly the same location?

2) Please switch on Tools>Options>Compiler>Verbose and email the result from output window

Thanks

« Last Edit: Nov 5th, 2012 at 1:37pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #10 - Nov 5th, 2012 at 1:56pm
Print Post  
1) YES
2) have over 4k Ln
and most of it says 
hidusagestr.h : Warning: only initialized variables can be placed into program memory area
But if i change the project name in compile without any problems
« Last Edit: Nov 5th, 2012 at 2:14pm by THX_RoG »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #11 - Nov 5th, 2012 at 2:16pm
Print Post  
Ok thanks. 

Out of interest, what did you change the project name to?

One of the rules of vm is supposed to be that the project name is the same as the main .ino so it shouldn't work with a different name
« Last Edit: Nov 5th, 2012 at 2:17pm by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #12 - Nov 5th, 2012 at 2:43pm
Print Post  
i just change the project name and delete the old file
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #13 - Nov 5th, 2012 at 3:09pm
Print Post  
What is the project name that worked for you?
  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #14 - Nov 5th, 2012 at 4:18pm
Print Post  
in folder where u have your default Arduino libraries
Code
Select All
..\Documents\Arduino\libraries\ 


in each different libraries u have a folder with examples
Code
Select All
..\Documents\Arduino\libraries\...\examples\ 


and there u have a sketch folder.
i chose the same name in VS as my arduino examples folder sketch and i was getting this
Code
Select All
Compiling '...(your example name sketch)...' for 'Arduino Mega 2560 or Mega ADK'
Couldn't determine program size:  


and the short story  VS cant compile a solution with the same name as your example sketch (but dont now why)
i chose to make a project with a different name alls my example sketch folder and it work
(do you understand me now?)
« Last Edit: Nov 5th, 2012 at 4:19pm by THX_RoG »  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #15 - Nov 5th, 2012 at 5:32pm
Print Post  
I think so but I will have to try it because that is how I tested another sketch recently. Thanks for the info. I guess when you changed the project name you also changed the sketch name?
  
Back to top
WWW  
IP Logged
 
THX_RoG
Junior Member
**
Offline


Posts: 27
Location: Germany
Joined: Nov 3rd, 2012
Re: [Visual Studio 2010]Couldn't determine program size
Reply #16 - Nov 5th, 2012 at 5:40pm
Print Post  
only project name in VS and the example sketch from arduino i didn't rename
  
Back to top
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12076
Location: United Kingdom
Joined: Apr 10th, 2010
Re: [Visual Studio 2010]Couldn't determine program size
Reply #17 - Nov 5th, 2012 at 5:44pm
Print Post  
Ok thanks. This will be an interesting one! (for me, boring for you)
  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint