I am working with doing some serial communications in C in Linux. I am doing this using file descriptors. For some reason after char* s = "Hello world"
, I can write s
to the serial port using the write method, no problem. I am using a serial monitor program to check the other end. However, I cannot send any other sort of data. I get a "Bad Address" error from the write function.
However, I noticed that if I did something very strange: int* x = "5";
That I could then send this x
. My question is, what in the world does int* x = "5"
mean?