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 [2] 3  Send TopicPrint
Very Hot Topic (More than 25 Replies) Multiple Definition of Vectors.... (Read 54440 times)
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #20 - Nov 26th, 2012 at 12:54am
Print Post  
Tim,

Is the debugger using Serial?  It appears to me Serial grabs all available ports, even if you're using only one.  If so, could I just cobble HardwareSerial.cpp to only use a single port when using the debugger?

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #21 - Nov 26th, 2012 at 1:17am
Print Post  
The debugger uses Serial. It uses HardwareSerial unless you specify otherwise in the RemoteTransport project property.

So you can use SoftwareSerial, a custom SerialObject or cobble your own HardwareSerial
« Last Edit: Nov 26th, 2012 at 1:18am by Tim@Visual Micro »  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #22 - Nov 26th, 2012 at 1:25am
Print Post  
Tim,

Ah, ok!  I set Transport to Software Serial, and it's now compiling and loading, so I think I should be OK - just have to get my code off that serial port.

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #23 - Nov 26th, 2012 at 1:32am
Print Post  
SoftwareSerial will work on any digital pins that support interrupts. I don't know if it can be used on the hardware serial ports. Arduino.cc/forums should be able to help with that.

To use SoftwareSerial you need to provide the Remote TXPin and Remote RXPin numbers in the project properties
  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #24 - Nov 26th, 2012 at 2:59am
Print Post  
Tim,

I'm trying to get Software Serial working, and I think I'm close, but having different compile problems.  I've set:

Local Port: COM7
Local Speed: 115200

Remote Rx Pin: 10
Remote Tx Pin: 11
Remote Port: Serial
Remote Speed: 115200
Remote Transport: Software Serial

I have Pins 10 & 11 connected to the RS232 level converter, which is plugged into the USB Serial cable, which Windows sees as COM7.

The compile errors I get are:

Compiling 'SkyNet' for 'Arduino Mega 2560 or Mega ADK'
Binary sketch size: 13146 bytes (of a 258048 byte maximum) (1.234375 secs)
Compiling debug version of 'SkyNet' for 'Arduino Mega 2560 or Mega ADK'
SkyNet.ino : : In function 'void setup()':
SkyNet.ino : begin(HardwareSerial*, long int)'
VM_DBG.h : begin(SoftwareSerial*)
VM_DBG.h : begin(SoftwareSerial*, long int)
Error compiling

Regards,
Ray L
« Last Edit: Nov 26th, 2012 at 4:27am by RayLivingston »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #25 - Nov 26th, 2012 at 1:22pm
Print Post  
Hi,

One small point is to clear out the "Remote Port" property. If using the rx/tx then remote port is not required

If that doesn't fix it then please email your sketch

Thanks
  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #26 - Nov 26th, 2012 at 4:31pm
Print Post  
Tim,

Clearing the Remote Port property now has it compiling and loading, but when I set a breakpoint, the second monitor window just shows: "Waiting for debug breakpoint data".  If I don't set a breakpoint, the application does run.  If I do set a breakpoint, it appears to stop at the breakpoint, but the debugger never shows anything, and the "Waiting" message never goes away.   Even odder, the Monitor window now refuses to display the output from my program, though my custom terminal program, displays everything just fine.  That makes no sense at all to me, since they are simply monitoring a COM port on the PC!

I will e-mail my sketch shortly.

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #27 - Nov 26th, 2012 at 4:56pm
Print Post  
Thanks. 

Sounds like the RX on the arduino is not connected. 

I also forgot to say that SoftwareSerial doesn't like 115200. It does work okay at 115k without break/pause but slower speeds are better when the arduino receieves, please try at 19200. It has worked well for me at 57600 but not for some people.

Remember that Tx on the arduino goes to Rx on the ftdi, and Rx on the arduino goes to tx on the ftdi

I suggest you have break/pause = false so that you only have to worry about the Tx from the arduino to start with.

When you see debug trace messages then you will know the arduino tx is working. The debugger only uses the tx pin when break/pause = false.
« Last Edit: Nov 26th, 2012 at 5:12pm by Tim@Visual Micro »  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #28 - Nov 26th, 2012 at 8:56pm
Print Post  
Tim,

