aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/rrlp/RRLP-Components.asn
blob: e9c9132473b72fd29fba328a553dcfe5771a7539 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
-- RRLP-Components.asn
-- $Id$
-- Taken from 3GPP TS 44.031  V9.2.0 (2010-03)
-- http://www.3gpp.org/ftp/Specs/archive/44_series/44.031/44031-920.zip/44031-920.doc
--
-- 4 Components
-- 5 Elements of Components
--

RRLP-Components
-- { RRLP-Components }

DEFINITIONS AUTOMATIC TAGS ::=

BEGIN

IMPORTS
	Ext-GeographicalInformation, VelocityEstimate
FROM
	MAP-LCS-DataTypes {
	ccitt identified-organization (4) etsi (0) mobileDomain (0)
	gsm-Network (1) modules (3) map-LCS-DataTypes (25) version5 (5)}

	ExtensionContainer
FROM MAP-ExtensionDataTypes {
	ccitt identified-organization (4) etsi (0) mobileDomain (0)
	gsm-Network (1) modules (3) map-ExtensionDataTypes (21) version4 (4)}
;

-- Add here other ASN.1 definitions presented below
-- in chapters 4 and 5.

-- Measurement Position request component
MsrPosition-Req ::= SEQUENCE {
	positionInstruct		PositionInstruct,
	referenceAssistData		ReferenceAssistData		OPTIONAL,
	msrAssistData			MsrAssistData			OPTIONAL,
	systemInfoAssistData	SystemInfoAssistData	OPTIONAL,
	gps-AssistData			GPS-AssistData			OPTIONAL,
	extensionContainer		ExtensionContainer		OPTIONAL,
	...,
	-- Release 98 extension element
rel98-MsrPosition-Req-extension			Rel98-MsrPosition-Req-Extension			OPTIONAL,	
	-- Release 5 extension element
rel5-MsrPosition-Req-extension			Rel5-MsrPosition-Req-Extension			OPTIONAL,
	-- Release 7 extension element
rel7-MsrPosition-Req-extension			Rel7-MsrPosition-Req-Extension			OPTIONAL
}



-- Measurement Position response component
MsrPosition-Rsp ::= SEQUENCE {
	multipleSets			MultipleSets			OPTIONAL,
	referenceIdentity		ReferenceIdentity		OPTIONAL,
	otd-MeasureInfo			OTD-MeasureInfo			OPTIONAL,
	locationInfo			LocationInfo			OPTIONAL,
	gps-MeasureInfo			GPS-MeasureInfo			OPTIONAL,
	locationError			LocationError			OPTIONAL,
	extensionContainer		ExtensionContainer		OPTIONAL,
	...,	
	-- Release extension here
	rel-98-MsrPosition-Rsp-Extension		
							Rel-98-MsrPosition-Rsp-Extension		OPTIONAL,
	rel-5-MsrPosition-Rsp-Extension
							Rel-5-MsrPosition-Rsp-Extension		OPTIONAL,
	-- When RRLP pseudo-segmentation is used, rel-5-MsrPosition-Rsp-Extension 
	-- and other possible future extensions should be the ones included in 
	-- the 2nd MsrPosition-Rsp component.
	rel-7-MsrPosition-Rsp-Extension
							Rel-7-MsrPosition-Rsp-Extension		OPTIONAL
}


-- Assistance Data component
AssistanceData ::= SEQUENCE {
	referenceAssistData	ReferenceAssistData			OPTIONAL,
	msrAssistData			MsrAssistData			OPTIONAL,
	systemInfoAssistData	SystemInfoAssistData	OPTIONAL,
	gps-AssistData			GPS-AssistData			OPTIONAL,	
	moreAssDataToBeSent		MoreAssDataToBeSent		OPTIONAL,	-- If not present, interpret as only
																-- Assistance Data component used to
																-- deliver entire set of assistance
																-- data.
	extensionContainer		ExtensionContainer		OPTIONAL,
	...,
	-- Release extension here
	rel98-AssistanceData-Extension	Rel98-AssistanceData-Extension	OPTIONAL,
	rel5-AssistanceData-Extension	Rel5-AssistanceData-Extension	OPTIONAL,
 rel7-AssistanceData-Extension Rel7-AssistanceData-Extension OPTIONAL	
}


-- Protocol Error component
ProtocolError ::= SEQUENCE {
	errorCause				ErrorCodes,	
	extensionContainer		ExtensionContainer		OPTIONAL,
	...,
	-- Release extensions here
	rel-5-ProtocolError-Extension Rel-5-ProtocolError-Extension		OPTIONAL
}


-- Positioning Capability request component
PosCapability-Req ::= SEQUENCE {
	extended-reference			Extended-reference,
	gANSSPositionMethods		GANSSPositionMethods	OPTIONAL,
	extensionContainer			ExtensionContainer		OPTIONAL,
	...
}


-- Positioning Capability response component
PosCapability-Rsp ::= SEQUENCE {
	extended-reference		Extended-reference,
	posCapabilities			PosCapabilities,

-- assistanceSupported shall be included if and only if any of the assistance data is supported
	assistanceSupported		AssistanceSupported		OPTIONAL,
	assistanceNeeded		AssistanceNeeded		OPTIONAL,
	extensionContainer		ExtensionContainer		OPTIONAL,
	...
}


-- add these defintions to RRLP-Components module
-- Position instructions
PositionInstruct ::= SEQUENCE {
	-- Method type
	methodType				MethodType,	
	positionMethod			PositionMethod,
	measureResponseTime		MeasureResponseTime,		
	useMultipleSets			UseMultipleSets,		
	environmentCharacter	EnvironmentCharacter	OPTIONAL	
}

--
MethodType ::= CHOICE {
	msAssisted		AccuracyOpt,	-- accuracy is optional
	msBased			Accuracy,		-- accuracy is mandatory
	msBasedPref		Accuracy,		-- accuracy is mandatory
	msAssistedPref	Accuracy 		-- accuracy is mandatory
}

-- Accuracy of the location estimation
AccuracyOpt ::= SEQUENCE {
	accuracy		Accuracy	OPTIONAL
}


-- The values of this field are defined in 3GPP TS 23.032 (Uncertainty code)
Accuracy ::= INTEGER (0..127)

-- Position Method
PositionMethod ::= ENUMERATED {
	eotd (0),
	gps (1),
	gpsOrEOTD (2)
}

-- Measurement request response time
MeasureResponseTime ::= INTEGER (0..7)

-- useMultiple Sets, FFS!
UseMultipleSets ::= ENUMERATED {
	multipleSets (0),		-- multiple sets are allowed
	oneSet (1)				-- sending of multiple is not allowed
}

-- Environment characterization
EnvironmentCharacter ::= ENUMERATED {
	badArea (0),		-- bad urban or suburban, heavy multipath and NLOS
	notBadArea (1),		-- light multipath and NLOS
	mixedArea (2),		-- not defined or mixed environment
	...
}

-- E-OTD reference BTS for Assitance data IE
ReferenceAssistData ::= SEQUENCE {
	bcchCarrier		BCCHCarrier,						-- BCCH carrier
	bsic			BSIC,								-- BSIC
	timeSlotScheme	TimeSlotScheme, 					-- Timeslot scheme
	btsPosition		BTSPosition			OPTIONAL
}

-- ellipsoid point and
-- ellipsoid point with altitude and uncertainty ellipsoid shapes are supported
BTSPosition ::= Ext-GeographicalInformation

-- RF channel number of BCCH
BCCHCarrier ::= INTEGER (0..1023)

-- Base station Identity Code
BSIC ::= INTEGER (0..63)

-- Timeslot scheme
TimeSlotScheme ::= ENUMERATED {
	equalLength (0),
	variousLength (1)
}

-- Time slot (modulo)
ModuloTimeSlot ::= INTEGER (0..3)

-- E-OTD measurement assistance data IE
-- The total number of neighbors in this element (MsrAssistData)
-- and in SystemInfoAssistData element (presented neighbors
-- can be at a maximum 15!)
MsrAssistData ::= SEQUENCE {
	 msrAssistList SeqOfMsrAssistBTS
}
SeqOfMsrAssistBTS ::= SEQUENCE (SIZE(1..15)) OF MsrAssistBTS

MsrAssistBTS ::= SEQUENCE {
	bcchCarrier			BCCHCarrier,		-- BCCH carrier
	bsic				BSIC,				-- BSIC
	multiFrameOffset	MultiFrameOffset, 	-- multiframe offset
	timeSlotScheme		TimeSlotScheme,		-- Timeslot scheme
	roughRTD			RoughRTD,			-- rough RTD value

	-- Location Calculation Assistance data is moved here
	calcAssistanceBTS	CalcAssistanceBTS	OPTIONAL
}

-- Multiframe offset
MultiFrameOffset ::= INTEGER (0..51)
-- The Multiframe Offset value 51 shall not be encoded by the transmitting entity and
-- shall be treated by the receiving entity as 0.

-- Rough RTD value between one base station and reference BTS
RoughRTD ::= INTEGER (0..1250)
-- The RoughRTD value 1250 shall not be encoded by the transmitting entity and shall
-- be treated by the receiving entity as 0.

-- E-OTD Measurement assistance data for system information List IE
-- The total number of base stations in this element (SystemInfoAssistData
-- presented neighbors) and in MsrAssistData element can be at a maximum 15.
SystemInfoAssistData ::= SEQUENCE {
	systemInfoAssistList 	SeqOfSystemInfoAssistBTS
}
SeqOfSystemInfoAssistBTS::= SEQUENCE (SIZE(1..32)) OF SystemInfoAssistBTS

-- whether n.th is present or not ?
SystemInfoAssistBTS ::= CHOICE {
	notPresent		NULL,
	present			AssistBTSData
}

-- Actual assistance data for system information base station
AssistBTSData ::= SEQUENCE {
	bsic				BSIC,				-- BSIC
	multiFrameOffset	MultiFrameOffset,	-- multiframe offset
	timeSlotScheme		TimeSlotScheme,		-- Timeslot scheme
	roughRTD			RoughRTD,			-- rough RTD value

	-- Location Calculation Assistance data
	calcAssistanceBTS	CalcAssistanceBTS	OPTIONAL
}

-- E-OTD Location calculation assistance data,
-- CalcAssistanceBTS element is optional not subfields
CalcAssistanceBTS ::= SEQUENCE {
	fineRTD				FineRTD,		-- fine RTD value between base stations
	referenceWGS84		ReferenceWGS84	-- reference coordinates
}

-- Coordinates of neighbour BTS, WGS-84 ellipsoid
ReferenceWGS84 ::= SEQUENCE {
	relativeNorth	RelDistance,				-- relative distance (south negative)
	relativeEast	RelDistance,				-- relative distance (west negative)
	-- Relative Altitude is not always known
	relativeAlt		RelativeAlt		OPTIONAL	-- relative altitude
}

-- Fine RTD value between this BTS and the reference BTS	
FineRTD ::= INTEGER (0..255)

-- Relative north/east distance
RelDistance ::= INTEGER (-200000..200000)

-- Relative altitude
RelativeAlt ::= INTEGER (-4000..4000)

-- Measure position response IEs
-- Reference Identity
-- Multiple sets
MultipleSets ::= SEQUENCE {
	-- number of reference sets
	nbrOfSets			INTEGER (2..3),		

	-- This field actually tells the number of reference BTSs
	nbrOfReferenceBTSs	INTEGER (1..3),

	-- This field is conditional and included optionally only if
	-- nbrOfSets is 3 and number of reference BTSs is 2.
	referenceRelation		ReferenceRelation		OPTIONAL
}

-- Relation between refence BTSs and sets
ReferenceRelation ::= ENUMERATED {
	secondBTSThirdSet (0),	-- 1st BTS related to 1st and 2nd sets
	secondBTSSecondSet (1),	-- 1st BTS related to 1st and 3rd sets
	firstBTSFirstSet (2)	-- 1st BTS related to 1st set
}

-- Reference BTS Identity, this element contains number of
-- BTSs told nbrOfReferenceBTSs field in Multiple sets element)
ReferenceIdentity ::= SEQUENCE {
	-- Reference BTS list
	refBTSList		SeqOfReferenceIdentityType
}
SeqOfReferenceIdentityType ::= SEQUENCE (SIZE(1..3)) OF ReferenceIdentityType

-- Cell identity
ReferenceIdentityType ::= CHOICE {
	bsicAndCarrier	BSICAndCarrier,		-- BSIC and Carrier
	ci				CellID,				-- Cell ID, LAC not needed
	requestIndex	RequestIndex,		-- Index to Requested Neighbor List
	systemInfoIndex	SystemInfoIndex,	-- Index to System info list, this type of ref. identity
										-- shall not be used by the MS unless it has received
										-- the SystemInfoAssistData from the SMLC for this cell.
	ciAndLAC		CellIDAndLAC		-- CI and LAC
}

BSICAndCarrier ::= SEQUENCE {
	carrier	BCCHCarrier,
	bsic		BSIC
}

RequestIndex ::= INTEGER (1..16)

SystemInfoIndex ::= INTEGER (1..32)

CellIDAndLAC ::= SEQUENCE {
	referenceLAC	LAC,				-- Location area code
	referenceCI		CellID				-- Cell identity
}
CellID ::= INTEGER (0..65535)
LAC ::= INTEGER (0..65535)

-- OTD-MeasureInfo
OTD-MeasureInfo ::= SEQUENCE {
	-- Measurement info elements, OTD-MsrElement is repeated number of times
	-- told in nbrOfReferenceBTSs in MultipleSets, default value is 1
	otdMsrFirstSets		OTD-MsrElementFirst,

	-- if more than one sets are present this element is repeated
	-- NumberOfSets - 1 (-1 = first set)
	otdMsrRestSets		SeqOfOTD-MsrElementRest		OPTIONAL
}

SeqOfOTD-MsrElementRest ::= SEQUENCE (SIZE(1..2)) OF OTD-MsrElementRest

-- OTD measurent information for 1 set
OTD-MsrElementFirst ::= SEQUENCE {
	refFrameNumber			INTEGER (0..42431), 				-- Frame number modulo 42432
	referenceTimeSlot		ModuloTimeSlot,
	toaMeasurementsOfRef	TOA-MeasurementsOfRef	OPTIONAL,
	stdResolution			StdResolution,
	taCorrection			INTEGER (0..960)		OPTIONAL,	-- TA correction

	-- measured neighbors in OTD measurements
	otd-FirstSetMsrs 		SeqOfOTD-FirstSetMsrs 	OPTIONAL
}
SeqOfOTD-FirstSetMsrs ::= SEQUENCE (SIZE(1..10)) OF OTD-FirstSetMsrs

-- OTD measurent information 2 and 3 sets if exist
OTD-MsrElementRest ::= SEQUENCE {
	refFrameNumber			INTEGER (0..42431), 					-- Frame number modulo 42432
	referenceTimeSlot		ModuloTimeSlot,
	toaMeasurementsOfRef	TOA-MeasurementsOfRef		OPTIONAL,
	stdResolution			StdResolution,
	taCorrection			INTEGER (0..960)			OPTIONAL,	-- TA correction

	-- measured neighbors in OTD measurements
	otd-MsrsOfOtherSets 	SeqOfOTD-MsrsOfOtherSets	OPTIONAL
}
SeqOfOTD-MsrsOfOtherSets ::= SEQUENCE (SIZE(1..10)) OF OTD-MsrsOfOtherSets

-- Standard deviation of the TOA measurements from the reference BTS
TOA-MeasurementsOfRef ::= SEQUENCE {
	refQuality			RefQuality,
	numOfMeasurements	NumOfMeasurements
}

RefQuality ::= INTEGER (0..31)			-- St Dev of TOA of reference as defined in annex
NumOfMeasurements ::= INTEGER (0..7)	-- No. of measurements for RefQuality as defined in annex
StdResolution ::= INTEGER (0..3)		-- Values of resolution are defined in annex

OTD-FirstSetMsrs ::= OTD-MeasurementWithID

-- Neighbour info in OTD measurements 0-10 times in TD measurement info
OTD-MsrsOfOtherSets ::= CHOICE {
	identityNotPresent	OTD-Measurement,	
	identityPresent		OTD-MeasurementWithID
}

-- For this OTD measurement identity is same as the identity of BTS
-- in the first set with same sequence number
OTD-Measurement ::= SEQUENCE {
	nborTimeSlot	ModuloTimeSlot,
	eotdQuality		EOTDQuality,
	otdValue		OTDValue
}

-- This measurement contains the BTS identity and measurement
OTD-MeasurementWithID ::=SEQUENCE {
	neighborIdentity	NeighborIdentity,
	nborTimeSlot		ModuloTimeSlot,
	eotdQuality			EOTDQuality,
	otdValue			OTDValue
}

EOTDQuality ::= SEQUENCE {
	nbrOfMeasurements	INTEGER	(0..7),
	stdOfEOTD			INTEGER (0..31)
}

NeighborIdentity ::= CHOICE {
	bsicAndCarrier		BSICAndCarrier,		-- BSIC and Carrier
	ci					CellID,				-- Cell ID, LAC not needed
	multiFrameCarrier	MultiFrameCarrier, 	-- MultiFrameOffest and BSIC
	requestIndex		RequestIndex,		-- Index to Requested Neighbor List
	systemInfoIndex		SystemInfoIndex,	-- Index to System info list, this type of neighbour
											-- identity shall not be used by the MS unless it has
											-- received the SystemInfoAssistData from the SMLC for
											-- this cell.
	ciAndLAC			CellIDAndLAC		-- CI and LAC
}

-- Multiframe and carrier
MultiFrameCarrier ::= SEQUENCE {
	bcchCarrier			BCCHCarrier,
	multiFrameOffset	MultiFrameOffset
}

-- OTD measurement value for neighbour
OTDValue ::= INTEGER (0..39999)

-- Location information IE
LocationInfo ::= SEQUENCE {
	refFrame		INTEGER (0..65535),			-- Reference Frame number
	-- If refFrame is within (42432..65535), it shall be ignored by the receiver
	-- in that case the MS should provide GPS TOW if available
	gpsTOW			INTEGER (0..14399999)	OPTIONAL,	-- GPS TOW
	fixType			FixType,
	-- Note that applicable range for refFrame is 0 - 42431
	-- Possible shapes carried in posEstimate are
	-- ellipsoid point,
	-- ellipsoid point with uncertainty circle
	-- ellipsoid point with uncertainty ellipse
	-- ellipsoid point with altitude and uncertainty ellipsoid
	posEstimate		Ext-GeographicalInformation
}

FixType ::= INTEGER {
	twoDFix (0),
	threeDFix (1)
} (0..1)

-- GPS-Measurement information
GPS-MeasureInfo ::= SEQUENCE {
	-- Measurement info elements
	-- user has to make sure that in this element is number of elements
	-- defined in reference BTS identity
	gpsMsrSetList	SeqOfGPS-MsrSetElement	
}
SeqOfGPS-MsrSetElement ::= SEQUENCE (SIZE(1..3)) OF GPS-MsrSetElement

-- OTD measurent information 1-3 times in message
GPS-MsrSetElement ::= SEQUENCE {
	refFrame		INTEGER (0..65535)	OPTIONAL, 	-- Reference Frame number
	gpsTOW			GPSTOW24b,						-- GPS TOW
	-- Note that applicable range for refFrame is 0 - 42431

--N_SAT can be read from number of elements of gps-msrList

	gps-msrList		SeqOfGPS-MsrElement
}

-- 24 bit presentation for GPSTOW
GPSTOW24b ::= INTEGER (0..14399999)

-- measured elements in measurement parameters field
SeqOfGPS-MsrElement ::= SEQUENCE (SIZE(1..16)) OF GPS-MsrElement

GPS-MsrElement ::= SEQUENCE {
	satelliteID		SatelliteID,				-- Satellite identifier
	cNo				INTEGER (0..63),			-- carrier noise ratio
	doppler			INTEGER (-32768..32767), 	-- doppler, mulltiply by 0.2
	wholeChips		INTEGER (0..1022),			-- whole value of the code phase measurement
	fracChips		INTEGER (0..1024),			-- fractional value of the code phase measurement
											-- a value of 1024 shall not be encoded by the sender
											-- the receiver shall consider a value of 1024 to be
											-- invalid data
	mpathIndic		MpathIndic,					-- multipath indicator
	pseuRangeRMSErr	INTEGER (0..63)				-- index		
}

-- Multipath indicator
MpathIndic ::= ENUMERATED {
	notMeasured (0),
	low (1),
	medium (2),
	high (3)
}

-- Location error IE
LocationError ::= SEQUENCE {
	locErrorReason				LocErrorReason,
	additionalAssistanceData	AdditionalAssistanceData	OPTIONAL,
	...
}

LocErrorReason ::= ENUMERATED {
	unDefined (0),	
	notEnoughBTSs (1),
	notEnoughSats (2),
	eotdLocCalAssDataMissing (3),
	eotdAssDataMissing (4),
	gpsLocCalAssDataMissing (5),
	gpsAssDataMissing (6),
	methodNotSupported (7),
	notProcessed (8),
	refBTSForGPSNotServingBTS (9),
	refBTSForEOTDNotServingBTS (10),
	...,
	notEnoughGANSSSats (11),	
 ganssAssDataMissing (12),
	refBTSForGANSSNotServingBTS (13)
}

-- exception handling:
-- an unrecognized value shall be treated the same as value 0


-- defines additional assistance data needed for any new location attempt
-- MS shall retain any assistance data already received
AdditionalAssistanceData ::= SEQUENCE {
	gpsAssistanceData		GPSAssistanceData		OPTIONAL,
	extensionContainer		ExtensionContainer		OPTIONAL,
	...,
	ganssAssistanceData GANSSAssistanceData OPTIONAL
}


GPSAssistanceData ::= OCTET STRING (SIZE (1..maxGPSAssistanceData))
-- GPSAssistanceData has identical structure and encoding to octets 3 to n of the
-- GPS Assistance Data IE in 3GPP TS 49.031

maxGPSAssistanceData	INTEGER ::= 40

GANSSAssistanceData ::= OCTET STRING (SIZE (1..maxGANSSAssistanceData))
-- GANSSAssistanceData has identical structure and encoding to octets 3 to n of the
-- GANSS Assistance Data IE in 3GPP TS 49.031

maxGANSSAssistanceData	INTEGER ::= 40

-- Protocol Error Causes
ErrorCodes ::= ENUMERATED {
	unDefined (0),
missingComponet (1),			
incorrectData (2),			
missingIEorComponentElement (3),		
messageTooShort (4),			
unknowReferenceNumber (5),		
...
}

-- exception handling:
-- an unrecognized value shall be treated the same as value 0

-- GPS assistance data IE
GPS-AssistData ::= SEQUENCE {
	controlHeader		ControlHeader
}

-- More Assistance Data To Be Sent IE
-- More Assistance Data Components On the Way indication for delivery of an entire set of assistance
-- data in multiple Assistance Data components.

MoreAssDataToBeSent ::= ENUMERATED {
	noMoreMessages (0),			-- This is the only or last Assistance Data message used to deliver
								-- the entire set of assistance data.
	moreMessagesOnTheWay (1)	-- The SMLC will send more Assistance Data messages or a final RRLP
								-- Measure Position Request message to deliver the
								-- the entire set of assistance data.
}

-- Control header of the GPS assistance data
ControlHeader ::= SEQUENCE {

	-- Field type Present information
	referenceTime		ReferenceTime		OPTIONAL,
	refLocation			RefLocation			OPTIONAL,
	dgpsCorrections		DGPSCorrections		OPTIONAL,
	navigationModel		NavigationModel		OPTIONAL,
	ionosphericModel	IonosphericModel	OPTIONAL,
	utcModel			UTCModel			OPTIONAL,
	almanac				Almanac				OPTIONAL,
	acquisAssist		AcquisAssist		OPTIONAL,
	realTimeIntegrity SeqOf-BadSatelliteSet OPTIONAL
}

ReferenceTime ::= SEQUENCE {
	gpsTime				GPSTime,
	gsmTime				GSMTime				OPTIONAL,
	gpsTowAssist		GPSTOWAssist		OPTIONAL
}

-- GPS Time includes week number and time-of-week (TOW)
GPSTime ::= SEQUENCE {
	gpsTOW23b			GPSTOW23b,
	gpsWeek				GPSWeek
}

-- GPSTOW, range 0-604799.92, resolution 0.08 sec, 23-bit presentation
GPSTOW23b ::= INTEGER (0..7559999)

-- GPS week number
GPSWeek ::= INTEGER (0..1023)

-- GPSTOWAssist consists of TLM message, Anti-spoof flag, Alert flag, and 2 reserved bits in TLM Word
-- for each visible satellite.
-- N_SAT can be read from number of elements in GPSTOWAssist
GPSTOWAssist ::= SEQUENCE (SIZE(1..12)) OF GPSTOWAssistElement

GPSTOWAssistElement ::= SEQUENCE {
	satelliteID			SatelliteID,
	tlmWord				TLMWord,
	antiSpoof			AntiSpoofFlag,
	alert				AlertFlag,
	tlmRsvdBits			TLMReservedBits
}

-- TLM Word, 14 bits
TLMWord ::= INTEGER (0..16383)

-- Anti-Spoof flag
AntiSpoofFlag ::= INTEGER (0..1)

-- Alert flag
AlertFlag ::= INTEGER (0..1)

-- Reserved bits in TLM word, MSB occurs earlier in TLM Word transmitted by satellite
TLMReservedBits ::= INTEGER (0..3)

GSMTime ::= SEQUENCE {
	bcchCarrier		BCCHCarrier,	-- BCCH carrier
	bsic			BSIC,			-- BSIC
	frameNumber		FrameNumber,
	timeSlot		TimeSlot,
	bitNumber		BitNumber
}

-- Frame number
FrameNumber ::= INTEGER (0..2097151)

-- Time slot number
TimeSlot ::= INTEGER (0..7)

-- Bit number
BitNumber ::= INTEGER (0..156)


-- Reference Location IE
RefLocation ::= SEQUENCE {
	threeDLocation			Ext-GeographicalInformation
}

-- DGPS Corrections IE
DGPSCorrections ::= SEQUENCE {

	gpsTOW		INTEGER (0..604799),	-- DGPS reference time
	status		INTEGER (0..7),
	-- N_SAT can be read from number of elements of satList
	satList		SeqOfSatElement 	
}
SeqOfSatElement ::= SEQUENCE (SIZE (1..16)) OF SatElement

-- number of correction for satellites
SatElement ::= SEQUENCE {
	satelliteID		SatelliteID,

--- Sequence number for ephemeris
	iode 			INTEGER (0..239),
	-- User Differential Range Error
	udre			INTEGER (0..3),		

	-- Pseudo Range Correction, range is
	-- -655.04 - +655.04,
	pseudoRangeCor	INTEGER (-2047..2047), 	

	-- Pseudo Range Rate Correction, range is
	-- -4.064 - +4.064,
	rangeRateCor	INTEGER (-127..127),

-- Delta Pseudo Range Correction 2 	
	deltaPseudoRangeCor2 	INTEGER (-127..127),	-- This IE shall be ignored by the receiver and
													-- set to zero by the sender
	-- Delta Pseudo Range Correction 2	
	deltaRangeRateCor2		INTEGER (-7..7),		-- This IE shall be ignored by the receiver and
													-- set to zero by the sender
	-- Delta Pseudo Range Correction 3
	deltaPseudoRangeCor3 	INTEGER (-127..127),	-- This IE shall be ignored by the receiver and
													-- set to zero by the sender
	-- Delta Pseudo Range Correction 3
	deltaRangeRateCor3		INTEGER (-7..7)			-- This IE shall be ignored by the receiver and
													-- set to zero by the sender
}

SatelliteID ::= INTEGER (0..63)	-- identifies satellite

-- Navigation Model IE
NavigationModel ::= SEQUENCE {
	navModelList	SeqOfNavModelElement	
}

-- navigation model satellite list
SeqOfNavModelElement ::= SEQUENCE (SIZE(1..16)) OF NavModelElement

NavModelElement ::= SEQUENCE {
	satelliteID		SatelliteID,			
	satStatus		SatStatus		-- satellite status
}

-- the Status of the navigation model
SatStatus ::= CHOICE {
	-- New satellite, new Navigation Model
	newSatelliteAndModelUC	UncompressedEphemeris,

	-- Existing satellite, Existing Navigation Model
	oldSatelliteAndModel	NULL,

	-- Existing satellite, new Navigation Model
	newNaviModelUC			UncompressedEphemeris,
	...
}

-- Uncompressed satellite emhemeris and clock corrections
UncompressedEphemeris ::= SEQUENCE {
	ephemCodeOnL2	INTEGER (0..3),
	ephemURA		INTEGER (0..15),
	ephemSVhealth	INTEGER (0..63),
	ephemIODC		INTEGER	(0..1023),
	ephemL2Pflag	INTEGER (0..1),
	ephemSF1Rsvd	EphemerisSubframe1Reserved,
	ephemTgd		INTEGER (-128..127),
	ephemToc		INTEGER (0..37799),
	ephemAF2		INTEGER (-128..127),
	ephemAF1		INTEGER (-32768..32767),
	ephemAF0		INTEGER (-2097152..2097151),
	ephemCrs		INTEGER (-32768..32767),
	ephemDeltaN		INTEGER (-32768..32767),
	ephemM0			INTEGER (-2147483648..2147483647),
	ephemCuc		INTEGER (-32768..32767),
	ephemE			INTEGER (0..4294967295),
	ephemCus		INTEGER (-32768..32767),
	ephemAPowerHalf	INTEGER (0..4294967295),
	ephemToe		INTEGER (0..37799),
	ephemFitFlag	INTEGER (0..1),
	ephemAODA		INTEGER (0..31),
	ephemCic		INTEGER (-32768..32767),
	ephemOmegaA0	INTEGER (-2147483648..2147483647),
	ephemCis		INTEGER (-32768..32767),
	ephemI0			INTEGER (-2147483648..2147483647),
	ephemCrc		INTEGER (-32768..32767),
	ephemW			INTEGER (-2147483648..2147483647),
	ephemOmegaADot	INTEGER (-8388608..8388607),
	ephemIDot		INTEGER (-8192..8191)
}

-- Reserved bits in subframe 1 of navigation message
EphemerisSubframe1Reserved ::= SEQUENCE {
	reserved1		INTEGER (0..8388607),	-- 23-bit field
	reserved2		INTEGER (0..16777215),	-- 24-bit field
	reserved3		INTEGER (0..16777215),	-- 24-bit field
	reserved4		INTEGER (0..65535)		-- 16-bit field
}

-- Ionospheric Model IE
IonosphericModel ::= SEQUENCE {
	alfa0			INTEGER (-128..127),
	alfa1			INTEGER (-128..127),
	alfa2			INTEGER (-128..127),
	alfa3			INTEGER (-128..127),
	beta0			INTEGER (-128..127),
	beta1			INTEGER (-128..127),
	beta2			INTEGER (-128..127),
	beta3			INTEGER (-128..127)
}

-- Universal Time Coordinate Model
UTCModel ::= SEQUENCE {
	utcA1			INTEGER (-8388608..8388607),
	utcA0			INTEGER (-2147483648..2147483647),
	utcTot			INTEGER (0..255),
	utcWNt			INTEGER (0..255),
	utcDeltaTls		INTEGER (-128..127),
	utcWNlsf		INTEGER (0..255),
	utcDN			INTEGER (-128..127),
	utcDeltaTlsf	INTEGER (-128..127)
}

-- Almanac, Long term model
-- NOTE: These are parameters are subset of the ephemeris
-- NOTE: But with reduced resolution and accuracy
Almanac ::= SEQUENCE {
	alamanacWNa		INTEGER (0..255),	-- Once per message

	-- navigation model satellite list.
	-- The size of almanacList is actually Nums_Sats_Total field
	almanacList		SeqOfAlmanacElement		
}
SeqOfAlmanacElement ::= SEQUENCE (SIZE(1..64)) OF AlmanacElement

-- Almanac info once per satellite
AlmanacElement ::= SEQUENCE {
	satelliteID			SatelliteID,
	almanacE			INTEGER (0..65535),
	alamanacToa			INTEGER (0..255),
	almanacKsii			INTEGER (-32768..32767),
	almanacOmegaDot		INTEGER (-32768..32767),
	almanacSVhealth		INTEGER (0..255),
	almanacAPowerHalf	INTEGER (0..16777215),
	almanacOmega0		INTEGER (-8388608..8388607),
	almanacW			INTEGER (-8388608..8388607),
	almanacM0			INTEGER (-8388608..8388607),
	almanacAF0			INTEGER (-1024..1023),
	almanacAF1			INTEGER (-1024..1023)
}

-- Acquisition Assistance
AcquisAssist ::= SEQUENCE {

	-- Number of Satellites can be read from acquistList
	timeRelation	TimeRelation,

	-- Acquisition assistance list
	-- The size of Number of Satellites is actually Number of Satellites field
	acquisList		SeqOfAcquisElement		
}
SeqOfAcquisElement ::= SEQUENCE (SIZE(1..16)) OF AcquisElement

-- the relationship between GPS time and air-interface timing
TimeRelation ::= SEQUENCE {
	--
	gpsTOW		GPSTOW23b,		-- 23b presentation
	gsmTime		GSMTime		OPTIONAL
}

-- data occuring per number of satellites
AcquisElement ::= SEQUENCE {
	svid					SatelliteID,

	-- Doppler 0th order term,
	-- -5120.0 - 5117.5 Hz (= -2048 - 2047 with 2.5 Hz resolution)
	doppler0				INTEGER (-2048..2047),	
	addionalDoppler			AddionalDopplerFields	OPTIONAL,
	codePhase				INTEGER (0..1022),	-- Code Phase
	intCodePhase			INTEGER (0..19),	-- Integer Code Phase
	gpsBitNumber			INTEGER (0..3), 	-- GPS bit number
	codePhaseSearchWindow	INTEGER (0..15),	-- Code Phase Search Window
	addionalAngle			AddionalAngleFields		OPTIONAL
}

AddionalDopplerFields ::= SEQUENCE {
	-- Doppler 1st order term, -1.0 - +0.5 Hz/sec
 -- (= -42 + (0 to 63) with 1/42 Hz/sec. resolution)
	doppler1				INTEGER (0..63),
	dopplerUncertainty		INTEGER (0..7)
 -- a sender shall not encode any DopplerUncertainty value in the range 5 to 7
 -- a receiver shall ignore any value between 5 and 7.
}

AddionalAngleFields	::= SEQUENCE {
	-- azimuth angle, 0 - 348.75 deg (= 0 - 31 with 11.25 deg resolution)
	azimuth					INTEGER (0..31),
	-- elevation angle, 0 - 78.75 deg (= 0 - 7 with 11.25 deg resolution)
	elevation				INTEGER (0..7)
}

-- Real-Time Integrity
-- number of bad satellites can be read from this element
SeqOf-BadSatelliteSet ::= SEQUENCE (SIZE(1..16)) OF SatelliteID

-- Extension Elements

-- Release 98 Extensions here
Rel98-MsrPosition-Req-Extension ::= SEQUENCE {
	rel98-Ext-ExpOTD			Rel98-Ext-ExpOTD		OPTIONAL,	-- ExpectedOTD extension
	..., 
 gpsTimeAssistanceMeasurementRequest NULL OPTIONAL, 
 gpsReferenceTimeUncertainty GPSReferenceTimeUncertainty OPTIONAL

-- Further R98 extensions here
}
Rel98-AssistanceData-Extension ::= SEQUENCE {
	rel98-Ext-ExpOTD			Rel98-Ext-ExpOTD		OPTIONAL,	-- ExpectedOTD extension
	..., 
 gpsTimeAssistanceMeasurementRequest NULL OPTIONAL,
 gpsReferenceTimeUncertainty GPSReferenceTimeUncertainty OPTIONAL

-- Further R98 extensions here
}

-- Release 98 ExpOTD extension
Rel98-Ext-ExpOTD ::= SEQUENCE {
-- If MsrAssistBTS is included in message, msrAssistData-R98-ExpOTD shall be included.
	msrAssistData-R98-ExpOTD			MsrAssistData-R98-ExpOTD			OPTIONAL,

-- If SystemInfoAssistaData is included in message, systemInfoAssistData-R98-ExpOTD shall be
-- included.
	systemInfoAssistData-R98-ExpOTD	SystemInfoAssistData-R98-ExpOTD	OPTIONAL
}

-- MsrAssistData R98 extension
MsrAssistData-R98-ExpOTD ::= SEQUENCE {
	 msrAssistList-R98-ExpOTD			 SeqOfMsrAssistBTS-R98-ExpOTD
}

-- Indexes in SeqOfMsrAssistBTS-R98-ExpOTD refer to SeqOfMsrAssistBTS
-- If the index exceeds the SegOfMsrAssistBTS range or if there is other
-- inconsistencies between the BTS indices, the MS shall apply protocol
-- error cause incorrectData
SeqOfMsrAssistBTS-R98-ExpOTD ::= SEQUENCE (SIZE(1..15)) OF MsrAssistBTS-R98-ExpOTD

-- This element completes MsrAssistBTS IE
MsrAssistBTS-R98-ExpOTD ::= SEQUENCE {
	expectedOTD				ExpectedOTD,
	expOTDUncertainty		ExpOTDUncertainty
}

-- SystemInfoAssistData R98 extension
SystemInfoAssistData-R98-ExpOTD ::= SEQUENCE {
	systemInfoAssistListR98-ExpOTD 	SeqOfSystemInfoAssistBTS-R98-ExpOTD
}

-- SeqOfSystemInfoAssistBTS-R98-ExpOTD index refer to SeqOfSystemInfoAssistBTS
-- If the index exceeds the SegOfSystemInfoAssistBTS range or if there is other
-- inconsistencies between the BTS indices, the MS shall apply protocol
-- error cause incorrectData
SeqOfSystemInfoAssistBTS-R98-ExpOTD ::= SEQUENCE (SIZE(1..32)) OF SystemInfoAssistBTS-R98-ExpOTD

-- whether n.th is present or not ?
SystemInfoAssistBTS-R98-ExpOTD ::= CHOICE {
	notPresent		NULL,
	present			AssistBTSData-R98-ExpOTD
}

-- This element completes AssistBTSData IE
AssistBTSData-R98-ExpOTD ::= SEQUENCE {
	expectedOTD				ExpectedOTD,
	expOTDuncertainty		ExpOTDUncertainty	-- Uncertainty of expected OTD
}

-- Expected OTD value between nbor base station and reference BTS
-- at MS's current estimated location.
ExpectedOTD ::= INTEGER (0..1250)
-- The ExpectedOTD value 1250 shall not be encoded by the transmitting entity and
-- shall be treated by the receiving entity as 0.
-- Uncertainty of Exptected OTD in bits
ExpOTDUncertainty ::= INTEGER(0..7)

-- Release 98 extensions

