/*
         * protected virtual void OnRawMessage(RawMessageEventArgs e)
         * {
         *  EventHandler<RawMessageEventArgs> handler = RawMessageReceived;
         *
         *  if (handler != null)
         *  {
         *      context.Post(delegate(object dummy)
         *      {
         *          handler(this, e);
         *      }, null);
         *  }
         * }
         */

        protected virtual void OnShortMessage(ShortMessageEventArgs e)
        {
            EventHandler <ShortMessageEventArgs> handler = ShortMessageReceived;

            if (handler != null)
            {
                context.Post(delegate(object dummy)
                {
                    handler(this, e);
                }, null);
            }
        }
 private void EventSource_RawMessageReceived(object sender, ShortMessageEventArgs e)
 {
     FOutDevice.SendShort(e.Message.Message);
 }