Some progress - I've gotten SoftwareSerial to work, using a simple test program.  I was confused about pin numbers....  Now trying to get the debugger to work with the LED blinking program.  If I set a breakpoint in loop(), and specify "print a message and continue execution", the printouts do come out in the Output window.  So, obviously the board and PC are talking.  At one point, it was also displaying something each pass of loop(), but that stopped - no idea why.  But it I set a regular breakpoint, nothing happens, other than periodically printing "12:53:59.968 BlivetSketch.ino, line 14" in the output window.  The "expressions on COM7" window never shows anything other than "Waiting for debug breakpoint data" in blue.

I also noticed some things in VS seem to have gotten whacked in installing the debugger, which may be the whole problem here.  The Project menu now has two new items "Upload last Arduino build" and "Show all Arduino file", but there are DOZENS of each in there.  I have NO Watch window, and it doesn't shows up anywhere in the View menu.

Regards,
Ray L.
« Last Edit: Nov 26th, 2012 at 9:18pm by RayLivingston »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #29 - Nov 27th, 2012 at 12:11pm
Print Post  
Hi, 

1)
You need to run the resetaddin which is documented on the main site. Search for resetaddin. That will remove the multiple menu items.

2)
All breakpoints are tracepoints unless you switch on the project property called "Enable Break/Pause". This is to prevent new users from causing an rc plane to stop in flight Smiley

3)
What "When Hit" message did you add to your breakpoint? Did it contain some variables/expressions to be watched??? Here are 3 different examples, you can add as many {expression} as you like, with or without static text:-

Quote:
Hello World {millis()}

Quote:
{millis()}

Quote:
Hello World


The first two examples should cause millis() to be displayed in the expression window. 

The expression window opens automatically when the debug starts, there is no menu item to open it.

Now that you have the vectors sorted I suggest a new thread for any other issues. Thanks
« Last Edit: Nov 27th, 2012 at 12:12pm by Tim@Visual Micro »  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #30 - Nov 27th, 2012 at 2:13pm
Print Post  
Tim,

resetaddin does get rid of the extra menu items, leaving only one set.  But, if I close then re-open VS, then I have two copies.  Close and re-open again, and I now have three copies.  And so on...

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #31 - Nov 27th, 2012 at 2:16pm
Print Post  
Very so often we find a version of vs that has another addin or extension installed that causes this problem.

Vs is unhappy so tells vm that it needs to re-add these controls. When vm asks vs if a control exists on a bar or menu it says it doesn't when it does!!

I expect you are on the latest vs service pack? What other addins have you got installed "Tools>Addin Manager"?

Thanks
  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #32 - Nov 27th, 2012 at 2:39pm
Print Post  
Tim,

Actually, VisualMicro is the ONLY add-on I have installed:

Microsoft Visual Studio 2008
Version 9.0.30729.1 SP
Microsoft .NET Framework
Version 3.5 SP1

Installed Edition: Standard

Microsoft Visual Basic 2008   91851-136-1197172-60481
Microsoft Visual Basic 2008

Microsoft Visual C# 2008   91851-136-1197172-60481
Microsoft Visual C# 2008

Microsoft Visual C++ 2008   91851-136-1197172-60481
Microsoft Visual C++ 2008

Microsoft Visual Web Developer 2008   91851-136-1197172-60481
Microsoft Visual Web Developer 2008

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB2538241)   KB2538241

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB944899)   KB944899

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB945282)   KB945282

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB946040)   KB946040

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB946308)   KB946308

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB946344)   KB946344

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB946581)   KB946581

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB947173)   KB947173

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB947540)   KB947540

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB947789)   KB947789

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB948127)   KB948127

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB953256)   KB953256

Hotfix for Microsoft Visual Studio 2008 Standard Edition - ENU (KB971091)   KB971091

Microsoft Visual Studio 2008 Standard Edition - ENU Service Pack 1 (KB945140)   KB945140

