|
|
#ifndef RMAPPLUGINPYTHONWRAPPER_H
|
|
|
#define RMAPPLUGINPYTHONWRAPPER_H
|
|
|
|
|
|
#include <QObject>
|
|
|
#include <genericPySysdriver.h>
|
|
|
#include <QList>
|
|
|
#include <QVariant>
|
|
|
#include <QTimer>
|
|
|
|
|
|
#include "rmapoperations.h"
|
|
|
#include "ccsds.h"
|
|
|
#include "tcpackettosend.h"
|
|
|
#include "tmpackettoread.h"
|
|
|
|
|
|
class rmappluginPythonWrapper : public genericPySysdriver
|
|
|
{
|
|
|
Q_OBJECT
|
|
|
public:
|
|
|
explicit rmappluginPythonWrapper(lppmonplugin *parent = 0);
|
|
|
|
|
|
QList<TMPacketToRead*> *ccsdsPacketStore;
|
|
|
void processPacketStore();
|
|
|
unsigned int storeCCSDSPacket(unsigned char *ccsdsPacket, unsigned int size);
|
|
|
|
|
|
QList<TCPacketToSend*> TCPacketStore;
|
|
|
QTimer *timer;
|
|
|
|
|
|
signals:
|
|
|
void ccsdsPacketIsAvailable(unsigned int size);
|
|
|
void wakeUpCallingThread();
|
|
|
unsigned int WriteSPWSig(char *Value, unsigned int count, char targetLogicalAddress, char userApplication);
|
|
|
//
|
|
|
void updateTargetLogicalAddress(unsigned char newAddress);
|
|
|
void updateSourceLogicalAddress(unsigned char newAddress);
|
|
|
void updateSpaceWireLinkNumber(unsigned char newAddress);
|
|
|
//
|
|
|
void activateTCLoopSig();
|
|
|
void processPacketStoreNowSig();
|
|
|
void sendMessage(QString message);
|
|
|
int fetchPacketSig();
|
|
|
void nbPacketHasChanged(int nb);
|
|
|
|
|
|
//*******************
|
|
|
// TIMECODE SIGNALS
|
|
|
void sig_sendOneTimecode();
|
|
|
void sig_sendTimecodePeriodically(unsigned char);
|
|
|
|
|
|
public slots:
|
|
|
QList<QVariant> ReadSPW(unsigned int size=0);
|
|
|
int fetchPacket() {return emit fetchPacketSig();}
|
|
|
void WriteSPW(QList<int> dataList);
|
|
|
void WriteSPWDelay(QList<int> dataList, unsigned int delay=0);
|
|
|
void processPacketStoreLater(unsigned int delay);
|
|
|
void sendProcessPacketStoreNowSig(){emit processPacketStoreNowSig();}
|
|
|
void sendTCLoop();
|
|
|
void sendTC();
|
|
|
void reEmitWriteSPWSig(char *Value, unsigned int count, char targetLogicalAddress, char userApplication)
|
|
|
{emit WriteSPWSig(Value, count, targetLogicalAddress, userApplication);}
|
|
|
//
|
|
|
void setValueTargetLogicalAddress(unsigned int address);
|
|
|
void setValueSourceLogicalAddress(unsigned int address);
|
|
|
void setValueSpaceWireLinkNumber(unsigned int linkNumber);
|
|
|
//
|
|
|
void ProcessPendingEvents();
|
|
|
void BlockAllSignals();
|
|
|
|
|
|
//*******************
|
|
|
// TIMECODE FUNCTIONS
|
|
|
void sendOneTimecode();
|
|
|
void sendTimecodePeriodically(unsigned int onOff);
|
|
|
|
|
|
};
|
|
|
|
|
|
#endif // RMAPPLUGINPYTHONWRAPPER_H
|
|
|
|