| 1 | /**************************************************************************** |
|---|
| 2 | |
|---|
| 3 | Copyright 2007 Virginia Polytechnic Institute and State University |
|---|
| 4 | |
|---|
| 5 | This file is part of the OSSIE USRP_Commander. |
|---|
| 6 | |
|---|
| 7 | OSSIE USRP_Commander is free software; you can redistribute it and/or modify |
|---|
| 8 | it under the terms of the GNU General Public License as published by |
|---|
| 9 | the Free Software Foundation; either version 2 of the License, or |
|---|
| 10 | (at your option) any later version. |
|---|
| 11 | |
|---|
| 12 | OSSIE USRP_Commander is distributed in the hope that it will be useful, |
|---|
| 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 15 | GNU General Public License for more details. |
|---|
| 16 | |
|---|
| 17 | You should have received a copy of the GNU General Public License |
|---|
| 18 | along with OSSIE USRP_Commander; if not, write to the Free Software |
|---|
| 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|---|
| 20 | |
|---|
| 21 | ****************************************************************************/ |
|---|
| 22 | |
|---|
| 23 | |
|---|
| 24 | #ifndef USRP_COMMANDER_IMPL_H |
|---|
| 25 | #define USRP_COMMANDER_IMPL_H |
|---|
| 26 | |
|---|
| 27 | #include <stdlib.h> |
|---|
| 28 | #include "ossie/cf.h" |
|---|
| 29 | |
|---|
| 30 | |
|---|
| 31 | #include "ossie/PortTypes.h" |
|---|
| 32 | |
|---|
| 33 | #include "standardinterfaces/Radio_Control_u.h" |
|---|
| 34 | #include "standardinterfaces/Resource_u.h" |
|---|
| 35 | |
|---|
| 36 | #include "ossie/Resource_impl.h" |
|---|
| 37 | |
|---|
| 38 | class USRP_Commander_i : public virtual Resource_impl |
|---|
| 39 | { |
|---|
| 40 | public: |
|---|
| 41 | USRP_Commander_i(const char *uuid, omni_condition *sem); |
|---|
| 42 | |
|---|
| 43 | void start() throw (CF::Resource::StartError, CORBA::SystemException); |
|---|
| 44 | void stop() throw (CF::Resource::StopError, CORBA::SystemException); |
|---|
| 45 | |
|---|
| 46 | CORBA::Object_ptr getPort( const char* portName ) throw (CF::PortSupplier::UnknownPort, CORBA::SystemException); |
|---|
| 47 | |
|---|
| 48 | void releaseObject() throw (CF::LifeCycle::ReleaseError, CORBA::SystemException); |
|---|
| 49 | |
|---|
| 50 | void initialize() throw (CF::LifeCycle::InitializeError, CORBA::SystemException); |
|---|
| 51 | void configure(const CF::Properties&) throw (CORBA::SystemException, CF::PropertySet::InvalidConfiguration, CF::PropertySet::PartialConfiguration); |
|---|
| 52 | |
|---|
| 53 | |
|---|
| 54 | private: |
|---|
| 55 | USRP_Commander_i(); |
|---|
| 56 | USRP_Commander_i(USRP_Commander_i&); |
|---|
| 57 | |
|---|
| 58 | omni_condition *component_running; //for component shutdown |
|---|
| 59 | |
|---|
| 60 | omni_mutex accessPrivateData; |
|---|
| 61 | |
|---|
| 62 | short M; // Interpolation factor |
|---|
| 63 | float tx_freq; // Transmitter frequency |
|---|
| 64 | |
|---|
| 65 | //list components provides and uses ports |
|---|
| 66 | standardInterfaces_i::TX_Control_u *TXControl; |
|---|
| 67 | standardInterfaces_i::Resource_u *data_control; |
|---|
| 68 | |
|---|
| 69 | }; |
|---|
| 70 | #endif |
|---|