Description
Provides access to the properties and methods
defining a simple receiver model.
Object Model
Public Methods
Public Properties
Example
Compute a link budget
for a Transmtiter and Receiver pair, using simple models
[C#] |
Copy Code
|
IAgStkObject xmtrAsStkObject = geoTransmitter as IAgStkObject;
IAgStkObject rcvrAsStkObject = facilityReceiver as IAgStkObject;
geoTransmitter.SetModel("Simple Transmitter Model");
IAgTransmitterModelSimple simpleTrans = geoTransmitter.Model as IAgTransmitterModelSimple;
simpleTrans.Frequency = 3.2;
simpleTrans.Eirp = 60.0;
facilityReceiver.SetModel("Simple Receiver Model");
IAgReceiverModelSimple simpleRcvr = facilityReceiver.Model as IAgReceiverModelSimple;
simpleRcvr.GOverT = 60.0;
IAgStkAccess linkAccess = xmtrAsStkObject.GetAccessToObject(rcvrAsStkObject);
linkAccess.ComputeAccess();
IAgIntervalCollection accessIntervals = linkAccess.ComputedAccessIntervalTimes;
Array dataPrvElements = new object[] { "Time", "Eb/No", "BER" };
IAgDataPrvTimeVar dp = linkAccess.DataProviders["Link Information"] as IAgDataPrvTimeVar;
for (int index0 = 0; index0 < accessIntervals.Count; ++index0)
{
object startTime = null, stopTime = null;
accessIntervals.GetInterval(index0, out startTime, out stopTime);
IAgDrResult result = dp.ExecElements(startTime, stopTime, 60, ref dataPrvElements);
Array timeValues = result.DataSets[0].GetValues();
Array ebno = result.DataSets[1].GetValues();
Array ber = result.DataSets[2].GetValues();
for (int index1 = 0; index1 < timeValues.GetLength(0); ++index1)
{
string time = (string)timeValues.GetValue(index1);
double ebnoVal = (double)ebno.GetValue(index1);
double berVal = (double)ber.GetValue(index1);
Console.WriteLine("{0}: Eb/No={1} BER={2}", time, ebnoVal, berVal);
}
Console.WriteLine();
}
|
|
Compute a link budget
for a Transmtiter and Receiver pair, using simple models
[Visual Basic .NET] |
Copy Code
|
Dim xmtrAsStkObject As IAgStkObject = TryCast(geoTransmitter,
IAgStkObject)
Dim rcvrAsStkObject As IAgStkObject = TryCast(facilityReceiver,
IAgStkObject)
geoTransmitter.SetModel("Simple Transmitter
Model")
Dim simpleTrans As IAgTransmitterModelSimple =
TryCast(geoTransmitter.Model, IAgTransmitterModelSimple)
simpleTrans.Frequency = 3.2
simpleTrans.Eirp = 60
facilityReceiver.SetModel("Simple Receiver
Model")
Dim simpleRcvr As IAgReceiverModelSimple =
TryCast(facilityReceiver.Model, IAgReceiverModelSimple)
simpleRcvr.GOverT = 60
Dim linkAccess As IAgStkAccess =
xmtrAsStkObject.GetAccessToObject(rcvrAsStkObject)
linkAccess.ComputeAccess()
Dim accessIntervals As IAgIntervalCollection =
linkAccess.ComputedAccessIntervalTimes
#If Not CSToJava Then
Dim dataPrvElements As Array =
New Object() {"Time",
"Eb/No", "BER"}
#Else
#End If
Dim dp As
IAgDataPrvTimeVar = TryCast(linkAccess.DataProviders("Link Information"), IAgDataPrvTimeVar)
Dim index0 As Integer = 0
While index0 <>
Dim startTime
As Object
= Nothing, stopTime As Object =
Nothing
#If Not
CSToJava Then
accessIntervals.GetInterval(index0,
startTime, stopTime)
#Else
#End If
#If Not
CSToJava Then
Dim result
As IAgDrResult =
dp.ExecElements(startTime, stopTime, 60, dataPrvElements)
#Else
#End If
Dim timeValues
As Array
= result.DataSets(0).GetValues()
Dim ebno
As Array
= result.DataSets(1).GetValues()
Dim ber
As Array
= result.DataSets(2).GetValues()
Dim index1
As Integer = 0
While index1
<>
Dim time As
String =
DirectCast(timeValues.GetValue(index1), String)
Dim ebnoVal As
Double =
DirectCast(ebno.GetValue(index1), Double)
Dim berVal As
Double =
DirectCast(ber.GetValue(index1), Double)
Console.WriteLine("{0}:
Eb/No={1} BER={2}", time, ebnoVal, berVal)
System.Threading.Interlocked.Increment(index1)
End
While
Console.WriteLine()
System.Threading.Interlocked.Increment(index0)
End While
|
|
CoClasses that Implement
IAgReceiverModelSimple