Message Counters Coded

Message counters are implemented and message structures are corrected