UDP string

byte packetBuffer[]={0x02,0xff,0x26,0x8f,0x26,0x8f,0x00,0x45,0x86,0xd9,0x53,0x54,0x41,0x54,0x55,0x53,0x3a,0x20,0x22,0x6e,0x65,0x74,0x77,0x65,0x72,0x6b,0x2d,0x69,0x64,0x22,0x20,0x22};

its pre defined (?) and the code looks if this ID is in the string

Peter

It's defined right there in that code. Those hexadecimal digits (base 16 digits begin with 0x) are the text.

Arduino uses text codes from the ASCII (American Standard Code for Information Interchange) table.

ASCII codes

Letter S is character 0x53 (== decimal 83) for instance.

Letters A to Z are 0x41 to 0x5A and letters a to z are 0x61 to 0x7A. The difference between upper and lower case is 0x20 (32 decimal).

But for printable characters you don't have to spell with ASCII values, just put the char in single quotes, easier to read!

byte packetBuffer[]={0x02,0xff,0x26,0x8f,0x26,0x8f,0x00,0x45,0x86,0xd9,'S','T','A','T','U','S',':',' ',0x22,'c','e','t','w','e','r','k','.','i','d',0x22,0x20,0x22};