mirror of
https://github.com/dj0abr/SSB_HighSpeed_Modem.git
synced 2026-06-08 08:54:39 -04:00
update
This commit is contained in:
Generated
+73
-36
@@ -104,7 +104,6 @@
|
||||
this.tb_callsign = new System.Windows.Forms.TextBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.cb_stampcall = new System.Windows.Forms.CheckBox();
|
||||
this.cb_savegoodfiles = new System.Windows.Forms.CheckBox();
|
||||
this.tabPage4 = new System.Windows.Forms.TabPage();
|
||||
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
|
||||
this.cb_speed = new System.Windows.Forms.ComboBox();
|
||||
@@ -113,6 +112,12 @@
|
||||
this.progressBar_fifo = new System.Windows.Forms.ProgressBar();
|
||||
this.label_fifo = new System.Windows.Forms.Label();
|
||||
this.bt_blockinfo = new System.Windows.Forms.Button();
|
||||
this.progressBar_capfifo = new System.Windows.Forms.ProgressBar();
|
||||
this.label_capfifo = new System.Windows.Forms.Label();
|
||||
this.lb_rxsignal = new System.Windows.Forms.Label();
|
||||
this.lb_rxsync = new System.Windows.Forms.Label();
|
||||
this.pb_rxsync = new System.Windows.Forms.PictureBox();
|
||||
this.pb_rxsignal = new System.Windows.Forms.PictureBox();
|
||||
this.bt_rximages = new System.Windows.Forms.Button();
|
||||
this.button_loadimage = new System.Windows.Forms.Button();
|
||||
this.button_cancelimg = new System.Windows.Forms.Button();
|
||||
@@ -134,8 +139,6 @@
|
||||
this.button_startBERtest = new System.Windows.Forms.Button();
|
||||
this.pb_audioCAPstatus = new System.Windows.Forms.PictureBox();
|
||||
this.pb_audioPBstatus = new System.Windows.Forms.PictureBox();
|
||||
this.progressBar_capfifo = new System.Windows.Forms.ProgressBar();
|
||||
this.label_capfifo = new System.Windows.Forms.Label();
|
||||
this.statusStrip1.SuspendLayout();
|
||||
this.tabPage1.SuspendLayout();
|
||||
this.tabPage2.SuspendLayout();
|
||||
@@ -155,6 +158,8 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.tb_PBvol)).BeginInit();
|
||||
this.groupBox2.SuspendLayout();
|
||||
this.tabPage4.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pb_rxsync)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pb_rxsignal)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox_rximage)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox_tximage)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
|
||||
@@ -882,7 +887,6 @@
|
||||
this.groupBox2.Controls.Add(this.tb_callsign);
|
||||
this.groupBox2.Controls.Add(this.label1);
|
||||
this.groupBox2.Controls.Add(this.cb_stampcall);
|
||||
this.groupBox2.Controls.Add(this.cb_savegoodfiles);
|
||||
this.groupBox2.Location = new System.Drawing.Point(12, 13);
|
||||
this.groupBox2.Name = "groupBox2";
|
||||
this.groupBox2.Size = new System.Drawing.Size(674, 126);
|
||||
@@ -1005,18 +1009,6 @@
|
||||
this.cb_stampcall.Text = "Insert Callsign into picture";
|
||||
this.cb_stampcall.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// cb_savegoodfiles
|
||||
//
|
||||
this.cb_savegoodfiles.AutoSize = true;
|
||||
this.cb_savegoodfiles.Checked = true;
|
||||
this.cb_savegoodfiles.CheckState = System.Windows.Forms.CheckState.Checked;
|
||||
this.cb_savegoodfiles.Location = new System.Drawing.Point(71, 102);
|
||||
this.cb_savegoodfiles.Name = "cb_savegoodfiles";
|
||||
this.cb_savegoodfiles.Size = new System.Drawing.Size(159, 17);
|
||||
this.cb_savegoodfiles.TabIndex = 3;
|
||||
this.cb_savegoodfiles.Text = "Save good files/images only";
|
||||
this.cb_savegoodfiles.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// tabPage4
|
||||
//
|
||||
this.tabPage4.Controls.Add(this.richTextBox1);
|
||||
@@ -1100,6 +1092,61 @@
|
||||
this.bt_blockinfo.UseVisualStyleBackColor = true;
|
||||
this.bt_blockinfo.Click += new System.EventHandler(this.bt_blockinfo_Click);
|
||||
//
|
||||
// progressBar_capfifo
|
||||
//
|
||||
this.progressBar_capfifo.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(192)))), ((int)(((byte)(128)))));
|
||||
this.progressBar_capfifo.Location = new System.Drawing.Point(658, 642);
|
||||
this.progressBar_capfifo.Name = "progressBar_capfifo";
|
||||
this.progressBar_capfifo.Size = new System.Drawing.Size(304, 18);
|
||||
this.progressBar_capfifo.Step = 1;
|
||||
this.progressBar_capfifo.Style = System.Windows.Forms.ProgressBarStyle.Continuous;
|
||||
this.progressBar_capfifo.TabIndex = 15;
|
||||
//
|
||||
// label_capfifo
|
||||
//
|
||||
this.label_capfifo.AutoSize = true;
|
||||
this.label_capfifo.Location = new System.Drawing.Point(567, 643);
|
||||
this.label_capfifo.Name = "label_capfifo";
|
||||
this.label_capfifo.Size = new System.Drawing.Size(56, 13);
|
||||
this.label_capfifo.TabIndex = 16;
|
||||
this.label_capfifo.Text = "RX Buffer:";
|
||||
//
|
||||
// lb_rxsignal
|
||||
//
|
||||
this.lb_rxsignal.AutoSize = true;
|
||||
this.lb_rxsignal.Location = new System.Drawing.Point(984, 643);
|
||||
this.lb_rxsignal.Name = "lb_rxsignal";
|
||||
this.lb_rxsignal.Size = new System.Drawing.Size(57, 13);
|
||||
this.lb_rxsignal.TabIndex = 18;
|
||||
this.lb_rxsignal.Text = "RX Signal:";
|
||||
//
|
||||
// lb_rxsync
|
||||
//
|
||||
this.lb_rxsync.AutoSize = true;
|
||||
this.lb_rxsync.Location = new System.Drawing.Point(1094, 643);
|
||||
this.lb_rxsync.Name = "lb_rxsync";
|
||||
this.lb_rxsync.Size = new System.Drawing.Size(52, 13);
|
||||
this.lb_rxsync.TabIndex = 20;
|
||||
this.lb_rxsync.Text = "RX Sync:";
|
||||
//
|
||||
// pb_rxsync
|
||||
//
|
||||
this.pb_rxsync.BackgroundImage = global::oscardata.Properties.Resources.redmarker;
|
||||
this.pb_rxsync.Location = new System.Drawing.Point(1155, 636);
|
||||
this.pb_rxsync.Name = "pb_rxsync";
|
||||
this.pb_rxsync.Size = new System.Drawing.Size(24, 24);
|
||||
this.pb_rxsync.TabIndex = 19;
|
||||
this.pb_rxsync.TabStop = false;
|
||||
//
|
||||
// pb_rxsignal
|
||||
//
|
||||
this.pb_rxsignal.BackgroundImage = global::oscardata.Properties.Resources.redmarker;
|
||||
this.pb_rxsignal.Location = new System.Drawing.Point(1047, 636);
|
||||
this.pb_rxsignal.Name = "pb_rxsignal";
|
||||
this.pb_rxsignal.Size = new System.Drawing.Size(24, 24);
|
||||
this.pb_rxsignal.TabIndex = 17;
|
||||
this.pb_rxsignal.TabStop = false;
|
||||
//
|
||||
// bt_rximages
|
||||
//
|
||||
this.bt_rximages.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
@@ -1354,30 +1401,15 @@
|
||||
this.pb_audioPBstatus.TabIndex = 17;
|
||||
this.pb_audioPBstatus.TabStop = false;
|
||||
//
|
||||
// progressBar_capfifo
|
||||
//
|
||||
this.progressBar_capfifo.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(192)))), ((int)(((byte)(128)))));
|
||||
this.progressBar_capfifo.Location = new System.Drawing.Point(658, 642);
|
||||
this.progressBar_capfifo.Name = "progressBar_capfifo";
|
||||
this.progressBar_capfifo.Size = new System.Drawing.Size(304, 18);
|
||||
this.progressBar_capfifo.Step = 1;
|
||||
this.progressBar_capfifo.Style = System.Windows.Forms.ProgressBarStyle.Continuous;
|
||||
this.progressBar_capfifo.TabIndex = 15;
|
||||
//
|
||||
// label_capfifo
|
||||
//
|
||||
this.label_capfifo.AutoSize = true;
|
||||
this.label_capfifo.Location = new System.Drawing.Point(567, 643);
|
||||
this.label_capfifo.Name = "label_capfifo";
|
||||
this.label_capfifo.Size = new System.Drawing.Size(56, 13);
|
||||
this.label_capfifo.TabIndex = 16;
|
||||
this.label_capfifo.Text = "RX Buffer:";
|
||||
//
|
||||
// Form1
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1293, 691);
|
||||
this.Controls.Add(this.lb_rxsync);
|
||||
this.Controls.Add(this.pb_rxsync);
|
||||
this.Controls.Add(this.lb_rxsignal);
|
||||
this.Controls.Add(this.pb_rxsignal);
|
||||
this.Controls.Add(this.label_capfifo);
|
||||
this.Controls.Add(this.progressBar_capfifo);
|
||||
this.Controls.Add(this.bt_blockinfo);
|
||||
@@ -1423,6 +1455,8 @@
|
||||
this.groupBox2.ResumeLayout(false);
|
||||
this.groupBox2.PerformLayout();
|
||||
this.tabPage4.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.pb_rxsync)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pb_rxsignal)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox_rximage)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox_tximage)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
|
||||
@@ -1486,7 +1520,6 @@
|
||||
private System.Windows.Forms.TextBox tb_callsign;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.CheckBox cb_stampcall;
|
||||
private System.Windows.Forms.CheckBox cb_savegoodfiles;
|
||||
private System.Windows.Forms.TextBox tb_shutdown;
|
||||
private System.Windows.Forms.Button bt_shutdown;
|
||||
private System.Windows.Forms.Button bt_resetmodem;
|
||||
@@ -1545,6 +1578,10 @@
|
||||
private System.Windows.Forms.PictureBox pb_voice;
|
||||
private System.Windows.Forms.ProgressBar progressBar_capfifo;
|
||||
private System.Windows.Forms.Label label_capfifo;
|
||||
private System.Windows.Forms.PictureBox pb_rxsignal;
|
||||
private System.Windows.Forms.Label lb_rxsignal;
|
||||
private System.Windows.Forms.Label lb_rxsync;
|
||||
private System.Windows.Forms.PictureBox pb_rxsync;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ using System.IO;
|
||||
using System.Drawing.Drawing2D;
|
||||
using System.Diagnostics;
|
||||
using System.Threading;
|
||||
using oscardata.Properties;
|
||||
|
||||
namespace oscardata
|
||||
{
|
||||
@@ -55,11 +56,7 @@ namespace oscardata
|
||||
OperatingSystem osversion = System.Environment.OSVersion;
|
||||
statics.OSversion = osversion.Platform.ToString();
|
||||
if (osversion.VersionString.Contains("indow"))
|
||||
{
|
||||
statics.ostype = 0;
|
||||
tb_shutdown.Visible = false;
|
||||
bt_shutdown.Visible = false;
|
||||
}
|
||||
else
|
||||
statics.ostype = 1; // Linux
|
||||
|
||||
@@ -92,8 +89,6 @@ namespace oscardata
|
||||
timer_udpTX.Enabled = true;
|
||||
timer_udprx.Enabled = true;
|
||||
timer_searchmodem.Enabled = true;
|
||||
|
||||
//pictureBox_rximage.BackgroundImage = Image.FromFile("/tmp/temp293.jpg");
|
||||
}
|
||||
|
||||
// TX timer
|
||||
@@ -509,14 +504,19 @@ namespace oscardata
|
||||
|
||||
panel_txspectrum.Invalidate();
|
||||
|
||||
// show RX and TX Buffer Usage
|
||||
if (statics.PBfifousage < progressBar_fifo.Minimum) progressBar_fifo.Value = progressBar_fifo.Minimum;
|
||||
else if (statics.PBfifousage >= progressBar_fifo.Maximum) progressBar_fifo.Value = progressBar_fifo.Maximum-1;
|
||||
else progressBar_fifo.Value = statics.PBfifousage;
|
||||
|
||||
progressBar_capfifo.Invalidate();
|
||||
if (statics.CAPfifousage < progressBar_capfifo.Minimum) progressBar_capfifo.Value = progressBar_capfifo.Minimum;
|
||||
else if (statics.CAPfifousage >= progressBar_capfifo.Maximum) progressBar_capfifo.Value = progressBar_capfifo.Maximum - 1;
|
||||
else progressBar_capfifo.Value = statics.CAPfifousage;
|
||||
if (statics.CAPfifousage > 50) progressBar_capfifo.ForeColor = Color.Red; else progressBar_capfifo.ForeColor = Color.Green;
|
||||
|
||||
// Show RX Status LEDs
|
||||
if (statics.RXlevelDetected == 1) pb_rxsignal.BackgroundImage = Resources.greenmarker; else pb_rxsignal.BackgroundImage = Resources.redmarker;
|
||||
if (statics.RXinSync == 1 && statics.RXlevelDetected == 1) pb_rxsync.BackgroundImage = Resources.greenmarker; else pb_rxsync.BackgroundImage = Resources.redmarker;
|
||||
}
|
||||
|
||||
private void panel_constel_Paint(object sender, PaintEventArgs e)
|
||||
@@ -721,10 +721,10 @@ namespace oscardata
|
||||
|
||||
// random filename for picturebox control (picturebox cannot reload image from actual filename)
|
||||
try {
|
||||
//File.Delete(TXimagefilename);
|
||||
//statics.FileDelete(TXimagefilename);
|
||||
// delete also older unused files
|
||||
foreach (string f in Directory.EnumerateFiles(statics.addTmpPath(""), "tempTX*.jpg"))
|
||||
File.Delete(f);
|
||||
statics.FileDelete(f);
|
||||
} catch { }
|
||||
Random randNum = new Random();
|
||||
TXimagefilename = statics.addTmpPath("tempTX" + randNum.Next(0, 65000).ToString() + ".jpg");
|
||||
@@ -1028,6 +1028,12 @@ namespace oscardata
|
||||
label_capfifo.Location = new Point(label_fifo.Location.X, label_fifo.Location.Y + y);
|
||||
progressBar_capfifo.Location = new Point(progressBar_fifo.Location.X, progressBar_fifo.Location.Y + y);
|
||||
progressBar_capfifo.Size = new Size(progressBar_capfifo.Width, 18);
|
||||
|
||||
lb_rxsignal.Location = new Point(progressBar_capfifo.Location.X + progressBar_capfifo.Size.Width + 15, label_capfifo.Location.Y);
|
||||
pb_rxsignal.Location = new Point(lb_rxsignal.Location.X + lb_rxsignal.Size.Width + 2, label_capfifo.Location.Y-5);
|
||||
|
||||
lb_rxsync.Location = new Point(pb_rxsignal.Location.X + pb_rxsignal.Size.Width + 15, label_capfifo.Location.Y);
|
||||
pb_rxsync.Location = new Point(lb_rxsync.Location.X + lb_rxsync.Size.Width + 2, label_capfifo.Location.Y-5);
|
||||
}
|
||||
|
||||
public String GetMyBroadcastIP()
|
||||
@@ -1114,7 +1120,7 @@ namespace oscardata
|
||||
private void bt_file_send_Click(object sender, EventArgs e)
|
||||
{
|
||||
rtb_RXfile.Text = "";
|
||||
File.Delete(statics.zip_RXtempfilename);
|
||||
statics.FileDelete(statics.zip_RXtempfilename);
|
||||
|
||||
Byte[] textarr = File.ReadAllBytes(statics.zip_TXtempfilename);
|
||||
ArraySend.Send(textarr, (Byte)txcommand, TXfilename, TXRealFilename);
|
||||
@@ -1244,11 +1250,15 @@ namespace oscardata
|
||||
|
||||
private String ReadString(StreamReader sr)
|
||||
{
|
||||
String s = sr.ReadLine();
|
||||
if (s != null)
|
||||
try
|
||||
{
|
||||
return s;
|
||||
String s = sr.ReadLine();
|
||||
if (s != null)
|
||||
{
|
||||
return s;
|
||||
}
|
||||
}
|
||||
catch { }
|
||||
return " ";
|
||||
}
|
||||
|
||||
@@ -1280,7 +1290,7 @@ namespace oscardata
|
||||
String s = ReadString(sr);
|
||||
cb_stampcall.Checked = (s == "1");
|
||||
s = ReadString(sr);
|
||||
cb_savegoodfiles.Checked = (s == "1");
|
||||
// free for other usage
|
||||
cb_audioPB.Text = ReadString(sr);
|
||||
cb_audioCAP.Text = ReadString(sr);
|
||||
tb_PBvol.Value = ReadInt(sr);
|
||||
@@ -1323,7 +1333,7 @@ namespace oscardata
|
||||
sw.WriteLine(tb_callsign.Text);
|
||||
sw.WriteLine(cb_speed.Text);
|
||||
sw.WriteLine(cb_stampcall.Checked?"1":"0");
|
||||
sw.WriteLine(cb_savegoodfiles.Checked ? "1" : "0");
|
||||
sw.WriteLine("0"); // free for other use
|
||||
sw.WriteLine(cb_audioPB.Text);
|
||||
sw.WriteLine(cb_audioCAP.Text);
|
||||
sw.WriteLine(tb_PBvol.Value.ToString());
|
||||
|
||||
@@ -137,7 +137,7 @@
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAABw
|
||||
FwAAAk1TRnQBSQFMAgEBDQEAAbABAAGwAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
FwAAAk1TRnQBSQFMAgEBDQEAAcgBAAHIAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
AwABQAMAAUADAAEBAQABCAYAARAYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
|
||||
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
|
||||
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
|
||||
|
||||
@@ -150,6 +150,16 @@ namespace oscardata.Properties {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap greenmarker {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("greenmarker", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
@@ -230,6 +240,16 @@ namespace oscardata.Properties {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap redmarker {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("redmarker", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
|
||||
@@ -202,4 +202,10 @@
|
||||
<data name="cdc_intloop" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>cdc_intloop.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="greenmarker" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>greenmarker.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="redmarker" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>redmarker.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
</root>
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 5.9 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 9.9 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
@@ -74,6 +74,8 @@ namespace oscardata
|
||||
public static int CAPfifousage = 0;
|
||||
public static int initAudioStatus;
|
||||
public static int initVoiceStatus;
|
||||
public static int RXlevelDetected = 0;
|
||||
public static int RXinSync = 0;
|
||||
|
||||
|
||||
public static String[] getOwnIPs()
|
||||
@@ -399,5 +401,14 @@ namespace oscardata
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
|
||||
public static void FileDelete(String fn)
|
||||
{
|
||||
try
|
||||
{
|
||||
File.Delete(fn);
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace oscardata
|
||||
encoder_params.Param[0] = new EncoderParameter(System.Drawing.Imaging.Encoder.Quality, compression);
|
||||
|
||||
ImageCodecInfo image_codec_info = GetEncoderInfo("image/jpeg");
|
||||
File.Delete(file_name);
|
||||
statics.FileDelete(file_name);
|
||||
image.Save(file_name, image_codec_info, encoder_params);
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
@@ -111,13 +111,6 @@
|
||||
<ItemGroup>
|
||||
<None Include="Properties\image.jpg" />
|
||||
<None Include="Properties\image1.jpg" />
|
||||
<None Include="Properties\image2.jpg" />
|
||||
<None Include="Properties\App-voice-support-headset-icon.png" />
|
||||
<None Include="Properties\Categories-preferences-system-icon.png" />
|
||||
<None Include="Properties\Downloads-1-icon.png" />
|
||||
<None Include="Properties\Mimetypes-text-csv-icon.png" />
|
||||
<None Include="Properties\Photography-icon.png" />
|
||||
<None Include="Properties\Mimetypes-text-html-icon.png" />
|
||||
<None Include="Properties\binary.png" />
|
||||
<None Include="Properties\cancel.png" />
|
||||
<None Include="Properties\html.png" />
|
||||
@@ -144,6 +137,8 @@
|
||||
<None Include="Properties\cdc_intloop.png" />
|
||||
<None Include="Properties\textrx.png" />
|
||||
<None Include="Properties\texttx.png" />
|
||||
<None Include="Properties\greenmarker.png" />
|
||||
<None Include="Properties\redmarker.png" />
|
||||
<Content Include="Satellite-icon.ico" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
|
||||
@@ -1,4 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="MathNet.Numerics" version="4.12.0" targetFramework="net40" />
|
||||
</packages>
|
||||
@@ -102,7 +102,7 @@ namespace oscardata
|
||||
if (!StartFileRX()) return false; // invalid file
|
||||
}
|
||||
|
||||
if (minfo != statics.FirstFrame)
|
||||
if (receiving && minfo != statics.FirstFrame)
|
||||
runtime = DateTime.UtcNow - starttime;
|
||||
|
||||
// receive continous frames of a transmission
|
||||
@@ -403,29 +403,35 @@ namespace oscardata
|
||||
|
||||
// reception was ok, blockfile no more needed, delete it
|
||||
// file is OK, blockfile no more needed, delete it
|
||||
try { File.Delete(blockFilename); } catch { }
|
||||
try { statics.FileDelete(blockFilename); } catch { }
|
||||
|
||||
// make filename
|
||||
filename = makeRXfilename();
|
||||
|
||||
Console.WriteLine("save at " + filename);
|
||||
|
||||
using (BinaryWriter writer = new BinaryWriter(File.Open(filename, FileMode.Create)))
|
||||
try
|
||||
{
|
||||
for (int i = 0; i <= blockidx; i++)
|
||||
using (BinaryWriter writer = new BinaryWriter(File.Open(filename, FileMode.Create)))
|
||||
{
|
||||
if (i == 0)
|
||||
writer.Write(firstblock);
|
||||
else
|
||||
for (int i = 0; i <= blockidx; i++)
|
||||
{
|
||||
Byte[] blk = new byte[statics.PayloadLen];
|
||||
for (int j = 0; j < statics.PayloadLen; j++)
|
||||
blk[j] = blockbuf[i, j];
|
||||
if (i == 0)
|
||||
writer.Write(firstblock);
|
||||
else
|
||||
{
|
||||
Byte[] blk = new byte[statics.PayloadLen];
|
||||
for (int j = 0; j < statics.PayloadLen; j++)
|
||||
blk[j] = blockbuf[i, j];
|
||||
|
||||
writer.Write(blk);
|
||||
writer.Write(blk);
|
||||
}
|
||||
}
|
||||
writer.Close();
|
||||
}
|
||||
writer.Close();
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
|
||||
return true;
|
||||
@@ -501,7 +507,7 @@ namespace oscardata
|
||||
fdest = statics.getHomePath("", fdest);
|
||||
// fdest is the file in the oscardata's user home directoty
|
||||
// remove old file with same name
|
||||
try { File.Delete(fdest); } catch { }
|
||||
try { statics.FileDelete(fdest); } catch { }
|
||||
// move the unzipped file to the final location
|
||||
File.Move(fl, fdest);
|
||||
filesize = statics.GetFileSize(fdest);
|
||||
@@ -510,7 +516,7 @@ namespace oscardata
|
||||
else
|
||||
StatusText = "unzip failed";
|
||||
|
||||
File.Delete(statics.zip_RXtempfilename);
|
||||
statics.FileDelete(statics.zip_RXtempfilename);
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
||||
@@ -122,8 +122,10 @@ namespace oscardata
|
||||
{
|
||||
statics.PBfifousage = b[0];
|
||||
statics.CAPfifousage = b[1];
|
||||
Byte[] b1 = new byte[b.Length - 2];
|
||||
Array.Copy(b, 2, b1, 0, b1.Length);
|
||||
statics.RXlevelDetected = b[2];
|
||||
statics. RXinSync = b[3];
|
||||
Byte[] b1 = new byte[b.Length - 4];
|
||||
Array.Copy(b, 4, b1, 0, b1.Length);
|
||||
uq_fft.Add(b1);
|
||||
}
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ namespace oscardata
|
||||
{
|
||||
try
|
||||
{
|
||||
File.Delete(zipfilename);
|
||||
statics.FileDelete(zipfilename);
|
||||
}
|
||||
catch { }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user