arduino serial communication hex code parsing


I hacked this one.


According to this picture.


I did this.

and

this


this

this

this

ultimately

succeeded
but my arduino IDE serial monitor doing


like this

My question is this.

I want to see that hex code at arduino monitor.

And parse it to dicimal type or ascii and so on.

What do I have to do?
Please help me.

What do I have to do?

Post your code.

if(yourbyte<0x10)
{
  Serial.print("0");
}
Serial.print(yourbyte, HEX);

Will print the two nibbles of a byte.

sterretje:

if(yourbyte<0x10)

{
  Serial.print("0");
}
Serial.print(yourbyte, HEX);



Will print the two nibbles of a byte.

Thank you so much.
I'll try your code.