?? fso-antenna.h
字號:
// FSO-antenna.h @ RPI, David Partyka/* Ported from CMU/Monarch's code, nov'98 -Padma.omni-antenna.homni-directional antenna*/#ifndef ns_fsoantenna_h#define ns_fsoantenna_h#include <antenna.h> class FSOAntenna : public Antenna{ public: FSOAntenna(); int command(int argc, const char*const* argv); virtual FSOAntenna * copy() // return a pointer to a copy of this antenna that will return the // same thing for get{Rx,Tx}Gain that this one would at this point // in time. This is needed b/c if a pkt is sent with a directable // antenna, this antenna may be have been redirected by the time we // call getTxGain on the copy to determine if the pkt is received. { // since the Gt and Gr are constant w.r.t time, we can just return // this object itself return this; } virtual void release() // release a copy created by copy() above { // don't do anything } // LED get functions inline double getlambda() { return lambda; } inline double getTx_Power() { return Tx_Power; } //double getTx_Area() { return Tx_Area; } inline double getTx_Dia() { return Tx_Dia; } inline double getTx_Angle() { return Tx_Angle; } // Photodetector get functions inline double getRx_Sensitivity() { return Rx_Sensitivity; } //double getRx_Area() { return Rx_Area; } inline double getRx_Dia() { return Rx_Dia; } inline double getRx_Angle() { return Rx_Angle; } inline double getX() { return X_; } inline double getY() { return Y_; } inline double getZ() { return Z_; } inline double getXNormal() { return N_X; } inline double getYNormal() { return N_Y; } inline double getZNormal() { return N_Z; } inline void set_normal(double x, double y, double z) { N_X = x; N_Y = y; N_Z = z; } inline void set_position(double x, double y, double z) { X_ = x; Y_ = y; Z_ = z; } private: // LED specific parameters double lambda; double Tx_Power; double Tx_Dia; double Tx_Angle; // Photodector specific parameters double Rx_Sensitivity; double Rx_Dia; double Rx_Angle; // Normal Vector double N_X; double N_Y; double N_Z; protected: double Gt_; // gain of transmitter (db) double Gr_; // gain of receiver (db) }; #endif // ns_fsoantenna_h
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -