mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-09-05 14:47:54 -04: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".
|
! Find best frequency from sync_dat, the "orange sync curve".
|
||||||
df3=96000.0/32768.0
|
df3=96000.0/32768.0
|
||||||
ipk=(1000.0*f0-1.0)/df3
|
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
|
nfft1=MAXFFT1
|
||||||
nfft2=MAXFFT2
|
nfft2=MAXFFT2
|
||||||
df=96000.0/NFFT1
|
df=96000.0/NFFT1
|
||||||
nh=nfft2/2
|
nh=nfft2/2
|
||||||
f_mouse=1000.0*(fqso+48.0) + mousedf
|
|
||||||
k0=nint((ipk*df3-1000.0)/df)
|
k0=nint((ipk*df3-1000.0)/df)
|
||||||
if(k0.lt.nh .or. k0.gt.MAXFFT1-nfft2+1) go to 900
|
if(k0.lt.nh .or. k0.gt.MAXFFT1-nfft2+1) go to 900
|
||||||
fac=1.0/nfft2
|
fac=1.0/nfft2
|
||||||
cx(0:nfft2-1)=ca(k0:k0+nfft2-1)
|
if(nagain.ge.2) print*,nagain,k0,k0*df
|
||||||
cx=fac*cx
|
cx(0:nfft2-1)=fac*ca(k0:k0+nfft2-1)
|
||||||
|
|
||||||
! Here cx is frequency-domain data around the selected
|
! Here cx is frequency-domain data around the selected
|
||||||
! QSO frequency, taken from the full-length FFT computed in fftbig().
|
! 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'
|
if(iseq.eq.1) datetime1(12:13)='30'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
! if(nagain.eq.2) then
|
if(nagain.ge.2) then
|
||||||
! h=default_header(12000,30*12000)
|
ifile=ifile+1
|
||||||
! ifile=ifile+1
|
write(fname,1000) ifile
|
||||||
! write(fname,1000) ifile
|
1000 format('000000_',i6.6,'.wav')
|
||||||
!1000 format('000000_',i6.6,'.wav')
|
open(27,file=fname,status='unknown',access='stream')
|
||||||
! open(27,file=fname,status='unknown',access='stream')
|
if(nagain.eq.2) then
|
||||||
! ia=ifile*30*12000 + 1
|
h=default_header(12000,60*12000)
|
||||||
! ib=ia + 30*12000 - 1
|
ia=1
|
||||||
! write(27) h,iwave(ia:ib)
|
ib=60*12000
|
||||||
! close(27)
|
else if(nagain.eq.3) then
|
||||||
! endif
|
h=default_header(12000,30*12000)
|
||||||
! print*,'A',nagain,ifile,fname
|
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.
|
! NB: Frequency of ipk is now shifted to 1000 Hz.
|
||||||
nagain2=0
|
nagain2=0
|
||||||
|
@ -951,6 +951,7 @@ void MainWindow::decode() //decode()
|
|||||||
memcpy(savecom_.saveFileName, m_saveFileName.toLatin1(),len1);
|
memcpy(savecom_.saveFileName, m_saveFileName.toLatin1(),len1);
|
||||||
|
|
||||||
ui->actionExport_wav_file_at_fQSO->setEnabled(m_diskData);
|
ui->actionExport_wav_file_at_fQSO->setEnabled(m_diskData);
|
||||||
|
qDebug() << "aa" << datcom2_.nagain;
|
||||||
watcher3.setFuture(QtConcurrent::run (q65c_));
|
watcher3.setFuture(QtConcurrent::run (q65c_));
|
||||||
decodeBusy(true);
|
decodeBusy(true);
|
||||||
}
|
}
|
||||||
@ -1187,8 +1188,20 @@ void MainWindow::on_sbMaxDrift_valueChanged(int n)
|
|||||||
|
|
||||||
void MainWindow::on_actionExport_wav_file_at_fQSO_triggered()
|
void MainWindow::on_actionExport_wav_file_at_fQSO_triggered()
|
||||||
{
|
{
|
||||||
qDebug() << "Export .wav file" << m_path;
|
|
||||||
datcom_.newdat=0;
|
datcom_.newdat=0;
|
||||||
datcom_.nagain=2;
|
datcom_.nagain=2;
|
||||||
decode();
|
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_actionSave_decoded_triggered();
|
||||||
void on_actionExport_wav_file_at_fQSO_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:
|
private:
|
||||||
Ui::MainWindow *ui;
|
Ui::MainWindow *ui;
|
||||||
QString m_appDir;
|
QString m_appDir;
|
||||||
|
@ -435,6 +435,8 @@ p, li { white-space: pre-wrap; }
|
|||||||
<addaction name="actionDelete_all_iq_files_in_SaveDir"/>
|
<addaction name="actionDelete_all_iq_files_in_SaveDir"/>
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="actionExport_wav_file_at_fQSO"/>
|
<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="actionSettings"/>
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="actionExit"/>
|
<addaction name="actionExit"/>
|
||||||
@ -858,7 +860,17 @@ p, li { white-space: pre-wrap; }
|
|||||||
</action>
|
</action>
|
||||||
<action name="actionExport_wav_file_at_fQSO">
|
<action name="actionExport_wav_file_at_fQSO">
|
||||||
<property name="text">
|
<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>
|
</property>
|
||||||
</action>
|
</action>
|
||||||
</widget>
|
</widget>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user