private void updateStatusInBox(TrionicCANLib.TrionicCan.CanInfoEventArgs e) { AddLogItem(e.Info); if (e.Type == ActivityType.FinishedFlashing || e.Type == ActivityType.FinishedDownloadingFlash) { TimeSpan ts = DateTime.Now - dtstart; AddLogItem("Total duration: " + ts.Minutes + " minutes " + ts.Seconds + " seconds"); trionicCan.Cleanup(); EnableUserInput(true); } }
private void UpdateFlashStatus(TrionicCANLib.TrionicCan.CanInfoEventArgs e) { try { Invoke(m_DelegateUpdateStatus, e); } catch (Exception E) { Console.WriteLine(E.Message); } }
void trionicCan_onCanInfo(object sender, TrionicCANLib.TrionicCan.CanInfoEventArgs e) { UpdateFlashStatus(e); }