Pergunta

I am trying to send the following hex to NSOutputstream 0x0000000e000000010000001000003014

I'm able to send hex that is 8 bit with the following code:

long myhex = 0x0000000e00000001;    

NSData *data = [[NSData alloc] initWithBytes:&myhex length: sizeof(myhex)];
[outputStream write:[data bytes] maxLength:[data length]];

The problem is when I try this:

long myhex = 0x0000000e000000010000001000003014;

it says "integer constant is too long for its type"

I cant seem to figure out what type of integer will except this hex value.

Nenhuma solução correta

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top