GPSReferenceTimeUncertainty ::= INTEGER (0 .. 127) 		-- Coding according to Annex

GPSTimeAssistanceMeasurements ::= SEQUENCE {
 referenceFrameMSB INTEGER (0 .. 63)	OPTIONAL, 		-- MSB of frame number
 gpsTowSubms INTEGER (0 .. 9999) 		OPTIONAL, 		-- in units of 100ns, for MS based AGPS
 deltaTow INTEGER (0 .. 127) 			OPTIONAL, 		-- for MS assisted AGPS
 gpsReferenceTimeUncertainty GPSReferenceTimeUncertainty OPTIONAL
}

Rel-98-MsrPosition-Rsp-Extension ::= SEQUENCE {

	-- First extension to Release 98
	rel-98-Ext-MeasureInfo	SEQUENCE {
		otd-MeasureInfo-R98-Ext	OTD-MeasureInfo-R98-Ext		OPTIONAL
	},
	..., 
 timeAssistanceMeasurements GPSTimeAssistanceMeasurements OPTIONAL 
 -- Further R98 extensions here
}

-- This is an addition to OTD-MeasureInfo element defined in original message,
-- If OTD-MeasureInfo is absent, or if one or more OTD-MsrElementRest are present
-- OTD-MeasureInfo-R98-Ext shall be absent.
-- OTD-MeasureInfo-R98-Ext
OTD-MeasureInfo-R98-Ext ::= SEQUENCE {
	-- Measurement info elements
	otdMsrFirstSets-R98-Ext		OTD-MsrElementFirst-R98-Ext
}

-- OTD measurement information Ext for the first set only
OTD-MsrElementFirst-R98-Ext ::= SEQUENCE {
	-- additional measured neighbors in OTD measurements
	otd-FirstSetMsrs-R98-Ext 	SeqOfOTD-FirstSetMsrs-R98-Ext 	OPTIONAL
}
SeqOfOTD-FirstSetMsrs-R98-Ext ::= SEQUENCE (SIZE(1..5)) OF OTD-FirstSetMsrs

Rel-5-MsrPosition-Rsp-Extension ::= SEQUENCE {

	extended-reference	Extended-reference 	OPTIONAL,
	-- The extended-reference shall be included by the MS if and only if previously
	-- received from the SMLC in a Measure Position Request. When included, the value sent
	-- by the MS shall equal the value received from the SMLC.

	-- extension to Release 5, for RRLP pseudo-segmentation here
	otd-MeasureInfo-5-Ext	OTD-MeasureInfo-5-Ext	OPTIONAL,
	ulPseudoSegInd			UlPseudoSegInd			OPTIONAL,	-- Included when uplink RRLP
	-- Pseudo-segmentation is used, not included when no uplink pseudo-segmentation is used
	...
					-- Possibly more extensions for Release 5 here later
}

Extended-reference ::= SEQUENCE {
	smlc-code			INTEGER (0..63),
	transaction-ID		INTEGER (0..262143)
}

OTD-MeasureInfo-5-Ext ::= SeqOfOTD-MsrElementRest
	-- if more than one measurement sets are present this element is repeated
	-- NumberOfSets - 1 (-1 = first set) combined in OTD-MeasureInfo-5-Ext and
	-- OTD-MeasureInfo (e.g. if NumberOfSets is 3, then one otdMsrRestSets may
	-- be sent in OTD-MeasureInfo-5-Ext and one in OTD-MeasureInfo)

-- First part of Uplink RRLP Pseudo-segmentation indication, possibly more may be defined
-- in the future for segmentation with more than two segments.
UlPseudoSegInd ::= ENUMERATED {
	firstOfMany (0),
	secondOfMany(1)
}

Rel5-MsrPosition-Req-Extension ::= SEQUENCE {
	extended-reference			Extended-reference,
	...
	-- Possibly more extensions for Release 5 here later
}

Rel5-AssistanceData-Extension ::= SEQUENCE {
	extended-reference			Extended-reference,
	...

-- Possibly more extensions for Release 5 here later
}

Rel-5-ProtocolError-Extension::= SEQUENCE {
	extended-reference			Extended-reference 	OPTIONAL,
	-- The extended-reference shall be included by the MS if and only if previously
	-- received from the SMLC.
	-- When included, the value sent by the MS shall equal the value received from the SMLC.
	...

	-- Possibly more extensions for Release 5 here later
}

-- Release 7 Extensions here

Rel7-MsrPosition-Req-Extension ::= SEQUENCE {
	velocityRequested								NULL					OPTIONAL,
	ganssPositionMethod								GANSSPositioningMethod	OPTIONAL,
	ganss-AssistData								GANSS-AssistData		OPTIONAL,
	ganssCarrierPhaseMeasurementRequest				NULL					OPTIONAL,
	ganssTODGSMTimeAssociationMeasurementRequest	NULL					OPTIONAL,
	requiredResponseTime							RequiredResponseTime	OPTIONAL,
	add-GPS-AssistData								Add-GPS-AssistData		OPTIONAL,
	ganssMultiFreqMeasurementRequest				NULL					OPTIONAL,
	...
	-- Further Release 7 extentions here
}

-- additional satellite systems may be added in future versions of the protocol
-- Bit 0 of GANSSPositioningMethod bit map shall not be the only one set to TRUE ('1')
GANSSPositioningMethod ::= BIT STRING {
	gps 	 	 	 (0),
	galileo 	 	 (1),
	sbas 	 	 	 (2),
	modernizedGPS 	 (3),
	qzss 	 	 	 (4),
	glonass 	 	 (5) } (SIZE (2..16))

GANSS-AssistData ::= SEQUENCE {
	ganss-controlHeader	GANSS-ControlHeader
}
GANSS-ControlHeader ::= SEQUENCE {
 ganssCommonAssistData 			GANSSCommonAssistData 				OPTIONAL,
 ganssGenericAssistDataList 	SeqOfGANSSGenericAssistDataElement 	OPTIONAL
}

-- GANSS Common Assistance Data Elements
GANSSCommonAssistData ::= SEQUENCE {
	ganssReferenceTime		 	GANSSReferenceTime		 	OPTIONAL,
	ganssRefLocation			GANSSRefLocation		 	OPTIONAL,
	ganssIonosphericModel		GANSSIonosphericModel	 	OPTIONAL,
	... ,
	ganssAddIonosphericModel	GANSSAddIonosphericModel	OPTIONAL,
	ganssEarthOrientParam		GANSSEarthOrientParam		OPTIONAL
}

-- List of GANSS Generic Assistance Data Elements, up to 8 GANSS
SeqOfGANSSGenericAssistDataElement ::= SEQUENCE (SIZE (1..8)) OF GANSSGenericAssistDataElement
-- GANSS Generic Assistance Data Elements
GANSSGenericAssistDataElement ::= SEQUENCE {
	ganssID 	INTEGER (0..7)	OPTIONAL, -- Coding according to Annex
	ganssTimeModel	SeqOfGANSSTimeModel	OPTIONAL,
	ganssDiffCorrections	GANSSDiffCorrections	OPTIONAL,
	ganssNavigationModel	GANSSNavModel	OPTIONAL,
	ganssRealTimeIntegrity	GANSSRealTimeIntegrity	OPTIONAL,
	ganssDataBitAssist	GANSSDataBitAssist	OPTIONAL,
	ganssRefMeasurementAssist	GANSSRefMeasurementAssist 	OPTIONAL,
	ganssAlmanacModel	GANSSAlmanacModel	OPTIONAL,
	ganssUTCModel	GANSSUTCModel	OPTIONAL,
	ganssEphemerisExtension	GANSSEphemerisExtension	OPTIONAL,
	ganssEphemerisExtCheck	GANSSEphemerisExtensionCheck	OPTIONAL,
	... ,
	sbasID	INTEGER (0..7) 	OPTIONAL, -- Coding according to Annex
	ganssAddUTCModel	GANSSAddUTCModel	OPTIONAL,
	ganssAuxiliaryInfo	GANSSAuxiliaryInformation	OPTIONAL,
	ganssDiffCorrectionsValidityPeriod	GANSSDiffCorrectionsValidityPeriod	OPTIONAL
}

-- GANSS COMMON ASSISTANCE DATA ELEMENTS

-- GANSS Reference Time IE
GANSSReferenceTime ::= SEQUENCE {
	ganssRefTimeInfo				GANSSRefTimeInfo,
	ganssTOD-GSMTimeAssociation 	GANSSTOD-GSMTimeAssociation OPTIONAL
}

-- GANSS Reference Time includes GANSS TOD, GANSS Day, uncertainty
GANSSRefTimeInfo ::= SEQUENCE {
	ganssDay			 INTEGER(0 .. 8191) 	 OPTIONAL,
 	ganssTOD			 GANSSTOD,
	ganssTODUncertainty	 GANSSTODUncertainty	 OPTIONAL,
 	ganssTimeID 		 INTEGER (0 .. 7) 		 OPTIONAL
}

-- GANSS TOD integer seconds
GANSSTOD ::= INTEGER (0 .. 86399)

-- GANSS TOD uncertainty
GANSSTODUncertainty ::= INTEGER (0 .. 127) -- Coding according to Annex

-- GANSS TOD-GSM Time association 
GANSSTOD-GSMTimeAssociation ::= SEQUENCE {
	bcchCarrier		BCCHCarrier,	-- BCCH carrier
	bsic			BSIC,			-- BSIC
	frameNumber		FrameNumber,
	timeSlot		TimeSlot,
	bitNumber		BitNumber,
 	frameDrift 		FrameDrift 			OPTIONAL
}

-- Frame drift
FrameDrift ::= INTEGER(-64 .. 63)

-- GANSS Reference Location IE
GANSSRefLocation ::= SEQUENCE {
	threeDLocation			Ext-GeographicalInformation
}

-- GANSS Ionospheric Model IE
-- GANSS Ionospheric Model consists of NeQuick model parameters and storm flags
GANSSIonosphericModel ::= SEQUENCE {
 	ganssIonoModel 			GANSSIonosphereModel,
 	ganssIonoStormFlags 	GANSSIonoStormFlags 			OPTIONAL,
 	...
}

-- GANSS ionosphere model. Coding according to Annex 
GANSSIonosphereModel ::= SEQUENCE {
 	ai0 INTEGER (0 .. 4095),
 	ai1 INTEGER (0 .. 4095),
 	ai2 INTEGER (0 .. 4095)
}

-- GANSS ionosphere storm flags
GANSSIonoStormFlags ::= SEQUENCE {
	ionoStormFlag1	INTEGER (0 .. 1),
	ionoStormFlag2	INTEGER (0 .. 1),
	ionoStormFlag3	INTEGER (0 .. 1),
	ionoStormFlag4	INTEGER (0 .. 1),
	ionoStormFlag5	INTEGER (0 .. 1)
}

-- GANSS Additional Ionospheric Model IE
-- GANSS Additional Ionospheric Model consists of Klobuchar model parameters
GANSSAddIonosphericModel ::= SEQUENCE {
	dataID		BIT STRING (SIZE (2)), 	 -- Coding according to Annex
	ionoModel	IonosphericModel
}

-- GANSS Earth Orientation Paramaters IE
GANSSEarthOrientParam ::= SEQUENCE {
	teop				INTEGER (0..65535),
	pmX					INTEGER (-1048576..1048575),
	pmXdot				INTEGER (-16384..16383),
	pmY					INTEGER (-1048576..1048575),
	pmYdot				INTEGER (-16384..16383),
	deltaUT1			INTEGER (-1073741824..1073741823),
	deltaUT1dot			INTEGER (-262144..262143)
}

-- GANSS GENERIC ASSISTANCE DATA ELEMENTS

-- GANSS Time Model IE consists of time offset and first and second order parameters to relate GNSS
-- specific system time to selected time reference
SeqOfGANSSTimeModel ::= SEQUENCE (SIZE(1..7)) OF GANSSTimeModelElement

GANSSTimeModelElement ::= SEQUENCE {
	ganssTimeModelRefTime		INTEGER(0 .. 65535),
	tA0		 					TA0,
	tA1		 					TA1 					OPTIONAL,
	tA2		 					TA2 					OPTIONAL,
 	gnssTOID 					INTEGER (0 .. 7), 		-- coding according to annex
 	weekNumber 					INTEGER (0 .. 8191) 	OPTIONAL 
}

-- GANSS time model parameter A0
TA0 ::= INTEGER (-2147483648 .. 2147483647)

-- GANSS time model parameter A1
TA1 ::= INTEGER (-8388608 .. 8388607)

-- GANSS time model parameter A2
TA2 ::= INTEGER (-64 .. 63)


-- DGANSS Corrections IE
GANSSDiffCorrections ::= SEQUENCE {
	dganssRefTime		INTEGER (0 .. 119),	 -- DGANSS reference time

	-- N_SGN_TYPE can be read from number of elements of sgnTypeList
	sgnTypeList		 SeqOfSgnTypeElement
}

SeqOfSgnTypeElement ::= SEQUENCE (SIZE (1..3)) OF SgnTypeElement -- max three signals per GNSS

