diff --git a/astro.cpp b/astro.cpp index f861a6ce2..c2ccbde3e 100644 --- a/astro.cpp +++ b/astro.cpp @@ -45,8 +45,8 @@ void Astro::astroUpdate(QDateTime t, QString mygrid, QString hisgrid, if(!astroBusy) { astroBusy=true; - astrosub_(&nyear, &month, &nday, &uth, &nfreq, mygrid.toAscii(), - hisgrid.toAscii(), &azsun, &elsun, &azmoon, &elmoon, + astrosub_(&nyear, &month, &nday, &uth, &nfreq, mygrid.toLatin1(), + hisgrid.toLatin1(), &azsun, &elsun, &azmoon, &elmoon, &azmoondx, &elmoondx, &ntsky, &ndop, &ndop00,&ramoon, &decmoon, &dgrd, &poloffset, &xnr, 6, 6); astroBusy=false; diff --git a/devsetup.cpp b/devsetup.cpp index bf98ae204..743231275 100644 --- a/devsetup.cpp +++ b/devsetup.cpp @@ -109,7 +109,7 @@ void DevSetup::initDlg() ui.mult570SpinBox->setValue(m_mult570); ui.mult570TxSpinBox->setValue(m_mult570Tx); ui.cal570SpinBox->setValue(m_cal570); - sscanf(m_colors.toAscii(),"%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x", + sscanf(m_colors.toLatin1(),"%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x%2x", &r,&g,&b,&r0,&g0,&b0,&r1,&g1,&b1,&r2,&g2,&b2,&r3,&g3,&b3); updateColorLabels(); ui.sbBackgroundRed->setValue(r); diff --git a/getfile.cpp b/getfile.cpp index 8178a4dd9..3cfba38cf 100644 --- a/getfile.cpp +++ b/getfile.cpp @@ -18,7 +18,7 @@ void getfile(QString fname, bool xpol, int dbDgrd, int nfast) memset(id,0,2*npts); char name[80]; - strcpy(name,fname.toAscii()); + strcpy(name,fname.toLatin1()); FILE* fp=fopen(name,"rb"); if(fp != NULL) { @@ -66,7 +66,7 @@ void savetf2(QString fname, bool xpol, int nfast) qint16* buf=(qint16*)malloc(2*npts); char name[80]; - strcpy(name,fname.toAscii()); + strcpy(name,fname.toLatin1()); FILE* fp=fopen(name,"wb"); if(fp != NULL) { diff --git a/libm65/four2a.f90 b/libm65/four2a.f90 index 9cad07bb0..e1fd72fdd 100644 --- a/libm65/four2a.f90 +++ b/libm65/four2a.f90 @@ -34,7 +34,8 @@ subroutine four2a(a,nfft,ndim,isign,iform) if(nfft.eq.nn(i) .and. isign.eq.ns(i) .and. & iform.eq.nf(i) .and. nloc.eq.nl(i)) go to 10 enddo - if(nplan.ge.NPMAX) stop 'Too many FFTW plans requested.' +! if(nplan.ge.NPMAX) stop 'Too many FFTW plans requested.' + if(nplan.ge.NPMAX) call exit(1) nplan=nplan+1 i=nplan nn(i)=nfft @@ -76,7 +77,8 @@ subroutine four2a(a,nfft,ndim,isign,iform) else if(isign.eq.1 .and. iform.eq.-1) then call sfftw_plan_dft_c2r_1d(plan(i),nfft,a,a,nflags) else - stop 'Unsupported request in four2a' +! stop 'Unsupported request in four2a' + call exit(1) endif i=nplan if(nfft.le.NSMALL) then diff --git a/libm65/nchar.f b/libm65/nchar.f index 1da9a9813..a13148668 100644 --- a/libm65/nchar.f +++ b/libm65/nchar.f @@ -15,7 +15,7 @@ C Convert ascii number, letter, or space to 0-36 for callsign packing. n=36 else Print*,'Invalid character in callsign ',c,' ',ichar(c) - stop + call exit(1) endif nchar=n diff --git a/main.cpp b/main.cpp index 59441af50..3c045f667 100644 --- a/main.cpp +++ b/main.cpp @@ -1,5 +1,10 @@ +#ifdef QT5 +#include +#else #include -#include +#endif +#include + #include "mainwindow.h" int main(int argc, char *argv[]) diff --git a/mainwindow.cpp b/mainwindow.cpp index 6cca43788..2c061b77a 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -10,7 +10,7 @@ #include "bandmap.h" #include "txtune.h" #include "sleep.h" -#include +#include "portaudio.h" #define NFFT 32768 @@ -157,8 +157,8 @@ MainWindow::MainWindow(QWidget *parent) : iqAmp=0; iqPhase=0; - ui->xThermo->setFillBrush(Qt::green); - ui->yThermo->setFillBrush(Qt::magenta); +// ui->xThermo->setFillBrush(Qt::green); +// ui->yThermo->setFillBrush(Qt::magenta); #ifdef WIN32 while(true) { @@ -530,8 +530,8 @@ void MainWindow::dataSink(int k) if(m_xpol) t.sprintf(" Rx noise: %5.1f %5.1f %5.1f %% ",px,py,m_pctZap); if(!m_xpol) t.sprintf(" Rx noise: %5.1f %5.1f %% ",px,m_pctZap); lab4->setText(t); - ui->xThermo->setValue((double)px); //Update the bargraphs - ui->yThermo->setValue((double)py); +// ui->xThermo->setValue((double)px); //Update the bargraphs +// ui->yThermo->setValue((double)py); if(m_monitoring || m_diskData) { g_pWideGraph->dataSink2(s,nkhz,ihsym,m_diskData,lstrong); } @@ -1258,11 +1258,11 @@ void MainWindow::decode() //decode() QString hcall=(ui->dxCallEntry->text()+" ").mid(0,12); QString hgrid=(ui->dxGridEntry->text()+" ").mid(0,6); - strncpy(datcom_.mycall, mcall.toAscii(), 12); - strncpy(datcom_.mygrid, mgrid.toAscii(), 6); - strncpy(datcom_.hiscall, hcall.toAscii(), 12); - strncpy(datcom_.hisgrid, hgrid.toAscii(), 6); - strncpy(datcom_.datetime, m_dateTime.toAscii(), 20); + strncpy(datcom_.mycall, mcall.toLatin1(), 12); + strncpy(datcom_.mygrid, mgrid.toLatin1(), 6); + strncpy(datcom_.hiscall, hcall.toLatin1(), 12); + strncpy(datcom_.hisgrid, hgrid.toLatin1(), 6); + strncpy(datcom_.datetime, m_dateTime.toLatin1(), 20); //newdat=1 ==> this is new data, must do the big FFT //nagain=1 ==> decode only at fQSO +/- Tol @@ -1455,7 +1455,7 @@ void MainWindow::guiUpdate() f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append); QTextStream out(&f); out << QDateTime::currentDateTimeUtc().toString("yyyy-MMM-dd hh:mm") - << " Tx message: " << QString::fromAscii(msgsent) << endl; + << " Tx message: " << QString::fromLatin1(msgsent) << endl; f.close(); } @@ -1466,8 +1466,8 @@ void MainWindow::guiUpdate() if(iptt==1 && iptt0==0) nc1=-9; // TxDelay = 0.8 s if(nc1 <= 0) nc1++; if(nc1 == 0) { - ui->xThermo->setValue(0.0); //Set the Thermos to zero - ui->yThermo->setValue(0.0); +// ui->xThermo->setValue(0.0); //Set the Thermos to zero +// ui->yThermo->setValue(0.0); m_monitoring=false; soundInThread.setMonitoring(false); btxok=true; @@ -1478,7 +1478,7 @@ void MainWindow::guiUpdate() f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append); QTextStream out(&f); out << QDateTime::currentDateTimeUtc().toString("yyyy-MMM-dd hh:mm") - << " Tx message: " << QString::fromAscii(msgsent) << endl; + << " Tx message: " << QString::fromLatin1(msgsent) << endl; f.close(); } @@ -1579,8 +1579,8 @@ void MainWindow::guiUpdate() QString utc = " " + t.time().toString() + " "; ui->labUTC->setText(utc); if((!m_monitoring and !m_diskData) or (khsym==m_hsym0)) { - ui->xThermo->setValue(0.0); // Set Rx levels to 0 - ui->yThermo->setValue(0.0); +// ui->xThermo->setValue(0.0); // Set Rx levels to 0 +// ui->yThermo->setValue(0.0); lab4->setText(" Rx noise: 0.0 0.0 0.0% "); } m_hsym0=khsym; diff --git a/mainwindow.h b/mainwindow.h index fb6addcf8..0b2585dbb 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -1,6 +1,7 @@ #ifndef MAINWINDOW_H #define MAINWINDOW_H #include +#include #include #include #include @@ -10,6 +11,7 @@ #include "soundout.h" #include "commons.h" #include "sleep.h" +#include #define NFFT 32768 #define NSMAX 5760000 diff --git a/mainwindow.ui b/mainwindow.ui index b603c5e28..714a66d09 100644 --- a/mainwindow.ui +++ b/mainwindow.ui @@ -93,7 +93,7 @@ <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'Courier New'; font-size:10pt; font-weight:400; font-style:normal;"> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p></body></html> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p></body></html> false @@ -243,68 +243,6 @@ p, li { white-space: pre-wrap; } - - - - - 0 - 0 - - - - - 43 - 180 - - - - 1 - - - 60.000000000000000 - - - 0.000000000000000 - - - 8 - - - 0.000000000000000 - - - - - - - - 0 - 0 - - - - - 12 - 177 - - - - 1 - - - 60.000000000000000 - - - 0.000000000000000 - - - 8 - - - 0.000000000000000 - - - @@ -854,7 +792,7 @@ p, li { white-space: pre-wrap; } true - buttonGroup + buttonGroup @@ -882,7 +820,7 @@ p, li { white-space: pre-wrap; } - buttonGroup + buttonGroup @@ -910,7 +848,7 @@ p, li { white-space: pre-wrap; } - buttonGroup + buttonGroup @@ -938,7 +876,7 @@ p, li { white-space: pre-wrap; } - buttonGroup + buttonGroup @@ -966,7 +904,7 @@ p, li { white-space: pre-wrap; } - buttonGroup + buttonGroup @@ -994,7 +932,7 @@ p, li { white-space: pre-wrap; } - buttonGroup + buttonGroup @@ -1613,11 +1551,6 @@ p, li { white-space: pre-wrap; } QTextBrowser
displaytext.h
- - QwtThermo - QWidget -
qwt_thermo.h
-
diff --git a/map65.iss b/map65.iss index a695765f3..3347e92a5 100644 --- a/map65.iss +++ b/map65.iss @@ -1,7 +1,7 @@ [Setup] AppName=MAP65 -AppVerName=MAP65 Version 2.5 r3603 -AppCopyright=Copyright (C) 2001-2013 by Joe Taylor, K1JT +AppVerName=MAP65 Version 2.5 r3653 +AppCopyright=Copyright (C) 2001-2014 by Joe Taylor, K1JT DefaultDirName=c:\MAP65 DefaultGroupName=MAP65 @@ -17,7 +17,6 @@ Source: "c:\Users\joe\wsjt\map65_install\wisdom2.bat"; DestDir: "{app}"; Source: "c:\Users\joe\wsjt\map65_install\afmhot.dat"; DestDir: "{app}"; Source: "c:\Users\joe\wsjt\map65_install\blue.dat"; DestDir: "{app}"; Source: "c:\Users\joe\wsjt\map65_install\qthid.exe"; DestDir: "{app}"; - Source: "c:\Users\joe\wsjt\QtSupport\*.dll"; DestDir: "{sys}"; Flags: onlyifdoesntexist Source: "c:\Users\joe\wsjt\map65_install\save\dummy"; DestDir: "{app}\save"; diff --git a/map65.pro b/map65.pro index a1d54e88d..b597cb73b 100644 --- a/map65.pro +++ b/map65.pro @@ -5,12 +5,15 @@ #------------------------------------------------- QT += core gui network -CONFIG += qwt thread +greaterThan(QT_MAJOR_VERSION, 4): QT += widgets +#CONFIG += qwt thread +CONFIG += thread #CONFIG += console TARGET = map65 VERSION = 2.3.0 TEMPLATE = app +DEFINES = QT5 win32 { DEFINES = WIN32 @@ -47,8 +50,6 @@ HEADERS += mainwindow.h plotter.h soundin.h soundout.h \ bandmap.h commons.h sleep.h astro.h displaytext.h \ txtune.h -DEFINES += __cplusplus - FORMS += mainwindow.ui about.ui devsetup.ui widegraph.ui \ messages.ui bandmap.ui astro.ui \ txtune.ui @@ -63,16 +64,19 @@ LIBS += -lfftw3f -lportaudio -lgfortran } win32 { -INCLUDEPATH += c:/qwt-6.0.1/include +#INCLUDEPATH += c:/qwt-6.1.0/src LIBS += ../map65/libm65/libm65.a LIBS += ../map65/libfftw3f_win.a -LIBS += ../QtSupport/palir-02.dll +LIBS += /users/joe/wsjt/QtSupport/palir-02.dll LIBS += libwsock32 LIBS += C:/MinGW/lib/libf95.a CONFIG(release) { - LIBS += C:/qwt-6.0.1/lib/qwt.dll +# LIBS += C:/qwt-6.1.0/lib/qwt.dll } else { - LIBS += C:/qwt-6.0.1/lib/qwtd.dll +# LIBS += C:/qwt-6.1.0/lib/qwtd.dll } -LIBS += -lusb +#LIBS += -lusb +LIBS += /users/joe/linrad/3.37/libusb.a +LIBS += -lQt5Concurrent +#LIBS += c:\wsjt-env\Qt5\Tools\mingw48_32\i686-w64-mingw32\lib\libmingwex.a } diff --git a/set570.cpp b/set570.cpp index fef003c49..37c4fd7a3 100644 --- a/set570.cpp +++ b/set570.cpp @@ -17,7 +17,13 @@ #include /* String function definitions */ #include /* UNIX standard function definitions */ #include -#include + +#ifdef WIN32 +#include +#endif + +//#include +#include "/users/joe/linrad/3.37/usb.h" #include #define USB_SUCCESS 0 diff --git a/widegraph.h b/widegraph.h index 88c48e86f..c5862bdd6 100644 --- a/widegraph.h +++ b/widegraph.h @@ -1,5 +1,6 @@ #ifndef WIDEGRAPH_H #define WIDEGRAPH_H +#include #include namespace Ui {