Posts

Showing posts with the label Waveform

SX1278 OOK waveform view with C# chart control - 4

Image
2.2.2020 SX1278 OOK waveform view with C# chart control - 4 Oscilloscope "moving effect" lookalike         private void timer1_Tick(object sender, EventArgs e)         {             if (_run)             {                 for (int i = _index; i < _xValues.Count; i++)                 {                     chart1.Series[0].Points.AddY(_xValues[i]);                     if (chart1.Series[0].Points.Count > 100)           ...

SX1278 OOK waveform view with C# chart control - 3

  19.1.2020 SX1278 OOK waveform view with C# chart control - 3 https://github.com/OH1GIU-P/SxWavePlot Without datasource. Add new received values to chart         private bool _run = false;         private ArrayList _xValues = new ArrayList();         private int _val = 1; // add this:         private int _index = 0; private void buttonStart_Click ...                 _xValues.Clear();                 _index = 0;                 chart2.DataSource = null; ... private void buttonStop_Click ...             _run = false;          ...

SX1278 OOK waveform view with C# chart control - 2

Image
  sunnuntai, 19. tammikuu 2020 SX1278 OOK waveform view with C# chart control - 2 Dragino Lora Shield (Semtech SX1278) Arduino Due Visual Studio, C# Chart cannot be updated in serial port datareceived event (Collection was modified; enumeration operation may not execute). One solution is updating chart data in timer ontick event or in separate thread.   using System; using System.Collections; using System.Threading.Tasks; using System.Threading; using System.Windows.Forms; using System.IO.Ports; using System.Windows.Forms.DataVisualization.Charting; namespace SxWavePlot {     public partial class FormMain : Form     {         private bool _run = false;         private ArrayList _xValues = new ArrayList();         private int _val = 1;         public FormMain()         { ...

SX1278 OOK waveform view with C# chart control

Image
12.1.2020 SX1278 OOK waveform view with C# chart control Dragino Lora Shield (Semtech SX1278) Arduino Due Visual Studio, C#   Arduino code #include <SPI.h> #define SERIAL_SPEED        57600 #define BPS                 1200 #define FREQ                433.9855 #define STATE_SLEEP         0 #define STATE_STANDBY       1 #define STATE_FSRX          4 #define STATE_RX            5 #define S_DELAY             10 #define L_DELAY             100 #define CH_FILTER_BW        B000...