Hex to ASCII conversion

I guessed that in post #11, even if the OP has answered but half my questions.

i used his solution and initialized string s with all the character i need and later before printing i am reading from string and it printed the result i wanted.

not sure what a "Telegram" is. i assume the data is read into a byte array.

while Serial.print() doesn't know how to display "byte", it certainly knows how to display chars. so if if a value c-string is within the received buffer, it can be displayed by locating the beginning of the string and casting it as a char* (i.e. "(char*)"). make sure the c-string is terminated with a NULL, 0.

    byte s [] = "how now brown cow";
    Serial.println ((char*) &s [5]);

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.