mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-02-03 09:44:24 -05:00
More work in progress toward "Export .wav file ..." in QMAP.
This commit is contained in:
parent
6474f7e1cf
commit
0705bd329e
@ -44,16 +44,19 @@ subroutine q65b(nutc,nqd,fcenter,nfcal,nfsample,ikhz,mousedf,ntol, &
|
||||
! Find best frequency from sync_dat, the "orange sync curve".
|
||||
df3=96000.0/32768.0
|
||||
ipk=(1000.0*f0-1.0)/df3
|
||||
if(nagain.ge.2) then
|
||||
f_mouse=1000.0*(fqso+ikhz-48.0) + mousedf - 1270.0
|
||||
ipk = nint(f_mouse/df3)
|
||||
endif
|
||||
nfft1=MAXFFT1
|
||||
nfft2=MAXFFT2
|
||||
df=96000.0/NFFT1
|
||||
nh=nfft2/2
|
||||
f_mouse=1000.0*(fqso+48.0) + mousedf
|
||||
k0=nint((ipk*df3-1000.0)/df)
|
||||
if(k0.lt.nh .or. k0.gt.MAXFFT1-nfft2+1) go to 900
|
||||
fac=1.0/nfft2
|
||||
cx(0:nfft2-1)=ca(k0:k0+nfft2-1)
|
||||
cx=fac*cx
|
||||
if(nagain.ge.2) print*,nagain,k0,k0*df
|
||||
cx(0:nfft2-1)=fac*ca(k0:k0+nfft2-1)
|
||||
|
||||
! Here cx is frequency-domain data around the selected
|
||||
! QSO frequency, taken from the full-length FFT computed in fftbig().
|
||||
@ -110,18 +113,28 @@ subroutine q65b(nutc,nqd,fcenter,nfcal,nfsample,ikhz,mousedf,ntol, &
|
||||
if(iseq.eq.1) datetime1(12:13)='30'
|
||||
endif
|
||||
|
||||
! if(nagain.eq.2) then
|
||||
! h=default_header(12000,30*12000)
|
||||
! ifile=ifile+1
|
||||
! write(fname,1000) ifile
|
||||
!1000 format('000000_',i6.6,'.wav')
|
||||
! open(27,file=fname,status='unknown',access='stream')
|
||||
! ia=ifile*30*12000 + 1
|
||||
! ib=ia + 30*12000 - 1
|
||||
! write(27) h,iwave(ia:ib)
|
||||
! close(27)
|
||||
! endif
|
||||
! print*,'A',nagain,ifile,fname
|
||||
if(nagain.ge.2) then
|
||||
ifile=ifile+1
|
||||
write(fname,1000) ifile
|
||||
1000 format('000000_',i6.6,'.wav')
|
||||
open(27,file=fname,status='unknown',access='stream')
|
||||
if(nagain.eq.2) then
|
||||
h=default_header(12000,60*12000)
|
||||
ia=1
|
||||
ib=60*12000
|
||||
else if(nagain.eq.3) then
|
||||
h=default_header(12000,30*12000)
|
||||
ia=1
|
||||
ib=30*12000
|
||||
else
|
||||
h=default_header(12000,30*12000)
|
||||
ia=30*12000 + 1
|
||||
ib=60*12000
|
||||
endif
|
||||
write(27) h,iwave(ia:ib)
|
||||
close(27)
|
||||
go to 900
|
||||
endif
|
||||
|
||||
! NB: Frequency of ipk is now shifted to 1000 Hz.
|
||||
nagain2=0
|
||||
|
@ -951,6 +951,7 @@ void MainWindow::decode() //decode()
|
||||
memcpy(savecom_.saveFileName, m_saveFileName.toLatin1(),len1);
|
||||
|
||||
ui->actionExport_wav_file_at_fQSO->setEnabled(m_diskData);
|
||||
qDebug() << "aa" << datcom2_.nagain;
|
||||
watcher3.setFuture(QtConcurrent::run (q65c_));
|
||||
decodeBusy(true);
|
||||
}
|
||||
@ -1187,8 +1188,20 @@ void MainWindow::on_sbMaxDrift_valueChanged(int n)
|
||||
|
||||
void MainWindow::on_actionExport_wav_file_at_fQSO_triggered()
|
||||
{
|
||||
qDebug() << "Export .wav file" << m_path;
|
||||
datcom_.newdat=0;
|
||||
datcom_.nagain=2;
|
||||
decode();
|
||||
}
|
||||
|
||||
void MainWindow::on_actionExport_wav_file_at_fQSO_30a_triggered()
|
||||
{
|
||||
datcom_.newdat=0;
|
||||
datcom_.nagain=3;
|
||||
decode();
|
||||
}
|
||||
|
||||
void MainWindow::on_actionExport_wav_file_at_fQSO_30b_triggered()
|
||||
{
|
||||
datcom_.newdat=0;
|
||||
datcom_.nagain=4;
|
||||
decode();}
|
||||
|
@ -86,6 +86,10 @@ private slots:
|
||||
void on_actionSave_decoded_triggered();
|
||||
void on_actionExport_wav_file_at_fQSO_triggered();
|
||||
|
||||
void on_actionExport_wav_file_at_fQSO_30a_triggered();
|
||||
|
||||
void on_actionExport_wav_file_at_fQSO_30b_triggered();
|
||||
|
||||
private:
|
||||
Ui::MainWindow *ui;
|
||||
QString m_appDir;
|
||||
|
@ -435,6 +435,8 @@ p, li { white-space: pre-wrap; }
|
||||
<addaction name="actionDelete_all_iq_files_in_SaveDir"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionExport_wav_file_at_fQSO"/>
|
||||
<addaction name="actionExport_wav_file_at_fQSO_30a"/>
|
||||
<addaction name="actionExport_wav_file_at_fQSO_30b"/>
|
||||
<addaction name="actionSettings"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionExit"/>
|
||||
@ -858,7 +860,17 @@ p, li { white-space: pre-wrap; }
|
||||
</action>
|
||||
<action name="actionExport_wav_file_at_fQSO">
|
||||
<property name="text">
|
||||
<string>Export .wav file at fQSO</string>
|
||||
<string>Export .wav file at fQSO (60 s)</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionExport_wav_file_at_fQSO_30b">
|
||||
<property name="text">
|
||||
<string>Export .wav file at fQSO (30 s, second part)</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionExport_wav_file_at_fQSO_30a">
|
||||
<property name="text">
|
||||
<string>Export .wav file at fQSO (30 s, first part)</string>
|
||||
</property>
|
||||
</action>
|
||||
</widget>
|
||||
|
Loading…
Reference in New Issue
Block a user