diff --git a/gse_lesia/gselesia.pro.user b/gse_lesia/gselesia.pro.user --- a/gse_lesia/gselesia.pro.user +++ b/gse_lesia/gselesia.pro.user @@ -1,6 +1,6 @@ - + ProjectExplorer.Project.ActiveTarget diff --git a/gse_lesia/mainwindow.cpp b/gse_lesia/mainwindow.cpp --- a/gse_lesia/mainwindow.cpp +++ b/gse_lesia/mainwindow.cpp @@ -547,7 +547,7 @@ void MainWindow::buildWFAndDisplay_CWF_F } } -void MainWindow::buildSpectrumAndDisplayNORM_F0(TMPacketToRead *packet, SpectraPacket *spectraPacket) +void MainWindow::build_ASM_AndDisplay_NORM_F0(TMPacketToRead *packet, SpectraPacket *spectraPacket) { unsigned int i; unsigned int j; @@ -705,7 +705,7 @@ void MainWindow::preProcessPacket(TMPack buildWFAndDisplay_CWF_F2(packet, wfPacketSBM2); break; case SID_NORMAL_ASM_F0: - buildSpectrumAndDisplayNORM_F0(packet, spectraPacketNormalSpectrumF0); + build_ASM_AndDisplay_NORM_F0(packet, spectraPacketNormalSpectrumF0); break; } } diff --git a/gse_lesia/mainwindow.h b/gse_lesia/mainwindow.h --- a/gse_lesia/mainwindow.h +++ b/gse_lesia/mainwindow.h @@ -42,7 +42,7 @@ public: void buildWFAndDisplayBurst(TMPacketToRead *packet, WFPacket *wfPacket); void buildWFAndDisplay_CWF_F1(TMPacketToRead *packet, WFPacket *wfPacket); void buildWFAndDisplay_CWF_F2(TMPacketToRead *packet, WFPacket *wfPacket); - void buildSpectrumAndDisplayNORM_F0(TMPacketToRead *packet, SpectraPacket *spectraPacket); + void build_ASM_AndDisplay_NORM_F0(TMPacketToRead *packet, SpectraPacket *spectraPacket); protected: void closeEvent(QCloseEvent *); diff --git a/parameterdump/Makefile b/parameterdump/Makefile --- a/parameterdump/Makefile +++ b/parameterdump/Makefile @@ -3,7 +3,7 @@ # Generated by qmake (3.0) (Qt 5.2.0) # Project: parameterdump.pro # Template: lib -# Command: /bin/qmake-qt5 -spec linux-g++-64 CONFIG+=debug CONFIG+=declarative_debug CONFIG+=qml_debug -o Makefile parameterdump.pro +# Command: /usr/bin/qmake-qt5 -o Makefile parameterdump.pro ############################################################################# MAKEFILE = Makefile @@ -12,16 +12,16 @@ MAKEFILE = Makefile CC = gcc CXX = g++ -DEFINES = -DPARAMETERDUMP_LIBRARY -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_PRINTSUPPORT_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -CFLAGS = -m64 -pipe -g -Wall -W -D_REENTRANT -fPIC $(DEFINES) -CXXFLAGS = -m64 -pipe -g -Wall -W -D_REENTRANT -fPIC $(DEFINES) +DEFINES = -DPARAMETERDUMP_LIBRARY -DQT_NO_DEBUG -DQT_PRINTSUPPORT_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB +CFLAGS = -m64 -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -O2 -Wall -W -D_REENTRANT -fPIC $(DEFINES) +CXXFLAGS = -m64 -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -O2 -Wall -W -D_REENTRANT -fPIC $(DEFINES) INCPATH = -I/usr/lib64/qt5/mkspecs/linux-g++-64 -I. -I../../DEV_PLE/header -I../rmapplugin -I. -I/usr/include/qt5 -I/usr/include/qt5/QtPrintSupport -I/usr/include/qt5/QtWidgets -I/usr/include/qt5/QtGui -I/usr/include/qt5/QtCore -I. LINK = g++ -LFLAGS = -m64 -shared -Wl,-soname,libparameterdump.so.1 +LFLAGS = -m64 -Wl,-O1 -Wl,-z,relro -shared -Wl,-soname,libparameterdump.so.1 LIBS = $(SUBLIBS) -L/usr/X11R6/lib64 -lQt5PrintSupport -lQt5Widgets -lQt5Gui -lQt5Core -lGL -lpthread AR = ar cqs RANLIB = -QMAKE = /bin/qmake-qt5 +QMAKE = /usr/bin/qmake-qt5 TAR = tar -cf COMPRESS = gzip -9f COPY = cp -f @@ -65,13 +65,12 @@ DIST = /usr/lib64/qt5/mkspecs/f /usr/lib64/qt5/mkspecs/common/g++-base.conf \ /usr/lib64/qt5/mkspecs/common/g++-unix.conf \ /usr/lib64/qt5/mkspecs/qconfig.pri \ - /usr/lib64/qt5/mkspecs/modules/qt_lib_accountsservice.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_clucene_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_compositor.pri \ + /usr/lib64/qt5/mkspecs/modules/qt_lib_compositor_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent_private.pri \ - /usr/lib64/qt5/mkspecs/modules/qt_lib_configuration.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_core.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_core_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_dbus.pri \ @@ -139,8 +138,6 @@ DIST = /usr/lib64/qt5/mkspecs/f /usr/lib64/qt5/mkspecs/features/default_pre.prf \ /usr/lib64/qt5/mkspecs/features/resolve_config.prf \ /usr/lib64/qt5/mkspecs/features/default_post.prf \ - /usr/lib64/qt5/mkspecs/features/qml_debug.prf \ - /usr/lib64/qt5/mkspecs/features/declarative_debug.prf \ /usr/lib64/qt5/mkspecs/features/unix/gdb_dwarf_index.prf \ /usr/lib64/qt5/mkspecs/features/warn_on.prf \ /usr/lib64/qt5/mkspecs/features/qt.prf \ @@ -195,7 +192,6 @@ all: Makefile $(TARGET) -ln -s $(TARGET) $(TARGET0) -ln -s $(TARGET) $(TARGET1) -ln -s $(TARGET) $(TARGET2) - { test -z "$(DESTDIR)" || cd "$(DESTDIR)"; } && test $$(gdb --version | sed -e 's,[^0-9][^0-9]*\([0-9]\)\.\([0-9]\).*,\1\2,;q') -gt 72 && gdb --nx --batch --quiet -ex 'set confirm off' -ex "save gdb-index ." -ex quit '$(TARGET)' && test -f $(TARGET).gdb-index && objcopy --add-section '.gdb_index=$(TARGET).gdb-index' --set-section-flags '.gdb_index=readonly' '$(TARGET)' '$(TARGET)' && rm -f $(TARGET).gdb-index || true @@ -214,13 +210,12 @@ Makefile: parameterdump.pro /usr/lib64/q /usr/lib64/qt5/mkspecs/common/g++-base.conf \ /usr/lib64/qt5/mkspecs/common/g++-unix.conf \ /usr/lib64/qt5/mkspecs/qconfig.pri \ - /usr/lib64/qt5/mkspecs/modules/qt_lib_accountsservice.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_clucene_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_compositor.pri \ + /usr/lib64/qt5/mkspecs/modules/qt_lib_compositor_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent_private.pri \ - /usr/lib64/qt5/mkspecs/modules/qt_lib_configuration.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_core.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_core_private.pri \ /usr/lib64/qt5/mkspecs/modules/qt_lib_dbus.pri \ @@ -288,8 +283,6 @@ Makefile: parameterdump.pro /usr/lib64/q /usr/lib64/qt5/mkspecs/features/default_pre.prf \ /usr/lib64/qt5/mkspecs/features/resolve_config.prf \ /usr/lib64/qt5/mkspecs/features/default_post.prf \ - /usr/lib64/qt5/mkspecs/features/qml_debug.prf \ - /usr/lib64/qt5/mkspecs/features/declarative_debug.prf \ /usr/lib64/qt5/mkspecs/features/unix/gdb_dwarf_index.prf \ /usr/lib64/qt5/mkspecs/features/warn_on.prf \ /usr/lib64/qt5/mkspecs/features/qt.prf \ @@ -307,7 +300,7 @@ Makefile: parameterdump.pro /usr/lib64/q /lib64/libQt5Widgets.prl \ /lib64/libQt5Gui.prl \ /lib64/libQt5Core.prl - $(QMAKE) -spec linux-g++-64 CONFIG+=debug CONFIG+=declarative_debug CONFIG+=qml_debug -o Makefile parameterdump.pro + $(QMAKE) -o Makefile parameterdump.pro /usr/lib64/qt5/mkspecs/features/spec_pre.prf: /usr/lib64/qt5/mkspecs/common/shell-unix.conf: /usr/lib64/qt5/mkspecs/common/unix.conf: @@ -317,13 +310,12 @@ Makefile: parameterdump.pro /usr/lib64/q /usr/lib64/qt5/mkspecs/common/g++-base.conf: /usr/lib64/qt5/mkspecs/common/g++-unix.conf: /usr/lib64/qt5/mkspecs/qconfig.pri: -/usr/lib64/qt5/mkspecs/modules/qt_lib_accountsservice.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_clucene_private.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_compositor.pri: +/usr/lib64/qt5/mkspecs/modules/qt_lib_compositor_private.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_concurrent_private.pri: -/usr/lib64/qt5/mkspecs/modules/qt_lib_configuration.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_core.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_core_private.pri: /usr/lib64/qt5/mkspecs/modules/qt_lib_dbus.pri: @@ -391,8 +383,6 @@ Makefile: parameterdump.pro /usr/lib64/q /usr/lib64/qt5/mkspecs/features/default_pre.prf: /usr/lib64/qt5/mkspecs/features/resolve_config.prf: /usr/lib64/qt5/mkspecs/features/default_post.prf: -/usr/lib64/qt5/mkspecs/features/qml_debug.prf: -/usr/lib64/qt5/mkspecs/features/declarative_debug.prf: /usr/lib64/qt5/mkspecs/features/unix/gdb_dwarf_index.prf: /usr/lib64/qt5/mkspecs/features/warn_on.prf: /usr/lib64/qt5/mkspecs/features/qt.prf: @@ -411,7 +401,7 @@ parameterdump.pro: /lib64/libQt5Gui.prl: /lib64/libQt5Core.prl: qmake: FORCE - @$(QMAKE) -spec linux-g++-64 CONFIG+=debug CONFIG+=declarative_debug CONFIG+=qml_debug -o Makefile parameterdump.pro + @$(QMAKE) -o Makefile parameterdump.pro qmake_all: FORCE @@ -576,6 +566,7 @@ moc_parameterdump.cpp: /usr/include/qt5/ /usr/include/qt5/QtCore/QObject \ ../../DEV_PLE/header/TC_types.h \ ../../DEV_PLE/header/ccsds_types.h \ + ../../DEV_PLE/header/fsw_params_processing.h \ parameterdump_global.h \ tcpackettosend.h \ parameterdump.h @@ -642,6 +633,7 @@ moc_tcpackettosend.cpp: /usr/include/qt5 parameterdump_global.h \ ../../DEV_PLE/header/TC_types.h \ ../../DEV_PLE/header/ccsds_types.h \ + ../../DEV_PLE/header/fsw_params_processing.h \ tcpackettosend.h /usr/lib64/qt5/bin/moc $(DEFINES) $(INCPATH) -I/usr/lib/gcc/include/c++/4.8.2 -I/usr/lib/gcc/include/c++/4.8.2/x86_64-redhat-linux -I/usr/lib/gcc/include/c++/4.8.2/backward -I/usr/lib/gcc/x86_64-redhat-linux/4.8.2/include -I/usr/local/include -I/usr/include tcpackettosend.h -o moc_tcpackettosend.cpp @@ -853,6 +845,7 @@ parameterdump.o: parameterdump.cpp param /usr/include/qt5/QtCore/QObject \ ../../DEV_PLE/header/TC_types.h \ ../../DEV_PLE/header/ccsds_types.h \ + ../../DEV_PLE/header/fsw_params_processing.h \ parameterdump_global.h \ tcpackettosend.h $(CXX) -c $(CXXFLAGS) $(INCPATH) -o parameterdump.o parameterdump.cpp @@ -918,7 +911,8 @@ tcpackettosend.o: tcpackettosend.cpp tcp /usr/include/qt5/QtCore/qobject_impl.h \ parameterdump_global.h \ ../../DEV_PLE/header/TC_types.h \ - ../../DEV_PLE/header/ccsds_types.h + ../../DEV_PLE/header/ccsds_types.h \ + ../../DEV_PLE/header/fsw_params_processing.h $(CXX) -c $(CXXFLAGS) $(INCPATH) -o tcpackettosend.o tcpackettosend.cpp tmpackettoread.o: ../rmapplugin/tmpackettoread.cpp ../rmapplugin/tmpackettoread.h \ @@ -1009,6 +1003,7 @@ uninstall_header: FORCE install_target: first FORCE @test -d $(INSTALL_ROOT)/usr/lib64 || mkdir -p $(INSTALL_ROOT)/usr/lib64 -$(INSTALL_PROGRAM) "$(TARGET)" "$(INSTALL_ROOT)/usr/lib64/$(TARGET)" + -$(STRIP) --strip-unneeded "$(INSTALL_ROOT)/usr/lib64/$(TARGET)" -$(SYMLINK) "$(TARGET)" "$(INSTALL_ROOT)/usr/lib64/$(TARGET0)" -$(SYMLINK) "$(TARGET)" "$(INSTALL_ROOT)/usr/lib64/$(TARGET1)" -$(SYMLINK) "$(TARGET)" "$(INSTALL_ROOT)/usr/lib64/$(TARGET2)" diff --git a/parameterdump/parameterdump.cpp b/parameterdump/parameterdump.cpp --- a/parameterdump/parameterdump.cpp +++ b/parameterdump/parameterdump.cpp @@ -310,7 +310,7 @@ void ParameterDump::sendParameterDump() packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_DUMP; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packetToSend->GetCRCAsTwoBytes((unsigned char*) &packet, crcAsTwoBytes, PACKET_LENGTH_TC_LFR_DUMP_PAR + CCSDS_TC_TM_PACKET_OFFSET - 2); @@ -336,7 +336,7 @@ void ParameterDump::sendLoadCommon() packet.ccsdsSecHeaderFlag_pusVersion_ack = TC_LFR_DATA_FIELD_HEADER0; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_LOAD_COMMON_PAR; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.spare = TC_LFR_LOAD_COMMON_PAR_SPARE; packet.bw_sp0_sp1_r0_r1 = (spinbox_sy_lfr_bw->value() << 4) + (spinbox_sy_lfr_sp0->value() << 3) @@ -368,7 +368,7 @@ void ParameterDump::sendLoadNormal() packet.ccsdsSecHeaderFlag_pusVersion_ack = TC_LFR_DATA_FIELD_HEADER0; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_LOAD_NORMAL_PAR; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.sy_lfr_n_swf_l[0] = (unsigned char) (spinbox_sy_lfr_n_swf_l->value() >> 8 ); packet.sy_lfr_n_swf_l[1] = (unsigned char) (spinbox_sy_lfr_n_swf_l->value() ); packet.sy_lfr_n_swf_p[0] = (unsigned char) (spinbox_sy_lfr_n_swf_p->value() >> 8 ); @@ -404,7 +404,7 @@ void ParameterDump::sendLoadBurst() packet.ccsdsSecHeaderFlag_pusVersion_ack = TC_LFR_DATA_FIELD_HEADER0; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_LOAD_BURST_PAR; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.sy_lfr_bp_p0 = (unsigned char) (spinbox_sy_lfr_b_bp_p0->value() ); packet.sy_lfr_bp_p1 = (unsigned char) (spinbox_sy_lfr_b_bp_p1->value() ); @@ -432,7 +432,7 @@ void ParameterDump::sendLoadSBM1() packet.ccsdsSecHeaderFlag_pusVersion_ack = TC_LFR_DATA_FIELD_HEADER0; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_LOAD_SBM1_PAR; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.sy_lfr_bp_p0 = (unsigned char) (spinbox_sy_lfr_s1_bp_p0->value() ); packet.sy_lfr_bp_p1 = (unsigned char) (spinbox_sy_lfr_s1_bp_p1->value() ); @@ -460,7 +460,7 @@ void ParameterDump::sendLoadSBM2() packet.ccsdsSecHeaderFlag_pusVersion_ack = TC_LFR_DATA_FIELD_HEADER0; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_LOAD_SBM2_PAR; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.sy_lfr_bp_p0 = (unsigned char) (spinbox_sy_lfr_s2_bp_p0->value() ); packet.sy_lfr_bp_p1 = (unsigned char) (spinbox_sy_lfr_s2_bp_p1->value() ); diff --git a/rmapplugin/entermode.cpp b/rmapplugin/entermode.cpp --- a/rmapplugin/entermode.cpp +++ b/rmapplugin/entermode.cpp @@ -87,7 +87,7 @@ void EnterMode::sendEnterMode( unsigned packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_ENTER_MODE; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.spare = 0x00; packet.mode = mode; packet.enterModeTime[0] = 0x00; @@ -146,7 +146,7 @@ void EnterMode::sendReset() packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_RESET; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; parameterDump->GetCRCAsTwoBytes((unsigned char*) &packet, crcAsTwoBytes, PACKET_LENGTH_TC_LFR_RESET + CCSDS_TC_TM_PACKET_OFFSET - 2); @@ -172,7 +172,7 @@ void EnterMode::sendUpdateInfo() packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_UPDATE_INFO; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; packet.set1 = 0x00; packet.set2 = 0x00; @@ -229,7 +229,7 @@ void EnterMode::sendEnableCalibration() packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_ENABLE_CALIBRATION; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; parameterDump->GetCRCAsTwoBytes((unsigned char*) &packet, crcAsTwoBytes, PACKET_LENGTH_TC_LFR_ENABLE_CALIBRATION + CCSDS_TC_TM_PACKET_OFFSET - 2); @@ -255,7 +255,7 @@ void EnterMode::sendDisableCalibration() packet.ccsdsSecHeaderFlag_pusVersion_ack = 0x19; packet.serviceType = TC_TYPE_DEFAULT; packet.serviceSubType = TC_SUBTYPE_DISABLE_CALIBRATION; - packet.sourceID = SID_TC_GROUND; + packet.sourceID = SID_TC_RPW_INTERNAL; parameterDump->GetCRCAsTwoBytes((unsigned char*) &packet, crcAsTwoBytes, PACKET_LENGTH_TC_LFR_DISABLE_CALIBRATION + CCSDS_TC_TM_PACKET_OFFSET - 2);