kopia lustrzana https://github.com/jamescoxon/dl-fldigi
CW shape modification
* removed exponential wave shape * substituted Blackman for the sine wave shapepull/2/head
rodzic
d98d95ff53
commit
fc4a43601d
|
@ -531,21 +531,16 @@ void cw::makeshape()
|
|||
if (knum > KNUM)
|
||||
knum = KNUM;
|
||||
|
||||
for (int i = 0; i < knum; i++) {
|
||||
switch (QSKshape) {
|
||||
case 0:
|
||||
keyshape[i] = 0.5 * (1.0 - cos (M_PI * i / knum));
|
||||
break;
|
||||
case 1:
|
||||
keyshape[i] = 1.0 - exp(-3.0 * i / knum);
|
||||
break;
|
||||
case 2:
|
||||
keyshape[i] = sin (0.5 * M_PI * i / knum);
|
||||
case 1: // blackman
|
||||
for (int i = 0; i < knum; i++)
|
||||
keyshape[i] = (0.42 - 0.50 * cos(M_PI * i/ knum) + 0.08 * cos(2 * M_PI * i / knum));
|
||||
break;
|
||||
case 0: // raised cosine (hanning)
|
||||
default:
|
||||
for (int i = 0; i < knum; i++)
|
||||
keyshape[i] = 0.5 * (1.0 - cos (M_PI * i / knum));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
inline double cw::nco(double freq)
|
||||
|
|
|
@ -2737,6 +2737,7 @@ an merging"));
|
|||
tabsCW->selection_color(FL_LIGHT1);
|
||||
{ Fl_Group* o = new Fl_Group(0, 75, 500, 295, _("General"));
|
||||
o->align(FL_ALIGN_TOP_LEFT);
|
||||
o->hide();
|
||||
{ Fl_Group* o = new Fl_Group(5, 85, 490, 130, _("Receive"));
|
||||
o->box(FL_ENGRAVED_FRAME);
|
||||
o->align(FL_ALIGN_TOP_LEFT|FL_ALIGN_INSIDE);
|
||||
|
@ -2839,7 +2840,6 @@ an merging"));
|
|||
} // Fl_Group* o
|
||||
{ Fl_Group* o = new Fl_Group(0, 75, 500, 295, _("Timing and QSK"));
|
||||
o->align(FL_ALIGN_TOP_LEFT);
|
||||
o->hide();
|
||||
{ Fl_Group* o = new Fl_Group(5, 85, 490, 120, _("Timing"));
|
||||
o->box(FL_ENGRAVED_FRAME);
|
||||
o->align(FL_ALIGN_TOP_LEFT|FL_ALIGN_INSIDE);
|
||||
|
@ -2877,11 +2877,11 @@ an merging"));
|
|||
o->value(progdefaults.CWrisetime);
|
||||
} // Fl_Counter* cntCWrisetime
|
||||
{ Fl_Choice* o = mnuQSKshape = new Fl_Choice(15, 144, 112, 20, _("Edge shape"));
|
||||
mnuQSKshape->tooltip(_("Leading and Trailing edge shape"));
|
||||
mnuQSKshape->tooltip(_("Raised cosine = Hanning"));
|
||||
mnuQSKshape->down_box(FL_BORDER_BOX);
|
||||
mnuQSKshape->callback((Fl_Callback*)cb_mnuQSKshape);
|
||||
mnuQSKshape->align(FL_ALIGN_RIGHT);
|
||||
o->add("Raised Cos|Expontial|Sine");
|
||||
o->add("Hanning|Blackman");
|
||||
o->value(progdefaults.QSKshape);
|
||||
} // Fl_Choice* mnuQSKshape
|
||||
{ Fl_Check_Button* o = btnCWnarrow = new Fl_Check_Button(15, 175, 225, 15, _("Edge decreases pulse width"));
|
||||
|
|
|
@ -694,7 +694,7 @@ behaves inside the waterfall} xywh {15 196 150 22} down_box BORDER_BOX align 8
|
|||
} {
|
||||
Fl_Group {} {
|
||||
label General open
|
||||
xywh {0 75 500 295} align 5
|
||||
xywh {0 75 500 295} align 5 hide
|
||||
} {
|
||||
Fl_Group {} {
|
||||
label Receive open
|
||||
|
@ -777,7 +777,7 @@ cntCWlowerlimit->maximum(o->value()-20);}
|
|||
}
|
||||
Fl_Group {} {
|
||||
label {Timing and QSK} open
|
||||
xywh {0 75 500 295} align 5 hide
|
||||
xywh {0 75 500 295} align 5
|
||||
} {
|
||||
Fl_Group {} {
|
||||
label Timing open
|
||||
|
@ -808,8 +808,8 @@ progdefaults.changed = true;}
|
|||
label {Edge shape}
|
||||
callback {progdefaults.QSKshape = o->value();
|
||||
progdefaults.changed = true;} open
|
||||
tooltip {Leading and Trailing edge shape} xywh {15 144 112 20} down_box BORDER_BOX align 8
|
||||
code0 {o->add("Raised Cos|Expontial|Sine");}
|
||||
tooltip {Raised cosine = Hanning} xywh {15 144 112 20} down_box BORDER_BOX align 8
|
||||
code0 {o->add("Hanning|Blackman");}
|
||||
code1 {o->value(progdefaults.QSKshape);}
|
||||
} {}
|
||||
Fl_Check_Button btnCWnarrow {
|
||||
|
|
Ładowanie…
Reference in New Issue