-- DGANSS signal type element, once per GNSS signal type included in DGANSS
SgnTypeElement ::= SEQUENCE {
	ganssSignalID		 GANSSSignalID, -- signal type identity
 	ganssStatusHealth	 INTEGER (0 .. 7),
	-- N_SAT can be read from number of elements of dganssSgnList
 	dganssSgnList		 SeqOfDGANSSSgnElement
}

GANSSSignalID ::= INTEGER (0 .. 7)	-- Coding according to Annex
SeqOfDGANSSSgnElement ::= SEQUENCE (SIZE (1..16)) OF DGANSSSgnElement

-- number of correction for signals
DGANSSSgnElement ::= SEQUENCE {
	svID		 	SVID, -- Satellite identity

--- Sequence number for GANSS Navigation Model that matches the DGANSS correction set
	iod 			INTEGER (0 .. 1023),

	-- User Differential Range Error
	udre			INTEGER (0..3),		

	-- Pseudo Range Correction, range is
	-- -655.04 - +655.04,
	pseudoRangeCor	INTEGER (-2047..2047), 	

	-- Pseudo Range Rate Correction, range is
	-- -4.064 - +4.064,
	rangeRateCor	INTEGER (-127..127)
}

SVID ::= INTEGER (0 .. 63)	-- Coding according to Annex

-- GANSS Navigation Model IE
GANSSNavModel ::= SEQUENCE {
 	nonBroadcastIndFlag 	INTEGER (0 .. 1), 
	ganssSatelliteList 		SeqOfGANSSSatelliteElement
}

SeqOfGANSSSatelliteElement ::= SEQUENCE (SIZE(1..32)) OF GANSSSatelliteElement

GANSSSatelliteElement ::= SEQUENCE {
 svID 				SVID,
 svHealth 			BIT STRING (SIZE(5)), 	-- Coding according to Annex
 iod 				INTEGER (0 .. 1023), 	-- Coding according to Annex
 ganssClockModel 	GANSSClockModel, 
 ganssOrbitModel 	GANSSOrbitModel,  
 ...,
 svHealthMSB		BIT STRING (SIZE(1)) 	OPTIONAL, -- Coding according to Annex
 iodMSB				INTEGER (0 .. 1) 		OPTIONAL  -- Coding according to Annex
}

-- GANSS orbit model for the GNSS satellite according to the choice
GANSSOrbitModel ::= CHOICE {
	keplerianSet	 	NavModel-KeplerianSet,		-- Model-1
	... ,
	navKeplerianSet	 	NavModel-NAVKeplerianSet, 	-- Model-2
	cnavKeplerianSet	NavModel-CNAVKeplerianSet, 	-- Model-3
	glonassECEF			NavModel-GLONASSecef, 		-- Model-4
	sbasECEF			NavModel-SBASecef			-- Model-5
}

-- Navigation model in Keplerian parameters
NavModel-KeplerianSet ::= SEQUENCE {
	keplerToe 		 INTEGER (0 .. 16383), 
	keplerW			 INTEGER (-2147483648..2147483647),
	keplerDeltaN	 INTEGER (-32768..32767),
	keplerM0		 INTEGER (-2147483648..2147483647),
	keplerOmegaDot	 INTEGER (-8388608..8388607),
	keplerE 	 	 INTEGER (0..4294967295),
	keplerIDot		 INTEGER (-8192..8191),
	keplerAPowerHalf INTEGER (0.. 4294967295),
	keplerI0		 INTEGER (-2147483648..2147483647),
	keplerOmega0 	 INTEGER (-2147483648..2147483647),
	keplerCrs		 INTEGER (-32768..32767),
	keplerCis		 INTEGER (-32768..32767),
	keplerCus		 INTEGER (-32768..32767),
	keplerCrc		 INTEGER (-32768..32767),
	keplerCic		 INTEGER (-32768..32767),
	keplerCuc		 INTEGER (-32768..32767)
}

NavModel-NAVKeplerianSet ::= SEQUENCE {
	navURA			INTEGER (0..15),
	navFitFlag		INTEGER (0..1),
	navToe			INTEGER (0..37799),
	navOmega		INTEGER (-2147483648..2147483647),
	navDeltaN		INTEGER (-32768..32767),
	navM0			INTEGER (-2147483648..2147483647),
	navOmegaADot	INTEGER (-8388608..8388607),
	navE			INTEGER (0..4294967295),
	navIDot			INTEGER (-8192..8191),
	navAPowerHalf	INTEGER (0..4294967295),
	navI0			INTEGER (-2147483648..2147483647),
	navOmegaA0		INTEGER (-2147483648..2147483647),
	navCrs			INTEGER (-32768..32767),
	navCis			INTEGER (-32768..32767),
	navCus			INTEGER (-32768..32767),
	navCrc			INTEGER (-32768..32767),
	navCic			INTEGER (-32768..32767),
	navCuc			INTEGER (-32768..32767)
}

NavModel-CNAVKeplerianSet ::= SEQUENCE {
	cnavTop				INTEGER (0..2015),
	cnavURAindex		INTEGER (-16..15),
	cnavDeltaA			INTEGER (-33554432..33554431),
	cnavAdot			INTEGER (-16777216..16777215),
	cnavDeltaNo			INTEGER (-65536..65535),
	cnavDeltaNoDot		INTEGER (-4194304..4194303),
	cnavMo				INTEGER (-4294967296..4294967295),
	cnavE				INTEGER (0..8589934591),
	cnavOmega			INTEGER (-4294967296..4294967295),
	cnavOMEGA0			INTEGER (-4294967296..4294967295),
	cnavDeltaOmegaDot	INTEGER (-65536..65535),
	cnavIo				INTEGER (-4294967296..4294967295),
	cnavIoDot			INTEGER (-16384..16383),
	cnavCis				INTEGER (-32768..32767),
	cnavCic				INTEGER (-32768..32767),
	cnavCrs				INTEGER (-8388608..8388607),
	cnavCrc				INTEGER (-8388608..8388607),
	cnavCus				INTEGER (-1048576..1048575),
	cnavCuc				INTEGER (-1048576..1048575)
}

NavModel-GLONASSecef ::= SEQUENCE {
	gloEn				INTEGER (0..31),
	gloP1				BIT STRING (SIZE(2)),
	gloP2				BOOLEAN,
	gloM				INTEGER (0..3),
	gloX				INTEGER (-67108864..67108863),
	gloXdot				INTEGER (-8388608..8388607),
	gloXdotdot			INTEGER (-16..15),
	gloY				INTEGER (-67108864..67108863),
	gloYdot				INTEGER (-8388608..8388607),
	gloYdotdot			INTEGER (-16..15),
	gloZ				INTEGER (-67108864..67108863),
	gloZdot				INTEGER (-8388608..8388607),
	gloZdotdot			INTEGER (-16..15)
}


NavModel-SBASecef ::= SEQUENCE {
	sbasTo				INTEGER (0..5399) 					OPTIONAL,
	sbasAccuracy		BIT STRING (SIZE(4)),
	sbasXg				INTEGER (-536870912..536870911),
	sbasYg				INTEGER (-536870912..536870911),
	sbasZg				INTEGER (-16777216..16777215),
	sbasXgDot			INTEGER (-65536..65535),
	sbasYgDot			INTEGER (-65536..65535),
	sbasZgDot			INTEGER (-131072..131071),
	sbasXgDotDot		INTEGER (-512..511),
	sbagYgDotDot		INTEGER (-512..511),
	sbasZgDotDot		INTEGER (-512..511)
}

-- GANSS clock model for the GNSS satellite according to the choice
GANSSClockModel ::= CHOICE {
	standardClockModelList	 SeqOfStandardClockModelElement,	-- Model-1
	... ,
	navClockModel			 NAVclockModel, 					-- Model-2
	cnavClockModel			 CNAVclockModel, 					-- Model-3
	glonassClockModel		 GLONASSclockModel, 				-- Model-4
	sbasClockModel			 SBASclockModel						-- Model-5
}

SeqOfStandardClockModelElement ::= SEQUENCE (SIZE(1..2)) OF StandardClockModelElement

StandardClockModelElement ::= SEQUENCE {
 	stanClockToc 	INTEGER (0 .. 16383), 
 	stanClockAF2 	INTEGER (-2048 .. 2047), 
 	stanClockAF1 	INTEGER (-131072 .. 131071), 
 	stanClockAF0 	INTEGER (-134217728 .. 134217727),
 	stanClockTgd 	INTEGER (-512 .. 511) 				OPTIONAL,
 	stanModelID 	INTEGER (0 .. 1) 					OPTIONAL,
 	...
} 

NAVclockModel ::= SEQUENCE {
	navToc			INTEGER (0.. 37799),
	navaf2			INTEGER (-128..127),
	navaf1			INTEGER (-32768..32767),
	navaf0			INTEGER (-2097152..2097151),
	navTgd			INTEGER (-128..127)
}

CNAVclockModel ::= SEQUENCE {
	cnavToc			INTEGER (0..2015),
	cnavTop			INTEGER (0..2015),
	cnavURA0		INTEGER (-16..15),
	cnavURA1		INTEGER (0..7),
	cnavURA2		INTEGER (0..7),
	cnavAf2			INTEGER (-512..511),
	cnavAf1			INTEGER (-524288..524287),
	cnavAf0			INTEGER (-33554432..33554431),
	cnavTgd			INTEGER (-4096..4095),
	cnavISCl1cp		INTEGER (-4096..4095) 			OPTIONAL,
	cnavISCl1cd		INTEGER (-4096..4095) 			OPTIONAL,
	cnavISCl1ca		INTEGER (-4096..4095) 			OPTIONAL,
	cnavISCl2c		INTEGER (-4096..4095) 			OPTIONAL,
	cnavISCl5i5		INTEGER (-4096..4095) 			OPTIONAL,
	cnavISCl5q5		INTEGER (-4096..4095) 			OPTIONAL
}

GLONASSclockModel ::= SEQUENCE {
	gloTau			INTEGER (-2097152..2097151),
	gloGamma		INTEGER (-1024..1023),
	gloDeltaTau		INTEGER (-16..15) 				OPTIONAL
}

SBASclockModel ::= SEQUENCE {
	sbasTo			INTEGER (0..5399),
	sbasAgfo		INTEGER (-2048..2047),
	sbasAgf1		INTEGER (-128..127)
}

-- GANSS Real-Time Integrity IE
GANSSRealTimeIntegrity ::= SEQUENCE {
 -- list of satellites with bad signals
 -- NBS can be read from number of elements in SeqOf-BadSignalSet
 	ganssBadSignalList 		SeqOfBadSignalElement
}

SeqOfBadSignalElement ::= SEQUENCE (SIZE(1..16)) OF BadSignalElement

BadSignalElement ::= SEQUENCE {
 	badSVID 		SVID, 						 -- Coding according to Annex
 	badSignalID 	GANSSSignals 	OPTIONAL	 -- Coding according to Annex
}

-- GANSS Data Bit Assistance IE
GANSSDataBitAssist ::= SEQUENCE {
	ganssTOD 					INTEGER (0 .. 59),
	-- N_SAT can be read from number of elements in SeqOfGanssDataBitsElement
	ganssDataBitsSatList		SeqOfGanssDataBitsElement,
	...
}

SeqOfGanssDataBitsElement ::= SEQUENCE (SIZE(1 .. 32))OF GanssDataBitsElement

GanssDataBitsElement ::= SEQUENCE {
	svID					SVID,
	-- N_SGN can be read from number of elements in Seq-OfGANSSDataBitsSgn
	ganssDataBitsSgnList	Seq-OfGANSSDataBitsSgn,
	...
}

Seq-OfGANSSDataBitsSgn ::= SEQUENCE (SIZE(1..8)) OF GANSSDataBitsSgnElement

GANSSDataBitsSgnElement ::= SEQUENCE {
	ganssSignalType		GANSSSignalID,
	-- N_BIT can be read from number of elements in SeqOf-DataBits
	ganssDataBits		SeqOf-GANSSDataBits,
	...
}

SeqOf-GANSSDataBits ::= SEQUENCE (SIZE(1 .. 1024)) OF GANSSDataBit
GANSSDataBit ::= INTEGER(0 .. 1)

-- GANSS Reference Measurement Assistance IE
-- Code and Doppler assistance from the network. 
GANSSRefMeasurementAssist ::= SEQUENCE {
	ganssSignalID			GANSSSignalID,	-- Coding according to Annex
	ganssRefMeasAssistList	SeqOfGANSSRefMeasurementElement
}

SeqOfGANSSRefMeasurementElement ::= SEQUENCE (SIZE(1 .. 16)) OF GANSSRefMeasurementElement

GANSSRefMeasurementElement ::= SEQUENCE {
	svID					SVID,
	-- Doppler 0th order term,
	-- -1024 m/s to 1023.5 m/s with 0.5 m/s resolution)
	doppler0				INTEGER (-2048 .. 2047),					-- Coding according to Annex
	additionalDoppler		AdditionalDopplerFields			OPTIONAL,
	codePhase				INTEGER (0 .. 1022),						-- Code Phase in ms
	intCodePhase			INTEGER (0 .. 127),							-- Integer Code Phase in ms
	codePhaseSearchWindow	INTEGER (0 .. 31),				-- Code Phase Search Window, see Annex
	additionalAngle			AddionalAngleFields		 		OPTIONAL,
	...
}

