diff --git a/TeddyBench/TeddyMain.cs b/TeddyBench/TeddyMain.cs index 30cadfb..7b594e4 100644 --- a/TeddyBench/TeddyMain.cs +++ b/TeddyBench/TeddyMain.cs @@ -2240,19 +2240,25 @@ private void measureAnteannaToolStripMenuItem_Click(object sender, EventArgs e) TagOperationDialog opDlg = new TagOperationDialog(); opDlg.Show(); - Proxmark3.MeasurementResult result = RfidReader.MeasureAntenna(); + try + { + Proxmark3.MeasurementResult result = RfidReader.MeasureAntenna(); - opDlg.Close(); + opDlg.Close(); - if (result == null) - { - MessageBox.Show("Measurement failed.", "Failed"); - return; - } + if (result == null) + { + MessageBox.Show("Measurement failed.", "Failed"); + return; + } - PlotAntennaForm form = new PlotAntennaForm(result); + PlotAntennaForm form = new PlotAntennaForm(result); - form.ShowDialog(); + form.ShowDialog(); + } + catch (Exception ex) + { + } } private void flashFirmwareToolStripMenuItem_Click(object sender, EventArgs e) @@ -2263,7 +2269,13 @@ private void flashFirmwareToolStripMenuItem_Click(object sender, EventArgs e) dlg.Filter = "Firmware ELF files (*.elf)|*.elf|All files (*.*)|*.*"; if (dlg.ShowDialog() == DialogResult.OK) { - RfidReader.EnterBootloader(dlg.FileName); + try + { + RfidReader.EnterBootloader(dlg.FileName); + } + catch (Exception ex) + { + } } } @@ -2275,7 +2287,13 @@ private void flashBootloaderToolStripMenuItem_Click(object sender, EventArgs e) dlg.Filter = "Bootloader ELF files (*.elf)|*.elf|All files (*.*)|*.*"; if (dlg.ShowDialog() == DialogResult.OK) { - RfidReader.EnterBootloader(dlg.FileName); + try + { + RfidReader.EnterBootloader(dlg.FileName); + } + catch (Exception ex) + { + } } }