RodolfoRG - 2009-04-12

I think this issue is related to operator precedence. Typecast is evaluated before logical shift[1]. So, you must use some parenthesis, like this:
AskFrame[ FrameSize++ ] = (unsigned char) (BitValue>>8);

[1]http://www.cppreference.com/wiki/operator_precedence