Microsoft Visual Studio 2008 Standard Edition - ENU Service Pack 1 (KB947888)   KB947888

Microsoft Visual Studio 2008 Standard Edition - ENU Service Pack 1 (KB948484)   KB948484

Security Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB2251487)   KB2251487

Security Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB2669970)   KB2669970

Security Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB972222)   KB972222

Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB956453)   KB956453

Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB967143)   KB967143

Update for Microsoft Visual Studio 2008 Standard Edition - ENU (KB972221)   KB972221

Visual Micro Arduino
Copyright Visual Micro 2009

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #33 - Nov 27th, 2012 at 2:58pm
Print Post  
What about extensions Tools>Options>Extension Manager?

Your system looks okay. If you look at Tools>Options do you only see one set of "Visual Micro" options?
  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #34 - Nov 27th, 2012 at 3:16pm
Print Post  
Tim,

There is no Tools->Options->Extension Manager in my VS.  I can't find Extension Manager anywhere....

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #35 - Nov 27th, 2012 at 4:51pm
Print Post  
Oh yes I forgot that 2008 doesn't have extensions. 

I'm running out of suggestions. This is VS2008 playing up and I have little control over this part of the process.

All I can suggest is running a repair on vs2008 or downloading VS2012 on the 3 year ms promo. 

Sorry, it might also help to keep in mind that vs uses the office tool bar system and OLE so windows/office updated might help.
  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #36 - Nov 27th, 2012 at 7:07pm
Print Post  
Tim,

I guess I can live with the menu issues, for now.  But, back to the original problem, still no go.  I Enabled Break/Pause, but when it hits the breakpoiint, a message is printed indicating execution is paused, but the message specified in "When hit" does not display, nor does the Expression window ever appear.  The "Waiting for debug breakpoint data" also never goes away, and nothing is ever displayed in that window.  There appears to be no way to continue execution from that point.  The breakpoint source line does highlight when the breakpoint is hit.  This is all running a simple blink application, using hardware serial.

Would it be worthwhile to un-install the plug-in and debugger, and try again?

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Multiple Definition of Vectors....
Reply #37 - Nov 27th, 2012 at 8:53pm
Print Post  
So you are seeing a "Micro Trace" output window message to confirm the breakpoint has been hit or a status bar message?

What is the "When Hit" message that you have set against the breakpoint? 

Please switch off break/pause until you have the trace system working and showing both messages and expressions.

Can you see the "Micro Trace" output window when the debugger starts?

Thanks
« Last Edit: Nov 27th, 2012 at 8:54pm by Tim@Visual Micro »  
Back to top
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #38 - Nov 28th, 2012 at 3:55am
Print Post  
Tim,

What messages I get, come out in the VS Output window.  There are two additional windows, both apparently tied to COM7 (the serial port connected to the Arduino serial port), one of which says only "Port Open", and the other, which I just (stupidly) realized *is* the expression window, which has never shown anything but "Waiting for debug breakpoint data".

When I turn off Break/Trace, I get nothing at all in the output window after the program finishes loading.  The two COM7 windows show the same thing as always - basically nothing.

VS is also now throwing an error when I exit - I get the error dialog asking if I want to send an error report to Microsoft.

Regards,
Ray L.
  
Back to top
 
IP Logged
 
RayLivingston
Full Member
***
Offline


Posts: 158
Location: California
Joined: Nov 24th, 2012
Re: Multiple Definition of Vectors....
Reply #39 - Nov 28th, 2012 at 4:19am
Print Post  
Well, this is odd....  After the last crash on exiting VS, I re-started, and ran the same program - didn't change anything.  It hit the breakpoint, stopped, printed the variables to the expression window, and opened a couple of other windows (performance monitor and digital pins), then stopped working.  Exited VS, it crashed, re-started, and it again worked.  After it hits the breakpoint, I can click the Run button, and it continues, hits the breakpoint again.  After doing this 3 or 4 times, rather than continuing, it re-compiles and re-loads the program.

Are the Run/Stop/Pause/Step buttons supposed to work?  Only the Run button ever enables.

Regards,
Ray L.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1 [2] 3 
Send TopicPrint