AdditionalDopplerFields ::= SEQUENCE {
	-- Doppler 1st order term, -0.2 - +0.1 m/s2
	-- ( = -42 + (0 to 63) with 1/210 m/s2 resolution)
	doppler1				INTEGER (0..63),
	dopplerUncertainty		INTEGER (0..4)
}

-- GANSS Almanac Model IE
GANSSAlmanacModel ::= SEQUENCE {
 	weekNumber 			INTEGER (0 .. 255),
	toa 				INTEGER (0 .. 255) 	OPTIONAL,
	ioda 				INTEGER (0 .. 3) 	OPTIONAL,
	ganssAlmanacList 	SeqOfGANSSAlmanacElement
}


SeqOfGANSSAlmanacElement ::= SEQUENCE (SIZE(1 .. 36)) OF GANSSAlmanacElement

-- GANSS Almanac Model 
GANSSAlmanacElement ::= CHOICE {
	keplerianAlmanacSet	 	Almanac-KeplerianSet,			-- Model-1
 	...,
	keplerianNAVAlmanac	 	Almanac-NAVKeplerianSet, 		-- Model-2
	keplerianReducedAlmanac	Almanac-ReducedKeplerianSet, 	-- Model-3
	keplerianMidiAlmanac	Almanac-MidiAlmanacSet, 		-- Model-4
	keplerianGLONASS		Almanac-GlonassAlmanacSet, 		-- Model-5
	ecefSBASAlmanac			Almanac-ECEFsbasAlmanacSet		-- Model-6
}

-- Almanac parameters according to Keplerian parameters
Almanac-KeplerianSet ::= SEQUENCE {
	svID					SVID,
 	kepAlmanacE			 	INTEGER (0 .. 2047),
	kepAlmanacDeltaI		INTEGER (-1024 .. 1023),
	kepAlmanacOmegaDot		INTEGER (-1024 .. 1023),
 	kepSVHealth 			INTEGER (0 .. 15), 			 -- Coding according to Annex
	kepAlmanacAPowerHalf	INTEGER (-65536 .. 65535),
	kepAlmanacOmega0		INTEGER (-32768 .. 32767),
	kepAlmanacW			 	INTEGER (-32768 .. 32767),
	kepAlmanacM0			INTEGER (-32768 .. 32767),
	kepAlmanacAF0			INTEGER (-8192 .. 8191),
	kepAlmanacAF1			INTEGER (-1024..1023)
}

Almanac-NAVKeplerianSet ::= SEQUENCE {
	svID					SVID,
	navAlmE					INTEGER (0..65535),
	navAlmDeltaI			INTEGER (-32768..32767),
	navAlmOMEGADOT			INTEGER (-32768..32767),
	navAlmSVHealth			INTEGER (0..255),
	navAlmSqrtA				INTEGER (0..16777215),
	navAlmOMEGAo			INTEGER (-8388608..8388607),
	navAlmOmega				INTEGER (-8388608..8388607),
	navAlmMo				INTEGER (-8388608..8388607),
	navAlmaf0				INTEGER (-1024..1023),
	navAlmaf1				INTEGER (-1024..1023)
}

Almanac-ReducedKeplerianSet ::= SEQUENCE {
	svID					SVID,
	redAlmDeltaA			INTEGER (-128..127),
	redAlmOmega0			INTEGER (-64..63),
	redAlmPhi0				INTEGER (-64..63),
	redAlmL1Health			BOOLEAN,
	redAlmL2Health			BOOLEAN,
	redAlmL5Health			BOOLEAN
}

Almanac-MidiAlmanacSet ::= SEQUENCE {
	svID					SVID,
	midiAlmE				INTEGER (0..2047),
	midiAlmDeltaI			INTEGER (-1024..1023),
	midiAlmOmegaDot			INTEGER (-1024..1023),
	midiAlmSqrtA			INTEGER (0..131071),
	midiAlmOmega0			INTEGER (-32768..32767),
	midiAlmOmega			INTEGER (-32768..32767),
	midiAlmMo				INTEGER (-32768..32767),
	midiAlmaf0				INTEGER (-1024..1023),
	midiAlmaf1				INTEGER (-512..511),
	midiAlmL1Health			BOOLEAN,
	midiAlmL2Health			BOOLEAN,
	midiAlmL5Health			BOOLEAN
}

Almanac-GlonassAlmanacSet ::= SEQUENCE {
	gloAlmNA				INTEGER (1..1461),
	gloAlmnA				INTEGER (1..24),
	gloAlmHA				INTEGER (0..31),
	gloAlmLambdaA			INTEGER (-1048576..1048575),
	gloAlmtlambdaA			INTEGER (0..2097151),
	gloAlmDeltaIa			INTEGER (-131072..131071),
	gloAlmDeltaTA			INTEGER (-2097152..2097151),
	gloAlmDeltaTdotA		INTEGER (-64..63),
	gloAlmEpsilonA			INTEGER (0..32767),
	gloAlmOmegaA			INTEGER (-32768..32767),
	gloAlmTauA				INTEGER (-512..511),
	gloAlmCA				INTEGER (0..1),
	gloAlmMA				BIT STRING (SIZE(2)) 			OPTIONAL
}

Almanac-ECEFsbasAlmanacSet ::= SEQUENCE {
	sbasAlmDataID			INTEGER (0..3),
	svID					SVID,
	sbasAlmHealth			BIT STRING (SIZE(8)),
	sbasAlmXg				INTEGER (-16384..16383),
	sbasAlmYg				INTEGER (-16384..16383),
	sbasAlmZg				INTEGER (-256..255),
	sbasAlmXgdot			INTEGER (-4..3),
	sbasAlmYgDot			INTEGER (-4..3),
	sbasAlmZgDot			INTEGER (-8..7),
	sbasAlmTo				INTEGER (0..2047)
}

-- GANSS Universal Time Coordinate Model (Model-1)
GANSSUTCModel ::= SEQUENCE {
	ganssUtcA1			INTEGER (-8388608..8388607),
	ganssUtcA0			INTEGER (-2147483648..2147483647),
	ganssUtcTot			INTEGER (0..255),
	ganssUtcWNt			INTEGER (0..255),
	ganssUtcDeltaTls	INTEGER (-128..127),
	ganssUtcWNlsf		INTEGER (0..255),
	ganssUtcDN			INTEGER (-128..127),
	ganssUtcDeltaTlsf	INTEGER (-128..127)
}

--GANSS Ephemeris Extension
GANSSEphemerisExtension ::= SEQUENCE {
	ganssEphemerisHeader			GANSSEphemerisExtensionHeader			OPTIONAL,
	ganssReferenceSet				SeqOfGANSSRefOrbit						OPTIONAL,
	ganssephemerisDeltasMatrix		GANSSEphemerisDeltaMatrix				OPTIONAL,
...
}

-- The ganssEphemerisHeader and the ganssReferenceSet are mandatory only once in the delivery of the
-- GANSS Ephemeris Extension.  The ganssReferenceSet shall include all healthy satellite vehicles 
-- at the time of message construction.

GANSSEphemerisExtensionHeader ::= SEQUENCE {
	timeAtEstimation			GANSSEphemerisExtensionTime,
	validityPeriod				INTEGER(1..8),
-- The validity period, represented in hours, is the validity period of each individual ephemeris 
-- delta payload
	ephemerisExtensionDuration	INTEGER(1..512),
-- If the ephemerisExtensionDuration does not match the request duration made by the MS, the MS
-- should regard the provided ephemerisExtensionDuration as the limit of the SMLC ephemeris
-- extension capability at this time.
...
}

GANSSEphemerisExtensionTime ::= SEQUENCE {
	ganssEphExtDay		INTEGER(0..8191),
	ganssEphExtTOD		GANSSTOD,
...
}

-- Reference Nav Model for Ephepmeris Extension
ReferenceNavModel ::= SEQUENCE {
 	keplerToe			INTEGER (0..37799),
	keplerW				INTEGER (-2147483648..2147483647),
	keplerDeltaN		INTEGER (-32768..32767),
	keplerM0			INTEGER (-2147483648..2147483647),
	keplerOmegaDot		INTEGER (-8388608..8388607),
	keplerE				INTEGER (0..4294967295),
	keplerIDot			INTEGER (-8192..8191),
	keplerAPowerHalf	INTEGER (0.. 4294967295),
	keplerI0			INTEGER (-2147483648..2147483647),
	keplerOmega0		INTEGER (-2147483648..2147483647),
	keplerCrs			INTEGER (-32768..32767),
	keplerCis			INTEGER (-32768..32767),
	keplerCus			INTEGER (-32768..32767),
	keplerCrc			INTEGER (-32768..32767),
	keplerCic			INTEGER (-32768..32767),
	keplerCuc			INTEGER (-32768..32767)
}

SeqOfGANSSRefOrbit ::= SEQUENCE (SIZE(1..32)) OF GANSSReferenceOrbit
--The number of reference orbits can be read from number of elements in this sequence

GANSSReferenceOrbit ::= SEQUENCE {
	svID				SVID,
	ganssOrbitModel		ReferenceNavModel, 
	ganssClockModel		GANSSClockModel, 
...
}

GANSSEphemerisDeltaMatrix ::= SEQUENCE (SIZE(1 .. 128)) OF GANSSEphemerisDeltaEpoch

GANSSEphemerisDeltaEpoch ::= SEQUENCE {
	ganssDeltaEpochHeader		GANSSDeltaEpochHeader				OPTIONAL,
	ganssDeltaElementList		GANSSDeltaElementList,
...
}
-- Each GANSSDeltaEpoch element contains a header and the delta values for a particular time window
-- for all PRN's.

GANSSDeltaEpochHeader ::= SEQUENCE {
	validityPeriod				INTEGER(1..8)					OPTIONAL,
	ephemerisDeltaSizes			GANSSEphemerisDeltaBitSizes		OPTIONAL,
	ephemerisDeltaScales		GANSSEphemerisDeltaScales		OPTIONAL,
...
}
-- In each of the GANSSDeltaEpochs, if the optional element, validityPeriod is not included, the
-- value in GANSSEphemerisExtensionHeader shall be used.  If the optional elements 
-- ephemerisDeltaSizes or ephemerisDeltaScales are not included, then the default ephemeris delta
-- sizes and scales shall be used.  The default sizes and scales are found in the annex in the 
-- table 55.11.

GANSSDeltaElementList ::= SEQUENCE (SIZE(1 .. 32)) OF OCTET STRING(SIZE (1..49))
-- Each octet string element in GANSSDeltaElementList corresponds to one PRN within one epoch

-- Table 55.11 of the annex shows the organization of the delta ephemeris octet string.
-- Decoding of each of the octet strings is accomplished by consulting the ephemerisDeltaSizes
-- table to learn the length and order of each of the parameters in the ephemerisDelta payload.

-- Post decode scaling is accomplished by consulting the ephemerisDeltaScales table to learn the
-- scale factors to apply to the terms in the delta ephemeris.

-- Ephemeris Delta Bit Sizes.

GANSSEphemerisDeltaBitSizes ::= SEQUENCE {

-- This structure defines the order and sizes of the fields in the GANSSDeltaEpoch octet string 
-- seqNum and svID are the first two elements of each GANSS Ephemeris Delta Element Structure
-- seqNum is always 7 bits, and svID is always 6 bits long and are thus not included in
-- the GANSSEphemerisDeltaBitSizes table.  The value of seqNum indicates the GANSSDeltaEpoch number

-- The Ephemeris delta element payload mimics the bitsize table, but also includes the svID and 
-- seqNum as the first two elements (in that order),in each block.

	bitsize-delta-omega			INTEGER(1..32),
	bitsize-delta-deltaN		INTEGER(1..16),
	bitsize-delta-m0			INTEGER(1..32),
	bitsize-delta-omegadot		INTEGER(1..24),
	bitsize-delta-e				INTEGER(1..32),
	bitsize-delta-idot			INTEGER(1..14),
	bitsize-delta-sqrtA			INTEGER(1..32),
	bitsize-delta-i0			INTEGER(1..32),
	bitsize-delta-omega0		INTEGER(1..32),
	bitsize-delta-crs			INTEGER(1..16),
	bitsize-delta-cis			INTEGER(1..16),
	bitsize-delta-cus			INTEGER(1..16),
	bitsize-delta-crc			INTEGER(1..16),
	bitsize-delta-cic			INTEGER(1..16),
	bitsize-delta-cuc			INTEGER(1..16),
	bitsize-delta-tgd1			INTEGER(1..10),
	bitsize-delta-tgd2			INTEGER(1..10),
...
}

