In your command
fwrite(s,10101010,'int8')
you are asking to have decimal 10101010 converted to int8, and transit that. The effect would be as if you had used
fwrite(s, int8(10101010), 'int8')
which, due to the saturation properties of int8, would be equivalent to
fwrite(s, int8(127), 'int8')
High bit is 0, but low bit is transmitted first in serial, so the bit order across the wire would be 11111110 .
Remember, 10101010 is a decimal number, ten million, one hundred and one thousand, and ten.