##// END OF EJS Templates
python wrapper added to the API...
paul -
r46:54b149031754 default
parent child
Show More
@@ -88,7 +88,6 bool stardundeeSPW_USB::disconnectBridge
88 88 return false;
89 89 }
90 90
91
92 91 int stardundeeSPW_USB::pushRMAPPacket(char *packet, int size)
93 92 {
94 93 return this->manager->sendPacket(packet,size);
@@ -366,11 +365,12 void stardundeeSPW_USB::makeGUI(socexplo
366 365 connect(this,SIGNAL(SetBrickAsARouter(bool)), ((StarDundeeGUI*)this->p_GUI),SLOT(setBrickAsARouter(bool)));
367 366 connect(this,SIGNAL(BytesReceivedFromSpw(uint)), ((StarDundeeGUI*)this->p_GUI),SLOT(updateNbReceivedBytesFromSpw(uint)));
368 367 connect(this,SIGNAL(BytesTransmittedToSpw(uint)), ((StarDundeeGUI*)this->p_GUI),SLOT(updateNbTransmittedBytesToSpw(uint)));
369 connect(this, SIGNAL(CCSDSPacketTransmittedToSpw()),((StarDundeeGUI*)this->p_GUI),SLOT(updateCCSDSPacketTransmittedToSpw()));
368 connect(this,SIGNAL(CCSDSPacketTransmittedToSpw()), ((StarDundeeGUI*)this->p_GUI),SLOT(updateCCSDSPacketTransmittedToSpw()));
370 369 connect(this,SIGNAL(SetTimecodeFrequency(double)), ((StarDundeeGUI*)this->p_GUI),SLOT(setTimecodeFrequency(QString)));
371 370 connect(this,SIGNAL(StartSendingTimecodes(bool)), ((StarDundeeGUI*)this->p_GUI),SLOT(setStartSendingTimecodes(bool)));
372 371
373 connect(this,SIGNAL(GetLinkNumber()), this->manager, SLOT(getLinkNumber()));
372 connect(this,SIGNAL(SendOneTimecode(unsigned char)),this->manager, SLOT(sendOneTimecode(unsigned char)));
373 connect(this,SIGNAL(GetLinkNumber()), this->manager, SLOT(getLinkNumber()));
374 374 }
375 375
376 376 void stardundeeSPW_USB::sendPacketComingFromTCPServer(char *packet, int size)
@@ -1069,6 +1069,20 void stardundeeSPW_USB_Manager::setTimec
1069 1069 SocExplorerEngine::message(this->plugin,"tick frequency set to " + QString::number(currentFrequency) +" Hz");
1070 1070 }
1071 1071
1072 void stardundeeSPW_USB_Manager::sendOneTimecode( unsigned char nTimein )
1073 {
1074 // enable external timecode selection
1075 if(!USBSpaceWire_TC_EnableExternalTimecodeSelection(hDevice,1))
1076 SocExplorerEngine::message(this->plugin,"sendOneTimecode *** ERR *** enable external timecode selection");
1077
1078 if (!USBSpaceWire_TC_PerformTickIn( hDevice, nTimein) )
1079 SocExplorerEngine::message( this->plugin,"sendOneTimecode *** ERR *** Could not send the requested timecode: " + QString::number(nTimein) );
1080 else
1081 SocExplorerEngine::message( this->plugin,"sendOneTimecode *** OK *** timecode sent " + QString::number(nTimein) );
1082
1083 // disable external timecode selection
1084 if(!USBSpaceWire_TC_EnableExternalTimecodeSelection(hDevice,0))
1085 SocExplorerEngine::message(this->plugin,"sendOneTimecode *** ERR *** disable external timecode selection");
1086 }
1072 1087
1073 1088
1074
@@ -69,6 +69,7 signals:
69 69
70 70 public slots:
71 71 void sendTimecodePeriodically( bool onOff );
72 void sendOneTimecode(unsigned char nTimein);
72 73 int getLinkNumber( void );
73 74
74 75 private:
@@ -131,6 +132,7 signals:
131 132 void BytesTransmittedToSpw( unsigned int );
132 133 void CCSDSPacketTransmittedToSpw( void );
133 134 void StartSendingTimecodes( bool );
135 void SendOneTimecode( unsigned char );
134 136 int GetLinkNumber();
135 137
136 138 public slots:
@@ -119,6 +119,8 void spwplugin::bridgeSelectionChanged(c
119 119 ((stardundeeSPW_USB*)bridge),SIGNAL(StartSendingTimecodes(bool)));
120 120 connect(((spwPyWrapper*)this->pyObject),SIGNAL(StarDundeeSetTimecodeFrequency(double)),
121 121 ((stardundeeSPW_USB*)bridge),SIGNAL(SetTimecodeFrequency(double)));
122 connect(((spwPyWrapper*)this->pyObject),SIGNAL(StarDundeeSendOneTimecode(unsigned char)),
123 ((stardundeeSPW_USB*)bridge),SIGNAL(SendOneTimecode(unsigned char)));
122 124 connect(this->bridge,SIGNAL(pushPacketOverTCP(char*,int)),this->tcpServer,SLOT(pushPacket(char*,int)));
123 125 connect(this->tcpServer, SIGNAL(sendSPWPacket(char*,int)), ((stardundeeSPW_USB*)bridge), SLOT(sendPacketComingFromTCPServer(char*,int)));
124 126 }
@@ -26,6 +26,7 signals:
26 26 void StarDundeeSetBrickAsARouter( bool );
27 27 void StarDundeeSetTimecodeFrequency( double );
28 28 void StarDundeeStartTimecodes( bool );
29 void StarDundeeSendOneTimecode( unsigned char timecode );
29 30
30 31 void TCPServerConnect();
31 32 void TCPServerDisconnect();
General Comments 0
You need to be logged in to leave comments. Login now