GANSSEphemerisDeltaScales ::= SEQUENCE {

	scale-delta-omega			INTEGER(-16..15),
	scale-delta-deltaN			INTEGER(-16..15),
	scale-delta-m0				INTEGER(-16..15),
	scale-delta-omegadot		INTEGER(-16..15),
	scale-delta-e				INTEGER(-16..15),
	scale-delta-idot			INTEGER(-16..15),
	scale-delta-sqrtA			INTEGER(-16..15),
	scale-delta-i0				INTEGER(-16..15),
	scale-delta-omega0			INTEGER(-16..15),
	scale-delta-crs				INTEGER(-16..15),
	scale-delta-cis				INTEGER(-16..15),
	scale-delta-cus				INTEGER(-16..15),
	scale-delta-crc				INTEGER(-16..15),
	scale-delta-cic				INTEGER(-16..15),
	scale-delta-cuc				INTEGER(-16..15),
	scale-delta-tgd1			INTEGER(-16..15),
	scale-delta-tgd2			INTEGER(-16..15),
...
}

-- GANSS Ephemeris Extension Check
GANSSEphemerisExtensionCheck ::= SEQUENCE {
	ganssBeginTime			GANSSEphemerisExtensionTime,
	ganssEndTime			GANSSEphemerisExtensionTime,
	ganssSatEventsInfo		GANSSSatEventsInfo,
...
}

GANSSSatEventsInfo ::= SEQUENCE {
	eventOccured		BIT STRING (SIZE (64)),
	futureEventNoted	BIT STRING (SIZE (64)),
...
}
-- If a bit is clear in the eventOccured field it indicates that no known errors have occured
-- between the current time and the ganssBeginTime nor is a maneuver planned for the next sixty
-- minutes.
-- If a bit is set in the futureEventNoted field it indicates that a maneuver is planned during the
-- time period between current time plus sixty minutes and the ganssEndTime
-- GANSS Additional Universal Time Coordinate Model
GANSSAddUTCModel ::= CHOICE {
	utcModel2			UTCmodelSet2,
	utcModel3			UTCmodelSet3,
	utcModel4			UTCmodelSet4,
	...
}

UTCmodelSet2 ::= SEQUENCE {
	utcA0				INTEGER (-32768..32767),
	utcA1				INTEGER (-4096.. 4095),
	utcA2				INTEGER (-64..63),
	utcDeltaTls			INTEGER (-128.. 127),
	utcTot				INTEGER (0..65535),
	utcWNot				INTEGER (0..8191),
	utcWNlsf			INTEGER (0..255),
	utcDN				BIT STRING (SIZE(4)),
	utcDeltaTlsf		INTEGER (-128..127)
}

UTCmodelSet3 ::= SEQUENCE {
	nA					INTEGER (1..1461),
	tauC				INTEGER (-2147483648..2147483647),
	b1					INTEGER (-1024..1023) 					OPTIONAL,
	b2					INTEGER (-512..511) 					OPTIONAL,
	kp					BIT STRING (SIZE(2)) 					OPTIONAL
}

UTCmodelSet4 ::= SEQUENCE {
	utcA1wnt			INTEGER (-8388608..8388607),
	utcA0wnt			INTEGER (-2147483648..2147483647),
	utcTot				INTEGER (0..255),
	utcWNt				INTEGER (0..255),
	utcDeltaTls			INTEGER (-128..127),
	utcWNlsf			INTEGER (0..255),
	utcDN				INTEGER (-128..127),
	utcDeltaTlsf		INTEGER (-128..127),
	utcStandardID		INTEGER (0..7) 			-- coding according to annex
}

-- GANSS Auxiliary Information
GANSSAuxiliaryInformation ::= CHOICE{
	ganssID1	GANSS-ID1, 	-- This choice may only be present if GANSS ID indicates Modernized GPS
	ganssID3	GANSS-ID3, 	-- This choice may only be present if GANSS ID indicates GLONASS
	...
}

GANSS-ID1 ::= SEQUENCE (SIZE(1..64)) OF GANSS-ID1-element

GANSS-ID1-element ::= SEQUENCE {
	svID				SVID,
	signalsAvailable	GANSSSignals,
	...
}

GANSS-ID3 ::= SEQUENCE (SIZE(1..64)) OF GANSS-ID3-element

GANSS-ID3-element  ::= SEQUENCE {
	svID				SVID,
	signalsAvailable	GANSSSignals,
	channelNumber		INTEGER (-7..13),
	...
}

-- DGANSS Corrections Validity Period:
-- This element may only be included if GANSSDiffCorrections IE is included in 
-- GANSSGenericAssistDataElement element.
-- GANSSDiffCorrectionsValidityPeriod shall contain the same number of elements as the 
-- SeqOfSgnTypeElement included in GANSSDiffCorrections IE
GANSSDiffCorrectionsValidityPeriod ::= SEQUENCE (SIZE (1..3)) OF DGANSSExtensionSgnTypeElement

DGANSSExtensionSgnTypeElement ::= SEQUENCE {
	ganssSignalID		 		GANSSSignalID, -- signal type identity
	dganssExtensionSgnList		SeqOfDGANSSExtensionSgnElement
}

-- SeqOfDGANSSExtensionSgnElement shall contain the same number of elements as the 
-- SeqOfDGANSSSgnElement included in GANSSDiffCorrections IE
SeqOfDGANSSExtensionSgnElement ::= SEQUENCE (SIZE (1..16)) OF DGANSSExtensionSgnElement

DGANSSExtensionSgnElement ::= SEQUENCE {
	svID				SVID, 			-- Satellite identity
	udreGrowthRate		INTEGER(0..7), 	-- coding according to annex
	udreValidityTime	INTEGER(0..7), 	-- coding according to annex
	...
}

--Required Measurement Request Response Time, range is 1 to 128 seconds. 
RequiredResponseTime ::= INTEGER  (1..128)

-- Control header for additional GPS assistance data
Add-GPS-AssistData ::= SEQUENCE {
	add-GPS-controlHeader	Add-GPS-ControlHeader
}

Add-GPS-ControlHeader ::= SEQUENCE {
	gpsEphemerisExtension			GPSEphemerisExtension			OPTIONAL,
	gpsEphemerisExtensionCheck		GPSEphemerisExtensionCheck		OPTIONAL,
	... ,
	dgpsCorrectionsValidityPeriod	DGPSCorrectionsValidityPeriod	OPTIONAL
}

GPSClockModel ::= SEQUENCE {
	af2		INTEGER (-128..127),
	af1		INTEGER (-32768..32767),
	af0		INTEGER (-2097152..2097151),
	tgd		INTEGER (-128..127)
}

--GPS Ephemeris Extension
GPSEphemerisExtension ::= SEQUENCE {
	gpsEphemerisHeader			GPSEphemerisExtensionHeader				OPTIONAL,
	gpsReferenceSet				SeqOfGPSRefOrbit						OPTIONAL,
	gpsephemerisDeltaMatrix		GPSEphemerisDeltaMatrix					OPTIONAL,
...
}

-- The gpsEphemerisHeader and the gpsReferenceSet are mandatory only once in the delivery of the
-- GPS Ephemeris Extension.  The gpsReferenceSet shall include all healthy satellite vehicles at the
-- time of message construction

-- The SMLC is required to deliver the gpsReferenceSet for all healthy satellite vehicles
-- at the time of message construction.

GPSEphemerisExtensionHeader ::= SEQUENCE {
	timeofEstimation			GPSEphemerisExtensionTime,
	validityPeriod				INTEGER(1..8),
-- The validity period, represented in hours is the validity period of each individual ephemeris 
-- delta payload
	ephemerisExtensionDuration	INTEGER(1..512),
-- If the ephemerisExtensionDuration does not match the request duration made by the MS, the MS
-- should regard the provided ephemerisExtensionDuration as the limit of the SMLC ephemeris
-- extension capability at this time.
...
}

GPSEphemerisExtensionTime ::= SEQUENCE {
	gpsWeek				GPSWeek,
	gpsTOW				INTEGER (0..604799),
...
}

SeqOfGPSRefOrbit ::= SEQUENCE (SIZE(1..32)) OF GPSReferenceOrbit
--The number of reference orbits can be read from number of elements in this sequence

GPSReferenceOrbit ::= SEQUENCE {
	svID				SVID,
	gpsOrbitModel		ReferenceNavModel,
	gpsClockModel		GPSClockModel,
...
}

GPSEphemerisDeltaMatrix ::= SEQUENCE (SIZE(1 .. 128)) OF GPSEphemerisDeltaEpoch

GPSEphemerisDeltaEpoch ::= SEQUENCE {
	gpsDeltaEpochHeader		GPSDeltaEpochHeader				OPTIONAL,
	gpsDeltaElementList		GPSDeltaElementList,
...
}

-- Each GPSDeltaEpoch element contains a header and the delta values for a particular time window 
-- for all PRN's.
GPSDeltaEpochHeader ::= SEQUENCE {
	validityPeriod				INTEGER(1..8)				OPTIONAL,
	ephemerisDeltaSizes			GPSEphemerisDeltaBitSizes	OPTIONAL,
	ephemerisDeltaScales		GPSEphemerisDeltaScales	OPTIONAL,
...
}

-- In each of the GPSDeltaEpochs, if the optional element validityPeriod is not included,
-- the value in GPSEphemerisExtensionHeader shall be used.  if the optional elements 
-- ephemerisDeltaSizes or ephemerisDeltaScales are not included, then the default ephemeris delta
-- sizes and scales shall be used.  The default sizes and scales are found in the annex in section
-- A.29.m

GPSDeltaElementList ::= SEQUENCE (SIZE(1 .. 32)) OF OCTET STRING(SIZE (1..47))

-- Each octet string element in GPSDeltaElementList corresponds to one PRN within one epoch

-- Table A.29.m of the annex shows the organization of the delta ephemeris octet string.
-- Decoding of each of the octet strings is accomplished by consulting the ephemerisDeltaSizes
-- table to learn the length and order of each of the parameters in the ephemerisDelta payload

-- Post decode scaling is accomplished by consulting the ephemerisDeltaScales table to learn the.
-- scale factors to apply to the terms in the delta ephemeris

-- Ephemeris Delta Bit Sizes. 

GPSEphemerisDeltaBitSizes ::= SEQUENCE {

-- This structure defines the order and sizes of the fields in the GPSsDeltaEpoch octet string
-- seqNum and svID are the first two elements of each GPS Ephemeris Delta Element Structure
-- seqNum is always 7 bits, and svID is always 5 bits long and are thus not included in
-- the GPSEphemerisDeltaBitSizes table. seqNum indicates the GPSDeltaEpoch number.

-- The Ephemeris delta element payload mimics the bitsize table, but also includes the svID and
-- seqNum as the first two elements (in that order),in each block.

	bitsize-delta-omega			INTEGER(1..32),
	bitsize-delta-deltaN		INTEGER(1..16),
	bitsize-delta-m0			INTEGER(1..32),
	bitsize-delta-omegadot		INTEGER(1..24),
	bitsize-delta-e				INTEGER(1..32),
	bitsize-delta-idot			INTEGER(1..14),
	bitsize-delta-sqrtA			INTEGER(1..32),
	bitsize-delta-i0			INTEGER(1..32),
	bitsize-delta-omega0		INTEGER(1..32),
	bitsize-delta-crs			INTEGER(1..16),
	bitsize-delta-cis			INTEGER(1..16),
	bitsize-delta-cus			INTEGER(1..16),
	bitsize-delta-crc			INTEGER(1..16),
	bitsize-delta-cic			INTEGER(1..16),
	bitsize-delta-cuc			INTEGER(1..16),
	bitsize-delta-tgd			INTEGER(1..10),
...
}

GPSEphemerisDeltaScales ::= SEQUENCE {
	scale-delta-omega			INTEGER(-16..15),
	scale-delta-deltaN			INTEGER(-16..15),
	scale-delta-m0				INTEGER(-16..15),
	scale-delta-omegadot		INTEGER(-16..15),
	scale-delta-e				INTEGER(-16..15),
	scale-delta-idot			INTEGER(-16..15),
	scale-delta-sqrtA			INTEGER(-16..15),
	scale-delta-i0				INTEGER(-16..15),
	scale-delta-omega0			INTEGER(-16..15),
	scale-delta-crs				INTEGER(-16..15),
	scale-delta-cis				INTEGER(-16..15),
	scale-delta-cus				INTEGER(-16..15),
	scale-delta-crc				INTEGER(-16..15),
	scale-delta-cic				INTEGER(-16..15),
	scale-delta-cuc				INTEGER(-16..15),
	scale-delta-tgd				INTEGER(-16..15),
...
}

GPSEphemerisExtensionCheck ::= SEQUENCE {
	gpsBeginTime			GPSEphemerisExtensionTime,
	gpsEndTime				GPSEphemerisExtensionTime,
	gpsSatEventsInfo		GPSSatEventsInfo,
...
}

GPSSatEventsInfo ::= SEQUENCE {
	eventOccured		BIT STRING (SIZE (32)),
	futureEventNoted	BIT STRING (SIZE (32)),
...
}
-- If a bit is clear in the eventOccured field it indicates that no known errors have occured since 
-- the gpsBeginTime nor is a maneuver planned for the next sixty minutes.
-- If a bit is set in the futureEventNoted field it indicates that a maneuver is planned during the
-- time period between current time plus sixty minutes and gpsEndTime

