public void changestate(e_NMTState newstate)
        {
            laststate = state;
            state     = newstate;
            lastping  = DateTime.Now;

            if (newstate == e_NMTState.BOOT)
            {
                if (state != laststate && NMT_boot != null)
                {
                    NMT_boot(state);
                }
            }
        }
 public NMTState()
 {
     state     = e_NMTState.INVALID;
     laststate = e_NMTState.INVALID;
 }