VS Arduino
Visual Micro >> Visual Studio 2017, 2019, 2022 >> Impossible to compile grbl 1.1f with VisualMicro
https://www.visualmicro.com/forums/YaBB.pl?num=1492677326

Message started by mdps on Apr 20th, 2017 at 8:35am

Title: Impossible to compile grbl 1.1f with VisualMicro
Post by mdps on Apr 20th, 2017 at 8:35am
Hello,

I'm, trying to compile grbl 1.1f with VisualMicro and VS2015 (https://github.com/gnea/grbl/wiki) but it is not possible, i can do it with Arduino 1.8.1 IDE with no problems.

I'm using the example grblUpload and the error i'm getting is:

[code]
Error compiling for board Arduino/Genuino Uno
Debug build failed for project 'grbl_1_1f_vs'

wiring.c.o (symbol from plugin)*: In function __vector_16
(.text+0x0)*: multiple definition of __vector_16
stepper.c.o (symbol from plugin)*: (.text+0x0): first defined here

collect2.exe*: error: ld returned 1 exit status
[/code]

Thanks for your help!

Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by Visual Micro on Apr 20th, 2017 at 8:46am
Hi,,

If you switch the tool bar from Debug to Release does it compile okay?

Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by romycp on May 8th, 2017 at 7:27pm
Hello!
I have the same problem.
Yes, in Release Version verything works fine, but I want to debugg the Code.
I found, that there is a Problem with Timer0 that is used in my Code und in the wiring.h file.

Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by Visual Micro on May 8th, 2017 at 7:30pm
Great thanks.

Does the board support any type of standard Arduino Serial.print()

For example:-

Serial.println()
Serial1.println()
SerialUSB.print()


Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by Visual Micro on May 8th, 2017 at 7:51pm
I've looked at this and based on your report I think it is safe to assume that the normal arduino serial commands can not be used.

However, you should be able to use the SoftwareSerial option for Visual Micro debug. SoftwareSerial uses PinChange interrupts so should not be affected by timer1. This assumes you have one or two spare digital pins and some memory.

1) Make sure you switch on "vMicro>Debugger>Full Speed Debugging". GRBL seems to be very time critical so you want the debugger causing as little interruption as possible. Which projects that are time critical you will have to be careful about what debug features you use. For example the digital and analog pin viewers read the pins which can take some millis

2) Use the visual micro debugging with other ports and pins document that explains how to configure software serial.

In essence you tell visual micro to use SoftwareSerial and the Tx and Rx pins. If you only have debug trace messages and watch expressions then you only need the rx pin, if you want break and variables update during debug you also need to set the tx pin.


Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by Visual Micro on May 8th, 2017 at 8:14pm
Ignore previous post. I just tried using SoftwareSerial with GRBL and it doesn't like that either.

If you can find a way to write different types of data to the serial port that might be a good start.

We need to be able to print variables to the port.

Serial.print("hello world")
Serial.print(string)
Serial.print(float)
Serial.print(int)

Alternatively if you have a board that supports hardware debugging we can use that instead. Which board are you using?

Title: Re: Impossible to compile grbl 1.1f with VisualMicro
Post by mdps on May 11th, 2017 at 4:00pm
Hi, sorry for the delay i've been out for a while :) 

I tried in release mode a it compile well, thanks very much is all i need!

VS Arduino » Powered by YaBB 2.6.12!
YaBB Forum Software © 2000-2024. All Rights Reserved.