This is a problem thats been bugging me for a while, but now its flat out screwing me up
on the reference page for readBytes() it clearly states
buffer: the buffer to store the bytes in (char[] or byte[])
and if you do this
byte buffer[512];
void setup()
{
Serial.begin(9600);
Serial.readBytes(buffer, 512);
}
void loop(){}
the compile pukes out
sketch_dec09a.cpp: In function 'void setup()':
sketch_dec09a:5: error: invalid conversion from 'byte*' to 'char*'
sketch_dec09a:5: error: initializing argument 1 of 'size_t Stream::readBytes(char*, size_t)')
whats up with that? how would I get it to work with an array of bytes instead of chars?
thanks