-- DGPS Corrections Validity Period:
-- This element may only be included if DGPSCorrections IE is included in ControlHeader element.
-- DGPSCorrectionsValidityPeriod shall contain the same number of elements as the SeqOfSatElement
-- included in DGPSCorrections IE
DGPSCorrectionsValidityPeriod ::= SEQUENCE (SIZE (1..16)) OF DGPSExtensionSatElement

DGPSExtensionSatElement ::= SEQUENCE {
	satelliteID			SatelliteID,
	udreGrowthRate		INTEGER(0..7), 	-- coding according to annex
	udreValidityTime	INTEGER(0..7), 	-- coding according to annex
	...
}

Rel-7-MsrPosition-Rsp-Extension ::= SEQUENCE {

	velEstimate 	VelocityEstimate OPTIONAL,
 -- Horizontal Velocity
 -- Horizontal with Vertical Velocity
 -- Horizontal Velocity with Uncertainty
 -- Horizontal with Vertical Velocity and Uncertainty
 ganssLocationInfo GANSSLocationInfo OPTIONAL,
 ganssMeasureInfo GANSSMeasureInfo OPTIONAL,
	...
-- Further Release 7 extensions here
}

-- GANSS Location Information contains location estimate, time stamp with uncertainty 
-- and optionally Reference Frame field
GANSSLocationInfo ::= SEQUENCE {
 	referenceFrame 				ReferenceFrame 			OPTIONAL, -- Reference Frame Number
 	ganssTODm 					GANSSTODm 				OPTIONAL, -- GNSS TOD modulo
 	ganssTODFrac 				INTEGER (0 .. 16384) 	OPTIONAL, -- Coding according to Annex
	-- a value of 16384 shall not be encoded by the sender
	-- the receiver shall consider a value of 16384 to be invalid data
	ganssTODUncertainty 		GANSSTODUncertainty 	OPTIONAL, -- Coding according to Annex
 	ganssTimeID 				INTEGER (0 .. 7) 		OPTIONAL, -- Coding according to Annex
	fixType			 			FixType,
 	posData 					PositionData,
 	stationaryIndication 		INTEGER(0 .. 1) 		OPTIONAL, -- '0' if moving or motion not
																  -- known 
	-- Possible shapes carried in posEstimate are
	-- ellipsoid point,
	-- ellipsoid point with uncertainty circle
	-- ellipsoid point with uncertainty ellipse
	-- ellipsoid point with altitude and uncertainty ellipsoid
	posEstimate		 			Ext-GeographicalInformation,
 	...
}

PositionData ::= BIT STRING {
 	e-otd	 	 	 (0),
	gps 	 	 	 (1),
	galileo 	 	 (2),
	sbas 	 	 	 (3),
	modernizedGPS 	 (4),
	qzss 	 	 	 (5),
	glonass 	 	 (6) } (SIZE (3..16))

-- GANSS TOD modulo 1 hour
GANSSTODm ::= INTEGER (0 .. 3599999)

ReferenceFrame ::= SEQUENCE {
 referenceFN INTEGER (0 .. 65535),
	-- Note that applicable range for referenceFN is 0 - 42431
 referenceFNMSB INTEGER (0 .. 63) OPTIONAL -- MSB of Reference Frame Number
}

-- GANSS Measurement Information 
GANSSMeasureInfo ::= SEQUENCE {
	-- Measurement info elements
ganssMsrSetList SeqOfGANSS-MsrSetElement
}
SeqOfGANSS-MsrSetElement ::= SEQUENCE (SIZE(1..3)) OF GANSS-MsrSetElement

-- GANSS measurement information 1-3 times in a message
GANSS-MsrSetElement ::= SEQUENCE {
	referenceFrame 			ReferenceFrame 		OPTIONAL, -- Reference Frame Number
	-- if ganssTODm is included, it is the GNSS specific system time of the GANSS reported
	-- first in ganss-SgnTypeList. If GPS Measurement Information element is not included in
	-- a Measure Position Response component, this field shall be present.
	ganssTODm 				GANSSTODm 			OPTIONAL, -- GANSS TOD modulo 1 hour
	deltaGANSSTOD 			INTEGER (0 .. 127) 	OPTIONAL,
	ganssTODUncertainty 	GANSSTODUncertainty	OPTIONAL, -- Coding according to Annex
	--N_GANSS can be read from number of elements of SeqOfGANSS-MsrElement
	ganss-MsrElementList	SeqOfGANSS-MsrElement 
}

SeqOfGANSS-MsrElement ::= SEQUENCE (SIZE(1..8)) OF GANSS-MsrElement

GANSS-MsrElement ::= SEQUENCE {
	ganssID		INTEGER (0..7) 	OPTIONAL, --Absence means Galileo
	ganss-SgnTypeList 		SeqOfGANSS-SgnTypeElement
}

-- Measurements can be returned up to 8 different signal types
-- N_SGN_TYPE can be read from number of elements of SeqOfGANSS-SgnTypeElement 
-- Reporting of multiple signal types as defined in A.2.2.4g  
SeqOfGANSS-SgnTypeElement ::= SEQUENCE (SIZE(1..8)) OF GANSS-SgnTypeElement

GANSS-SgnTypeElement ::= SEQUENCE {
	ganssSignalID			GANSSSignalID, -- Coding according to Annex
	ganssCodePhaseAmbiguity	INTEGER (0 .. 127)				OPTIONAL,
 	--N_SGN can be read from number of elements of SeqOfGANSS-SgnElement
 	ganss-SgnList SeqOfGANSS-SgnElement,
 	...
}

-- Up to 16 Measurements can be returned per signal type 
SeqOfGANSS-SgnElement ::= SEQUENCE (SIZE(1..16)) OF GANSS-SgnElement


GANSS-SgnElement ::= SEQUENCE {
 	svID 				SVID,
	cNo 				INTEGER (0 .. 63),
	mpathDet 			MpathIndic, 								 -- Coding according to Annex
	carrierQualityInd 	INTEGER (0 .. 3) 			OPTIONAL, 	 -- Coding according to Annex
	codePhase 			INTEGER (0 .. 2097151),
	integerCodePhase 	INTEGER (0 .. 127) 			OPTIONAL,
	codePhaseRMSError 	INTEGER (0..63), 						 -- Coding according to Annex
	doppler 			INTEGER (-32768 .. 32767) 	OPTIONAL,
	adr 				INTEGER (0 .. 33554431) 	OPTIONAL
}

Rel7-AssistanceData-Extension ::= SEQUENCE {
	ganss-AssistData								GANSS-AssistData	OPTIONAL,
	ganssCarrierPhaseMeasurementRequest				NULL				OPTIONAL,
	ganssTODGSMTimeAssociationMeasurementRequest	NULL				OPTIONAL,
	 add-GPS-AssistData								Add-GPS-AssistData	OPTIONAL,
	...
-- Possibly more extensions for Release 7 here
}

-- Rel-7 Positioning Capability parameters here

PosCapabilities ::= SEQUENCE {

-- nonGANSSpositionMethods shall be included if and only if any 
-- of the non-GANSS methods is supported.
	nonGANSSpositionMethods		NonGANSSPositionMethods	OPTIONAL,

-- gANSSpositionMethods shall be included if and only if any of the GANSS methods is supported.
	gANSSPositionMethods		GANSSPositionMethods	OPTIONAL,

-- multipleMeasurementSets shall be present if and only if 'multiple sets' is supported 
-- for any of the positioning methods
	multipleMeasurementSets		MultipleMeasurementSets	OPTIONAL,
	...
}

NonGANSSPositionMethods ::= BIT STRING {
	msAssistedEOTD	 (0),
	msBasedEOTD	 	 (1),
	msAssistedGPS	 (2), -- If this bit is set, gpsAssistance in AssistanceSupported IE
						  -- shall be present
	msBasedGPS	 	 (3), -- If this bit is set, gpsAssistance in AssistanceSupported IE
						  -- shall be present

	standaloneGPS	 (4) } (SIZE (1..16))

GANSSPositionMethods ::= SEQUENCE (SIZE(1..16)) OF GANSSPositionMethod

GANSSPositionMethod ::= SEQUENCE {
	ganssID 						INTEGER (0..7) 				OPTIONAL, --Absence means Galileo
-- gANSSPositioningMethodTypes may be present for PosCapability-Req
-- and shall be present for PosCapability-Rsp
	gANSSPositioningMethodTypes		GANSSPositioningMethodTypes OPTIONAL,
	gANSSSignals					GANSSSignals,
	... ,
-- sbasID shall be present if and only if ganssID indicates SBAS
	sbasID							SBASID						OPTIONAL
}

GANSSPositioningMethodTypes ::= BIT STRING {
	msAssisted	(0),	-- If this bit is set, gANSSAssistanceSet in AssistanceSupported IE 
						-- shall be present.
	msBased	 	(1),	-- If this bit is set, gANSSAssistanceSet in AssistanceSupported IE 
						-- shall be present.
	standalone	(2) } (SIZE (1..8))

-- indicates MS support for particular GANSS signals and frequencies
GANSSSignals ::= BIT STRING {
	signal1 (0),
	signal2 (1),
	signal3 (2),
	signal4 (3),
	signal5 (4),
	signal6 (5),
	signal7 (6),
	signal8 (7) } (SIZE (1..8))

SBASID ::= BIT STRING {
	waas 	 (0),
	egnos 	 (1),
	masas 	 (2),
	gagan 	 (3) } (SIZE (1..8))

-- indicates MS support of multiple measurement sets for MS assisted position methods
MultipleMeasurementSets ::= BIT STRING {
	eotd	 (0),
	gps	 	 (1),
	ganss	 (2) } (SIZE (1..8))

-- indicates MS support of different types of assistance data
AssistanceSupported ::= SEQUENCE {
	gpsAssistance						GPSAssistance						OPTIONAL,
	gANSSAssistanceSet					GANSSAssistanceSet					OPTIONAL,
	... ,
-- gANSSAdditionalAssistanceChoices shall be present if the MS supports other than native models
	gANSSAdditionalAssistanceChoices	GANSSAdditionalAssistanceChoices	OPTIONAL
}

-- GPS assistance data supported
GPSAssistance ::= BIT STRING {
	almanac					(0),
	uTCmodel				(1),
	ionosphericModel		(2),
	navigationmodel			(3),
	dGPScorrections			(4),
	referenceLocation		(5),
	referenceTime			(6),
	acquisitionAssistance	(7),
	realTimeIntegrity		(8),
	ephemerisExtension		(9),
	ephemerisExtensionCheck	(10)} (SIZE (1..16))

-- GANSS assistance data supported
GANSSAssistanceSet ::= SEQUENCE {
	commonGANSSAssistance		CommonGANSSAssistance,
	specificGANSSAssistance		SpecificGANSSAssistance,
	...
}

-- Common GANSS assistance data supported
CommonGANSSAssistance ::= BIT STRING {
	referenceTime			 (0),
	referenceLocation		 (1),
	ionosphericModel		 (3),
	addIonosphericModel		 (4),
	earthOrientationParam	 (5)  } (SIZE (1..8))

SpecificGANSSAssistance ::= SEQUENCE (SIZE(1..16)) OF GANSSAssistanceForOneGANSS

-- assistance data supported for a particular GANSS system
GANSSAssistanceForOneGANSS ::= SEQUENCE {
	ganssID					INTEGER (0..7) 	OPTIONAL, --Absence means Galileo
	gANSSAssistance			GANSSAssistance,
	...
}

-- specific GANSS assistance data supported
GANSSAssistance ::= BIT STRING {
	realTimeIntegrity				(0),
	differentialCorrections			(1),
	almanac							(2),
	referenceMeasurementInformation	(3),
	navigationModel					(4),
	timeModelGNSS-UTC				(5),
	timeModelGNSS-GNSS				(6),
	databitassistance				(7),
	ephemerisExtension				(8),
	ephemerisExtensionCheck			(9),
	addUTCmodel						(10),
	auxiliaryInformation			(11)  } (SIZE (1..16))


GANSSAdditionalAssistanceChoices ::= SEQUENCE (SIZE(1..16)) OF GANSSAdditionalAssistanceChoicesForOneGANSS

GANSSAdditionalAssistanceChoicesForOneGANSS ::= SEQUENCE {
	ganssID							INTEGER (0..7) 	OPTIONAL, --Absence means Galileo
	ganssClockModelChoice			GANSSModelID 	OPTIONAL,
	gannsOrbitModelChoice			GANSSModelID 	OPTIONAL,
	ganssAlmanacModelChoice			GANSSModelID 	OPTIONAL,
	ganssAdditionalUTCModelChoice	GANSSModelID 	OPTIONAL,
	...
}

GANSSModelID ::= BIT STRING {
	model1 (0),
	model2 (1),
	model3 (2),
	model4 (3),
	model5 (4),
	model6 (5),
	model7 (6),
	model8 (7) } (SIZE (1..8))


-- indicates assistance data that may be needed by the MS
-- These elements are coded as defined in TS 49.031 with the exceptions defined in section A.8.2.3
AssistanceNeeded ::= SEQUENCE {
	gpsAssistanceData		GPSAssistanceData		OPTIONAL,
	ganssAssistanceData		GANSSAssistanceData		OPTIONAL,
	...
}

END