Thanks for the answers.
When I think in bites I see this:
myByte =: 128
myByte binair =: 10000000
bitwise not myByte is: 127
bitwise not myByte binair =: 1111111
Case 1 myChar = (char)temp; 1111111 decimal: 127
myByte =: 127
myByte binair =: 1111111
bitwise not myByte is: 128
bitwise not myByte binair =: 10000000
Case 2myChar = (char)temp; 11111111111111111111111110000000 decimal: -128
myChar seems to be a 32-bits long .