una preguntita,yo tambien quiero mandar comandos en hexa, y pongo asi:
#int_rda
secuencia(){
dato=0x00;
if(kbhit()){
dato=getc();
}
}
void main()
{
setup_adc_ports(NO_ANALOGS);
setup_adc(ADC_OFF);
setup_psp(PSP_DISABLED);
setup_spi(FALSE);
setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1);
setup_timer_1(T1_DISABLED);
setup_timer_2(T2_DISABLED,0,1);
setup_comparator(NC_NC_NC_NC);
setup_vref(FALSE);
enable_interrupts(global);
enable_interrupts(int_rda);
// TODO: USER CODE!!
while(1){
if(dato!=0x00){
printf("%X%X%X%X%X",0x1E,0x00,0x1C,0xD1,0x00);
dato =0x00;
}
}
}
mi pregunta es la siguiente,lo detecta realmente como datos hexadecimales o como valores ascci que luego interpreta como valores hexa,por decir asi,el valor 1 lo interpreta como 0x31?pregunto esto por que lo he leido en otro post aqui abierto y tengo la duda,gracias por su atencion