i'm trying to use the vscode arduino extension. its running fine when i'm not using any library, but when i including the wire.h library, my board is keep reseting. here is my stuff
i2c_scanner:
#include <Wire.h>
void setup() {
Wire.begin();
Serial.begin(115200);
while (!Serial); // Leonardo: wait for serial monitor
Serial.println("\nI2C Scanner");
}
output done uploading
output serial monitor
my c_cpp_properties.json
{
"version": 4,
"configurations": [
{
"name": "Arduino",
"compilerPath": "C:\\Users\\SAGITA\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7\\bin\\avr-g++",
"compilerArgs": [
"-w",
"-std=gnu++11",
"-fpermissive",
"-fno-exceptions",
"-ffunction-sections",
"-fdata-sections",
"-fno-threadsafe-statics",
"-Wno-error=narrowing"
],
"intelliSenseMode": "gcc-x64",
"includePath": [
"C:\\Users\\SAGITA\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\cores\\arduino",
"C:\\Users\\SAGITA\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\variants\\eightanaloginputs",
"C:\\Users\\SAGITA\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\libraries\\Wire\\src",
"c:\\users\\sagita\\appdata\\local\\arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7\\lib\\gcc\\avr\\7.3.0\\include",
"c:\\users\\sagita\\appdata\\local\\arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7\\lib\\gcc\\avr\\7.3.0\\include-fixed",
"c:\\users\\sagita\\appdata\\local\\arduino15\\packages\\arduino\\tools\\avr-gcc\\7.3.0-atmel3.6.1-arduino7\\avr\\include"
],
"forcedInclude": [
"C:\\Users\\SAGITA\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\avr\\1.8.6\\cores\\arduino\\Arduino.h"
],
"cStandard": "c11",
"cppStandard": "c++11",
"defines": [
im using:
vscode extension for Arduino v 0.4.11
vscode extension C/C++ latest version
Arduino IDE 1.8.5
anyone know whats going on here?