It's pretty well spelled out in the pack documentation. C for unsigned char (byte), n for unsigned 16-bit short in network order, N for 32-bit long in network order, a for "arbitrary binary data".
Don't be confused by the 32-bit CCCC's, since an IP address is 4 8-bit numbers, not a 32-bit number.
In reply to Re^5: Need help with (un)pack templates
by gmargo
in thread Need help with (un)pack templates
by Subop
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |