I am trying to upload a LED bar library from Grove, to the spark apps, but it seem to have some problems include the arduino.h files.
I have used this library GitHub - Seeed-Studio/Grove_LED_Bar: A powerful MY9221 LED driver.
But gets a error about the arduino.h file when compiling.
I try to work around the problem by deleting the arduino.h line in the .cpp file(line:25).
I also seach the community to figure out the problem and found this topic
that I understand from this is that I can replace:
# include arduino.h
with
define ARDUINO_H
include "stdint.h"
include "stddef.h"
include "stdlib.h"
and this should works in most cases. But that it not fixing the problem. Do some of you have other ways the work around this issue.
I think your easiest solution is to remove the line #include "arduino.h" completely or if you want to keep it wrap it up in conditional compiler block like this
#if !defined(SPARK)
#include "arduino.h"
#endif
Normally you don't need to replace the above include with anything - most common headers get included via application.h directly or indirectly.
BTW: Commenting out is not done with # but either with // or /* .... */.