/* get a big endian short (16bits) from a pointer 
Caller should ensure parameters are valid. */
uint16_t BytesGetBe16(const void *ptr)
/* get a big endian short (16bits) from a pointer 
Caller should ensure parameters are valid. */
uint16_t BytesGetBe16(const void *ptr)
{
    const uint8_t *p = (const uint8_t *)ptr;
    return (p[0] << 8) | p[1];
}