Visual Studio Ide for Arduino
https://www.visualmicro.com/forums/YaBB.pl
Other >> Other Hardware >> ESP8266/Visual Studio 2012: Problem with _EXFUN/Function Prototypes
https://www.visualmicro.com/forums/YaBB.pl?num=1453145481

Message started by Red Baron on Jan 18th, 2016 at 7:31pm

Title: ESP8266/Visual Studio 2012: Problem with _EXFUN/Function Prototypes
Post by Red Baron on Jan 18th, 2016 at 7:31pm
Hello,

VM seems to import wrong prototypes. Many prototypes of standard functions (e.g. sprintf(...)) are surrounded by a macro named _EXFUN. There is something going wrong with this macro: it expends to sprintf() with no paramters. Now Visual Studio (Intellisence?) grumbles "too many parameters".

There are a lot of defines to configure _EXFUN. I do not know how to fix it. :-X Can anybody help?

Kind rergards
Red Baron


Edit: My actual configuration is:
- Windows 10
- Visual Studio 2012, Update 5
- Arduino IDE 1.6.7
- ESP8266 Build-In 2.0.0
- Visual Micro 1.1601.11

Title: Re: ESP8266/Visual Studio 2012: Problem with _EXFUN/Function Prototypes
Post by Visual Micro on Jan 18th, 2016 at 7:41pm
Not sure. If possible please email your esp program to info[at]visualmicro.com so I can see the problem

Thanks

Title: Re: ESP8266/Visual Studio 2012: Problem with _EXFUN/Function Prototypes
Post by Visual Micro on Jan 18th, 2016 at 10:27pm
Thanks for the example.

I think I have found the solution. I have added #define __STDC__ to the esp8266 intellisense list.

You can edit the vm config to test. To find the vm install folder look in "tools>options>visual micro>version>assembly"

Then edit the text file called "[visual micro program folder]\Micro Platforms\arduino16x\hardware\esp8266\intellisense code.h"

Add this line to the top of the file and save it.

[code]#define __STDC__[/code]

In visual micro, clicking save on the project or building should refresh the intellisense, otherwise toggle the board selection with another board.

The code from the "intellisense code.h" is inserted into the "__vm\[project_name].vsarduino.h" file of each esp8266 project.

Does this make sense?

Title: Re: ESP8266/Visual Studio 2012: Problem with _EXFUN/Function Prototypes
Post by Red Baron on Jan 20th, 2016 at 3:25am
Works fine for me!

Thank you!

Visual Studio Ide for Arduino » Powered by YaBB 2.5.2!
YaBB Forum Software © 2000-2020. All Rights Reserved.