Hi all
I am trying to run a sketch using the c++ lib vector (#include ) but there seems to be a conflict with CurieBLE. The sketch works fine without the include . Any suggestions would be appreciated.
Here is a list of the error messages:
Arduino: 1.6.7 (Windows 10), TD: 1.27, Board: "Arduino/Genuino 101"
C:\Users\CyberPalin\Documents\Arduino\Arduino101\Arduino101_CRP_v2\Arduino101_CRP_v2\Arduino101_CRP_v2.ino: In function 'void setup()':
Arduino101_CRP_v2:71: error: 'blePeripheralConnectHandler' was not declared in this scope
blePeripheral.setEventHandler(BLEConnected, blePeripheralConnectHandler);
^
Arduino101_CRP_v2:72: error: 'blePeripheralDisconnectHandler' was not declared in this scope
blePeripheral.setEventHandler(BLEDisconnected, blePeripheralDisconnectHandler);
^
Arduino101_CRP_v2:75: error: 'rxCharacteristicWritten' was not declared in this scope
rxCharacteristic.setEventHandler(BLEWritten, rxCharacteristicWritten);
^
C:\Users\CyberPalin\Documents\Arduino\Arduino101\Arduino101_CRP_v2\Arduino101_CRP_v2\Arduino101_CRP_v2.ino: In function 'void loop()':
Arduino101_CRP_v2:148: error: 'closeConnection' was not declared in this scope
closeConnection(parser.getPfodAppStream());
^
exit status 1
'blePeripheralConnectHandler' was not declared in this scope
This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.
I am attaching the sketch.
Thanks
Mike
Arduino101_CRP_v2.zip (4.95 KB)
Hi Mike, the issue was due to ctags and should be solved with IDE 1.6.8 (and obviously in nightly) 
Thank facchinm. Just downloaded the nightly build as well as 1.6.8. Both still gave me the same error message.
Mike
Hi Merlin,
I found the bug, very nasty indeed. A PR for arduino-builder is on it way (ArduinoBot should post the binaries here Avoid using whole ctags_target_for_gcc_minus_e for prototype generation by facchinm · Pull Request #131 · arduino/arduino-builder · GitHub)
Thanks a lot for reporting!
Hi facchinm
Glad you found out the issue and glad I just tested it on something simple. I have the Eigen lib that I have running on the mega that I want to give a shot at for a Kalman filtering project that had issues and maybe this is the problem.
Hopefully they get it closed soon.
Thanks for your help.
Mike
Hi facchinm
I downloaded the zip file for the new Arduino-builder and replaced it with the windows version from the zip file. Unfortunately the minute I do an include into the sketch it still blows up with the same error message. Something else must be going on besides the issue you identified or they did not implement the changes correctly.
Mike
Update: I used the new builder with an old sketch that worked fine (no vector or strange calls) and it balked at the following:
In main sketch I do a call like so:
uint8_t count = serial_busy_wait();
It states that serial_busy_wait() is not defined in this context or something like that. Here is the function itself:
char serial_busy_wait() {
while(!Serial.available()) {
; // do nothing until ready
}
return Serial.read();
}
Merlin513, can you attach the full "old sketch"?
The old sketch is the one that had an issue with serial_busy_wait undefined but seems to be cleared up now and does not use the vector and ble at all.
Looking at the 131 pull request seems like it was replaced with this: Only pass sketch sources to ctags by matthijskooijman · Pull Request #156 · arduino/arduino-builder · GitHub. Says it was merged but don't know if incorporated into 1.6.9.
Right, there's not really any way to tell that by looking at github. So, let's wait and see what facchinm says.
Hi Erik, it didn't make into 1.6.9 but will be in upcoming 1.6.10 
Is it available in the nightly builds yet? Thanks Mike
The fix for the issue is now in nightly via this commit , simply download the package for your architecture from https://www.arduino.cc/en/Main/Software#hourly
Hi facchinm .
You're the man. Just downloaded and gave it a quick compile check and no errors 
Thanks for getting this working.
Mike