added encode/decode of MsgInfo. Added message type/command constants. tweaks