I want to use multi-file structure, like one xxx.pde file, and many xxx.h xxx.c, but when I write SerialUSB.print() Serial1.print() or digitalWrite() function in xxx.c file, the maple IDE can't complie success.
file aa.pde
////////////////
extern "C"
{
void test();
}
void setup()
{
}
void loop()
{
test();
delay(3000);
}
////////////////
file fun.c
////////////////
void test()
{
Serial1.println("Hello world!");//digitalWrite(17, HIGH)
}
////////////////
maple IDE give: error:'Serial1' undeclared (first use in this function)//error: 'HIGH' undeclared (first use in this function)
Which .h file should I must include?