I’m working on a ofxSimpleSerial-addon and because people like to work with strings I would like to add a writeString() method.
But… I don’t understand how I should convert strings into unsigned char’s, and that is what the original writeBytes needs.
string a = "the book is on the table"; // string a
unsigned char* b = (unsigned char*) a.c_str(); // cast from string to unsigned char*
ofDrawBitmapString(a, 30, 100); // draws a
ofDrawBitmapString(string((char *)b), 30, 130); // draws b
}