I'm using a pointer to type int inside a function and trying to shift the contents right 8 and cast to a char, to extract a byte for the upper address.
I get a run-time error.
This seem logical to me, can I not cast a dereferenced pointer?
funct1(unsigned int *address)
funct2( (unsigned char) ((*address)>>8) ) )//upper address
//funct2 expects byte
func2( (unsigned char) *address )//lower byte