MRTKLIB 0.7.14
Modernized GNSS Positioning Library
Loading...
Searching...
No Matches
mrtk_eph.c File Reference

MRTKLIB Broadcast Ephemeris Module — Kepler/GLONASS/SBAS orbit and clock computation functions. More...

#include "mrtklib/mrtk_eph.h"
#include <math.h>
#include "mrtklib/mrtk_mat.h"
#include "mrtklib/mrtk_nav.h"
#include "mrtklib/mrtk_trace.h"
Include dependency graph for mrtk_eph.c:

Go to the source code of this file.

Macros

#define PI   3.1415926535897932 /* pi */
#define CLIGHT   299792458.0 /* speed of light (m/s) */
#define OMGE   7.2921151467E-5 /* earth angular velocity (IS-GPS) (rad/s) */
#define SQR(x)
#define RE_GLO   6378136.0 /* radius of earth (m) ref [2] */
#define MU_GPS   3.9860050E14 /* gravitational constant ref [1] */
#define MU_GLO   3.9860044E14 /* gravitational constant ref [2] */
#define MU_GAL   3.986004418E14 /* earth gravitational constant ref [7] */
#define MU_CMP   3.986004418E14 /* earth gravitational constant ref [9] */
#define J2_GLO   1.0826257E-3 /* 2nd zonal harmonic of geopot ref [2] */
#define OMGE_GLO   7.292115E-5 /* earth angular velocity (rad/s) ref [2] */
#define OMGE_GAL   7.2921151467E-5 /* earth angular velocity (rad/s) ref [7] */
#define OMGE_CMP   7.292115E-5 /* earth angular velocity (rad/s) ref [9] */
#define SIN_5   -0.0871557427476582 /* sin(-5.0 deg) */
#define COS_5   0.9961946980917456 /* cos(-5.0 deg) */
#define ERREPH_GLO   5.0 /* error of glonass ephemeris (m) */
#define TSTEP   60.0 /* integration step glonass ephemeris (s) */
#define RTOL_KEPLER   1E-13 /* relative tolerance for Kepler equation */
#define MAX_ITER_KEPLER   30 /* max number of iteration of Kelpler */
#define STD_GAL_NAPA   500.0 /* error of galileo ephemeris for NAPA (m) */
#define SYS_NONE   0x00
#define SYS_GPS   0x01
#define SYS_SBS   0x02
#define SYS_GLO   0x04
#define SYS_GAL   0x08
#define SYS_QZS   0x10
#define SYS_CMP   0x20
#define SYS_IRN   0x40
#define MAXDTOE   7200.0 /* max time diff to GPS Toe (s) */
#define MAXDTOE_QZS   7200.0 /* max time diff to QZSS Toe (s) */
#define MAXDTOE_GAL   14400.0 /* max time diff to Galileo Toe (s) */
#define MAXDTOE_CMP   21600.0 /* max time diff to BeiDou Toe (s) */
#define MAXDTOE_GLO   1800.0 /* max time diff to GLONASS Toe (s) */
#define MAXDTOE_IRN   7200.0 /* max time diff to IRNSS Toe (s) */
#define MAXDTOE_SBS   360.0 /* max time diff to SBAS Toe (s) */
#define EPHOPT_BRDC   0 /* broadcast ephemeris */
#define EPHOPT_PREC   1 /* precise ephemeris */
#define EPHOPT_SBAS   2 /* broadcast + SBAS */
#define EPHOPT_SSRAPC   3 /* broadcast + SSR_APC */
#define EPHOPT_SSRCOM   4 /* broadcast + SSR_COM */
#define DEFURASSR   0.15 /* default accuracy of ssr corr (m) */
#define MAXECORSSR   10.0 /* max orbit correction of ssr (m) */
#define MAXCCORSSR   (1E-6 * CLIGHT) /* max clock correction of ssr (m) */
#define MAXAGESSR   60.0 /* max age of ssr orbit and clock (s) */
#define MAXAGESSR_HRCLK   10.0 /* max age of ssr high-rate clock (s) */
#define STD_BRDCCLK   30.0 /* error of broadcast clock (m) */

Functions

int satsys (int sat, int *prn)
int sbssatcorr (gtime_t time, int sat, const nav_t *nav, double *rs, double *dts, double *var)
static double var_uraeph (int sys, int ura)
static void deq (const double *x, double *xdot, const double *acc)
static void glorbit (double t, double *x, const double *acc)
void alm2pos (gtime_t time, const alm_t *alm, double *rs, double *dts)
 Compute satellite position and clock bias with almanac.
double eph2clk (gtime_t time, const eph_t *eph)
 Compute satellite clock bias with broadcast ephemeris (GPS/GAL/QZS).
void eph2pos (gtime_t time, const eph_t *eph, double *rs, double *dts, double *var)
 Compute satellite position and clock with broadcast ephemeris (GPS/GAL/QZS/BDS/IRN).
double geph2clk (gtime_t time, const geph_t *geph)
 Compute satellite clock bias with GLONASS ephemeris.
void geph2pos (gtime_t time, const geph_t *geph, double *rs, double *dts, double *var)
 Compute satellite position and clock with GLONASS ephemeris.
double seph2clk (gtime_t time, const seph_t *seph)
 Compute satellite clock bias with SBAS ephemeris.
void seph2pos (gtime_t time, const seph_t *seph, double *rs, double *dts, double *var)
 Compute satellite position and clock with SBAS ephemeris.
static double var_urassr (int ura)
eph_t * seleph (gtime_t time, int sat, int iode, const nav_t *nav)
 Select broadcast ephemeris by satellite and IODE.
static geph_t * selgeph (gtime_t time, int sat, int iode, const nav_t *nav)
static seph_t * selseph (gtime_t time, int sat, const nav_t *nav)
static int ephclk (gtime_t time, gtime_t teph, int sat, const nav_t *nav, double *dts)
int ephpos (gtime_t time, gtime_t teph, int sat, const nav_t *nav, int iode, double *rs, double *dts, double *var, int *svh)
 Satellite position and clock by broadcast ephemeris.
static int satpos_sbas (gtime_t time, gtime_t teph, int sat, const nav_t *nav, double *rs, double *dts, double *var, int *svh)
void set_ssr_ch_idx (int ch)
 Set SSR channel index for satpos_ssr() (multi-L6E).
int get_ssr_ch_idx (void)
 Get current SSR channel index.
static int satpos_ssr (gtime_t time, gtime_t teph, int sat, const nav_t *nav, int opt, double *rs, double *dts, double *var, int *svh)
int satpos (gtime_t time, gtime_t teph, int sat, int ephopt, const nav_t *nav, double *rs, double *dts, double *var, int *svh)
 Compute satellite position, velocity and clock.
void satposs (gtime_t teph, const obsd_t *obs, int n, const nav_t *nav, int ephopt, double *rs, double *dts, double *var, int *svh)
 Compute satellite positions, velocities and clocks.
void setseleph (int sys, int sel)
 Set selected satellite ephemeris for multiple ones.
int getseleph (int sys)
 Get selected satellite ephemeris.

Variables

static int eph_sel []
static int _ssr_ch_idx = 0

Detailed Description

MRTKLIB Broadcast Ephemeris Module — Kepler/GLONASS/SBAS orbit and clock computation functions.

This file contains all broadcast ephemeris orbit/clock computation functions extracted from ephemeris.c with zero algorithmic changes (pure cut-and-paste).

Definition in file mrtk_eph.c.

Macro Definition Documentation

◆ CLIGHT

#define CLIGHT   299792458.0 /* speed of light (m/s) */

Definition at line 37 of file mrtk_eph.c.

◆ COS_5

#define COS_5   0.9961946980917456 /* cos(-5.0 deg) */

Definition at line 54 of file mrtk_eph.c.

Referenced by eph2pos().

◆ DEFURASSR

#define DEFURASSR   0.15 /* default accuracy of ssr corr (m) */

Definition at line 90 of file mrtk_eph.c.

Referenced by var_urassr().

◆ EPHOPT_BRDC

#define EPHOPT_BRDC   0 /* broadcast ephemeris */

Definition at line 83 of file mrtk_eph.c.

Referenced by rtkpos(), and satpos().

◆ EPHOPT_PREC

#define EPHOPT_PREC   1 /* precise ephemeris */

Definition at line 84 of file mrtk_eph.c.

Referenced by resolve_correction(), satpos(), and udclk_ppp().

◆ EPHOPT_SBAS

#define EPHOPT_SBAS   2 /* broadcast + SBAS */

Definition at line 85 of file mrtk_eph.c.

Referenced by estpos(), and satpos().

◆ EPHOPT_SSRAPC

#define EPHOPT_SSRAPC   3 /* broadcast + SSR_APC */

Definition at line 86 of file mrtk_eph.c.

Referenced by clas_ssr2osr(), detslp_ssr(), resolve_correction(), and satpos().

◆ EPHOPT_SSRCOM

#define EPHOPT_SSRCOM   4 /* broadcast + SSR_COM */

Definition at line 87 of file mrtk_eph.c.

Referenced by detslp_ssr(), resolve_correction(), and satpos().

◆ ERREPH_GLO

#define ERREPH_GLO   5.0 /* error of glonass ephemeris (m) */

Definition at line 56 of file mrtk_eph.c.

Referenced by geph2pos().

◆ J2_GLO

#define J2_GLO   1.0826257E-3 /* 2nd zonal harmonic of geopot ref [2] */

Definition at line 47 of file mrtk_eph.c.

Referenced by deq().

◆ MAX_ITER_KEPLER

#define MAX_ITER_KEPLER   30 /* max number of iteration of Kelpler */

Definition at line 59 of file mrtk_eph.c.

Referenced by alm2pos(), and eph2pos().

◆ MAXAGESSR

#define MAXAGESSR   60.0 /* max age of ssr orbit and clock (s) */

Definition at line 93 of file mrtk_eph.c.

Referenced by satpos_ssr().

◆ MAXAGESSR_HRCLK

#define MAXAGESSR_HRCLK   10.0 /* max age of ssr high-rate clock (s) */

Definition at line 94 of file mrtk_eph.c.

Referenced by satpos_ssr().

◆ MAXCCORSSR

#define MAXCCORSSR   (1E-6 * CLIGHT) /* max clock correction of ssr (m) */

Definition at line 92 of file mrtk_eph.c.

Referenced by satpos_ssr().

◆ MAXDTOE

#define MAXDTOE   7200.0 /* max time diff to GPS Toe (s) */

Definition at line 74 of file mrtk_eph.c.

Referenced by convnav(), and seleph().

◆ MAXDTOE_CMP

#define MAXDTOE_CMP   21600.0 /* max time diff to BeiDou Toe (s) */

Definition at line 77 of file mrtk_eph.c.

Referenced by convnav(), and seleph().

◆ MAXDTOE_GAL

#define MAXDTOE_GAL   14400.0 /* max time diff to Galileo Toe (s) */

Definition at line 76 of file mrtk_eph.c.

Referenced by convnav(), and seleph().

◆ MAXDTOE_GLO

#define MAXDTOE_GLO   1800.0 /* max time diff to GLONASS Toe (s) */

Definition at line 78 of file mrtk_eph.c.

Referenced by convnav(), and selgeph().

◆ MAXDTOE_IRN

#define MAXDTOE_IRN   7200.0 /* max time diff to IRNSS Toe (s) */

Definition at line 79 of file mrtk_eph.c.

Referenced by convnav(), and seleph().

◆ MAXDTOE_QZS

#define MAXDTOE_QZS   7200.0 /* max time diff to QZSS Toe (s) */

Definition at line 75 of file mrtk_eph.c.

Referenced by convnav(), and seleph().

◆ MAXDTOE_SBS

#define MAXDTOE_SBS   360.0 /* max time diff to SBAS Toe (s) */

Definition at line 80 of file mrtk_eph.c.

Referenced by convnav(), and selseph().

◆ MAXECORSSR

#define MAXECORSSR   10.0 /* max orbit correction of ssr (m) */

Definition at line 91 of file mrtk_eph.c.

Referenced by satpos_ssr().

◆ MU_CMP

#define MU_CMP   3.986004418E14 /* earth gravitational constant ref [9] */

Definition at line 46 of file mrtk_eph.c.

Referenced by eph2pos().

◆ MU_GAL

#define MU_GAL   3.986004418E14 /* earth gravitational constant ref [7] */

Definition at line 45 of file mrtk_eph.c.

Referenced by alm2pos(), and eph2pos().

◆ MU_GLO

#define MU_GLO   3.9860044E14 /* gravitational constant ref [2] */

Definition at line 44 of file mrtk_eph.c.

Referenced by deq().

◆ MU_GPS

#define MU_GPS   3.9860050E14 /* gravitational constant ref [1] */

Definition at line 43 of file mrtk_eph.c.

Referenced by alm2pos(), and eph2pos().

◆ OMGE

#define OMGE   7.2921151467E-5 /* earth angular velocity (IS-GPS) (rad/s) */

Definition at line 38 of file mrtk_eph.c.

◆ OMGE_CMP

#define OMGE_CMP   7.292115E-5 /* earth angular velocity (rad/s) ref [9] */

Definition at line 51 of file mrtk_eph.c.

Referenced by eph2pos().

◆ OMGE_GAL

#define OMGE_GAL   7.2921151467E-5 /* earth angular velocity (rad/s) ref [7] */

Definition at line 50 of file mrtk_eph.c.

Referenced by eph2pos().

◆ OMGE_GLO

#define OMGE_GLO   7.292115E-5 /* earth angular velocity (rad/s) ref [2] */

Definition at line 49 of file mrtk_eph.c.

Referenced by deq().

◆ PI

#define PI   3.1415926535897932 /* pi */

Definition at line 36 of file mrtk_eph.c.

◆ RE_GLO

#define RE_GLO   6378136.0 /* radius of earth (m) ref [2] */

Definition at line 42 of file mrtk_eph.c.

Referenced by deq().

◆ RTOL_KEPLER

#define RTOL_KEPLER   1E-13 /* relative tolerance for Kepler equation */

Definition at line 58 of file mrtk_eph.c.

Referenced by alm2pos(), and eph2pos().

◆ SIN_5

#define SIN_5   -0.0871557427476582 /* sin(-5.0 deg) */

Definition at line 53 of file mrtk_eph.c.

Referenced by eph2pos().

◆ SQR

#define SQR ( x)
Value:
((x) * (x))

Definition at line 40 of file mrtk_eph.c.

Referenced by deq(), eph2pos(), geph2pos(), satposs(), var_uraeph(), and var_urassr().

◆ STD_BRDCCLK

#define STD_BRDCCLK   30.0 /* error of broadcast clock (m) */

Definition at line 95 of file mrtk_eph.c.

Referenced by satposs().

◆ STD_GAL_NAPA

#define STD_GAL_NAPA   500.0 /* error of galileo ephemeris for NAPA (m) */

Definition at line 61 of file mrtk_eph.c.

Referenced by var_uraeph().

◆ SYS_CMP

#define SYS_CMP   0x20

Definition at line 70 of file mrtk_eph.c.

Referenced by apply_pppsig(), checkpri(), clas_osr_adjust_r_dts(), code2sys(), code2sys(), convcode(), convcode(), convnav(), convrnx(), cssr_gnss2sys(), cssr_sys2gnss(), decode_bdsephemerisb(), decode_bdsnav(), decode_bdsraw(), decode_bnx_01_05(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_CN(), decode_eph(), decode_eph(), decode_eph_bds_cnav(), decode_lcliono(), decode_msm_head(), decode_obsdata(), decode_obsh(), decode_rangeb(), decode_rangecmpb(), decode_rtcm3(), decode_rx(), decode_rxmrawx(), decode_rxmsfrbx(), decode_SI(), decode_ssr1(), decode_ssr2(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_stqbds(), decode_stqraw(), decode_stqrawx(), decode_track_stat(), decode_trkd5(), decode_trkmeas(), decode_trksfrbx(), decode_type1042(), decode_type4076(), DecodeBeidouEphemeris(), encode_lcliono(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1042(), encode_type4076(), encode_type63(), eph2pos(), ephclk(), ephpos(), exc_sat_par(), freq_num2ant_idx(), gen_sat_sd(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), gnssid2sys(), gnssid2sys(), is_bds3_igso(), mcssr_sel_biascode(), mcssr_sigcode(), mrtk_band_to_freq_num(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), nextsat(), obs_code_for_freq(), obs_code_for_freq_vrs(), obsindex(), out_iono(), out_leaps(), out_time(), outobstype_ver3(), outprcopts(), outrnx_phase_shift(), outrnxcnavh(), outrnxnavb(), outrnxnavh(), outrnxobsb(), outrnxobsh(), ppp_note_autosig(), ppp_res(), prange(), raw2rtcm(), readfcbf(), readrnxh(), readrnxobsb(), rescode(), rtcm2rtcm(), sat2code(), satexclude(), satid2no(), satno(), satno2id(), satpos_ssr(), satsys(), satsys_bd2(), save_msm_obs(), seleph(), set_bdsopt(), set_index(), set_sysmask(), setopt_phshift(), setseleph(), sig2code(), sig2idx(), sig2idx(), sigmask2sig(), svid2sat(), sys2isbidx(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_sigid(), ubx_sig(), ubx_sys(), update_states(), varerr(), varerr(), varerr(), and write_rtcm3_msm().

◆ SYS_GAL

#define SYS_GAL   0x08

Definition at line 68 of file mrtk_eph.c.

Referenced by alm2pos(), apply_claslib_ppprtk_obsdef(), apply_pppsig(), check_bit_width_combo(), check_bit_width_oc(), checkpri(), clas_osr_adjust_r_dts(), clas_osr_selfreqpair(), clas_osr_zdres(), code2sys(), code2sys(), const_iono_corr(), convcode(), convnav(), convrnx(), cssr_gnss2sys(), cssr_sys2gnss(), decode_bnx_01_04(), decode_bnx_01_14(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_cssr_combo(), decode_cssr_oc(), decode_EN(), decode_eph(), decode_eph(), decode_gal_fnav_eph(), decode_gal_inav_eph(), decode_galephemerisb(), decode_galinavephemerisb(), decode_galnav(), decode_galrawfnav(), decode_galrawinav(), decode_lcliono(), decode_obsdata(), decode_obsh(), decode_rtcm3(), decode_rx(), decode_rxmrawx(), decode_rxmsfrbx(), decode_SI(), decode_ssr1(), decode_ssr2(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_stqrawx(), decode_track_stat(), decode_trksfrbx(), decode_type1045(), decode_type1046(), decode_type4076(), DecodeGalileoEphemeris(), encode_lcliono(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1005(), encode_type1006(), encode_type1045(), encode_type1046(), encode_type4076(), eph2pos(), ephclk(), ephpos(), freq_num2ant_idx(), gen_sat_sd(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), gnssid2sys(), gnssid2sys(), has_code2lam(), has_gnssid2sys(), has_sel_biascode(), iflc_freq2_idx(), input_rnxctr(), mcssr_sel_biascode(), mrtk_band_to_freq_num(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), nextsat(), obs_code_for_freq(), obs_code_for_freq_vrs(), out_iono(), out_leaps(), out_time(), outprcopts(), outrnxlnavh(), outrnxnavb(), outrnxnavh(), outrnxobsb(), outrnxobsh(), ppp_note_autosig(), ppp_res(), prange(), raw2rtcm(), readfcbf(), readrnxfp(), readrnxh(), readrnxnavb(), readrnxobsb(), rescode(), rtcm2rtcm(), sat2code(), satid2no(), satno(), satno2id(), satpos_ssr(), satsys(), save_msm_obs(), seleph(), selfreqpair(), seliflc(), set_index(), set_sysmask(), setopt_phshift(), setseleph(), sig2code(), sig2idx(), sig_idx(), sigmask2sig(), svid2sat(), sys2isbidx(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_sigid(), ubx_sig(), ubx_sys(), update_ssr(), update_states(), var_uraeph(), varerr(), varerr(), varerr(), varerr(), and write_rtcm3_msm().

◆ SYS_GLO

#define SYS_GLO   0x04

Definition at line 67 of file mrtk_eph.c.

Referenced by checkpri(), checkpri(), code2sys(), code2sys(), const_iono_corr(), convcode(), convcode(), convnav(), convrnx(), corr_meas(), cssr_gnss2sys(), cssr_sys2gnss(), ddres(), decode_bnx_01_02(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_cresgloeph(), decode_cresgloraw(), decode_geph(), decode_gloephem(), decode_gloephemerisb(), decode_glonav(), decode_glorawca(), decode_glostr_eph(), decode_lcliono(), decode_lD(), decode_msm_head(), decode_NE(), decode_NN(), decode_obsdata(), decode_obsh(), decode_rangeb(), decode_rangecmpb(), decode_rgeb(), decode_rged(), decode_rtcm3(), decode_rxmrawx(), decode_rxmsfrbx(), decode_sbstype1(), decode_ssr1(), decode_ssr1_head(), decode_ssr2(), decode_ssr2_head(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_ssr7_head(), decode_ssr_epoch(), decode_stqglo(), decode_stqgloe(), decode_stqraw(), decode_stqrawx(), decode_track_stat(), decode_trkd5(), decode_trkmeas(), decode_trksfrbx(), decode_type1010(), decode_type1012(), decode_type1020(), decode_type18(), decode_type19(), decode_type4076(), decode_xf5raw(), decode_xf7eph(), encode_head(), encode_lcliono(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1005(), encode_type1006(), encode_type1009(), encode_type1010(), encode_type1011(), encode_type1012(), encode_type1020(), encode_type4076(), ephclk(), ephpos(), fcn_glo(), freq_num2ant_idx(), freq_num2freq(), gen_msm_sat(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), gettgd(), gnssid2sys(), gnssid2sys(), input_rnxctr(), manage_amb_LAMBDA(), mcssr_sel_biascode(), mrtk_band_to_freq_num(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), nextsat(), obsindex(), out_time(), outnmea_gsa(), outnmea_gsv(), outprcopts(), outrnx_glo_bias(), outrnx_glo_fcn(), outrnxgnavb(), outrnxgnavh(), outrnxnavh(), outrnxobsb(), outrnxobsh(), ppp_note_autosig(), ppp_res(), prange(), raw2rtcm(), readbnxfp(), readnav(), readrnxfp(), readrnxh(), readrnxnavb(), readrnxobsb(), rescode(), rtcm2rtcm(), sat2code(), sat2freq(), sat_lambda(), satantoff(), satexclude(), satid2no(), satno(), satno2id(), satsys(), save_msm_obs(), scan_file(), set_index(), set_sysmask(), setopt_phshift(), setseleph(), sig2code(), sig2idx(), sig2idx(), sigmask2sig(), svid2sat(), sys2isbidx(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_sigid(), ubx_sig(), ubx_sys(), udstate(), udstate(), update_eph(), update_glofcn(), update_ssr(), varerr(), varerr(), varerr(), varerr(), varerr(), and write_rtcm3_msm().

◆ SYS_GPS

#define SYS_GPS   0x01

Definition at line 65 of file mrtk_eph.c.

Referenced by apply_claslib_ppprtk_obsdef(), apply_pppsig(), checkpri(), checkpri(), clas_osr_adjust_r_dts(), clas_osr_selfreqpair(), code2sys(), code2sys(), const_iono_corr(), convcode(), convcode(), convnav(), convrnx(), corr_meas(), cssr_gnss2sys(), cssr_sys2gnss(), decode_alm1(), decode_alm2(), decode_alm_gps(), decode_bnx_01_01(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_creseph(), decode_cresraw(), decode_cresraw2(), decode_eph(), decode_eph(), decode_eph_cnav(), decode_GE(), decode_gpsephemb(), decode_gpsnav(), decode_gpsrawca(), decode_javad(), decode_L1nav(), decode_lcliono(), decode_obsh(), decode_rawephemb(), decode_repb(), decode_rgeb(), decode_rged(), decode_rtcm3(), decode_rxmraw(), decode_rxmsfrb(), decode_rxmsfrbx(), decode_sbstype1(), decode_SI(), decode_ss2eph(), decode_ss2meas(), decode_ssr1(), decode_ssr2(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_stqgps(), decode_stqraw(), decode_stqrawx(), decode_track_stat(), decode_trkd5(), decode_trkmeas(), decode_trksfrbx(), decode_type1(), decode_type1002(), decode_type1004(), decode_type1019(), decode_type17(), decode_type18(), decode_type19(), decode_type4076(), decode_xf5raw(), decode_xf7eph(), DecodeGPSEphemeris(), DecodeQZSSEphemeris(), DecodeType17(), encode_lcliono(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1001(), encode_type1002(), encode_type1003(), encode_type1004(), encode_type1005(), encode_type1006(), encode_type1019(), encode_type4076(), ephclk(), ephpos(), freq_num2ant_idx(), gen_sat_sd(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), gnssid2sys(), gnssid2sys(), has_code2lam(), has_gnssid2sys(), has_sel_biascode(), mcssr_sel_biascode(), mrtk_band_to_freq_num(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), nextsat(), obs_code_for_freq(), obs_code_for_freq_vrs(), obsindex(), out_iono(), out_leaps(), out_time(), outprcopts(), outrnxgnavh(), outrnxhnavh(), outrnxnavb(), outrnxnavh(), outrnxobsb(), outrnxobsh(), ppp_note_autosig(), prange(), raw2rtcm(), readfcbf(), readrnxh(), readrnxnavb(), readrnxobsb(), readsp3b(), rtcm2rtcm(), sat2code(), satid2no(), satno(), satno2id(), satpos_ssr(), satsys(), save_msm_obs(), seleph(), set_index(), set_sysmask(), setopt_phshift(), setseleph(), sig2code(), sig2idx(), sig2idx(), sig_idx(), sigmask2sig(), svid2sat(), sys2isbidx(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_sigid(), ubx_sig(), ubx_sys(), update_ssr(), update_states(), varerr(), and write_rtcm3_msm().

◆ SYS_IRN

◆ SYS_NONE

◆ SYS_QZS

#define SYS_QZS   0x10

Definition at line 69 of file mrtk_eph.c.

Referenced by apply_claslib_ppprtk_obsdef(), apply_pppsig(), checkpri(), checkpri(), clas_osr_adjust_r_dts(), clas_osr_selfreqpair(), code2sys(), code2sys(), const_iono_corr(), convcode(), convcode(), convnav(), convrnx(), convsbs(), cssr_gnss2sys(), cssr_sys2gnss(), ddres(), decode_alm1(), decode_alm2(), decode_alm_qzs(), decode_bnx_01_06(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_eph(), decode_eph(), decode_eph_cnav(), decode_ionutc(), decode_ionutc(), decode_javad(), decode_L1ionutc(), decode_L1nav(), decode_lcliono(), decode_obsdata(), decode_obsh(), decode_QE(), decode_qzsrawl1ca(), decode_qzsrawl6(), decode_qzssephemerisb(), decode_qzssrawephemb(), decode_qzssrawsubframeb(), decode_rangeb(), decode_rangecmpb(), decode_rtcm3(), decode_rx(), decode_rxmrawx(), decode_rxmsfrbx(), decode_sbstype1(), decode_SI(), decode_ssr1(), decode_ssr1_head(), decode_ssr2(), decode_ssr2_head(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_ssr7_head(), decode_stqgps(), decode_stqraw(), decode_stqrawx(), decode_track_stat(), decode_trkd5(), decode_trkmeas(), decode_trksfrbx(), decode_type1044(), decode_type4076(), encode_lcliono(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1005(), encode_type1006(), encode_type1044(), encode_type4076(), ephclk(), ephpos(), exc_sat_par(), freq_num2ant_idx(), gen_sat_sd(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), gnssid2sys(), gnssid2sys(), input_rnxctr(), mcssr_sel_biascode(), mrtk_band_to_freq_num(), mrtk_get_signal_priority(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), nextsat(), obs_code_for_freq(), obs_code_for_freq_vrs(), obsindex(), out_iono(), out_leaps(), out_time(), outnmea_gsa(), outnmea_gsv(), outprcopts(), outrnxnavb(), outrnxnavh(), outrnxobsb(), outrnxobsh(), outrnxqnavh(), ppp_note_autosig(), ppp_res(), prange(), raw2rtcm(), readfcbf(), readrnxfp(), readrnxh(), readrnxnavb(), readrnxobsb(), readsp3b(), rescode(), rtcm2rtcm(), sat2code(), satexclude(), satid2no(), satno(), satno2id(), satpos_ssr(), satsys(), save_msm_obs(), seleph(), set_index(), set_sysmask(), setopt_phshift(), setseleph(), sig2code(), sig2idx(), sig2idx(), sig_idx(), sigmask2sig(), svid2sat(), sys2isbidx(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_satid(), to_sigid(), ubx_sig(), ubx_sys(), update_ssr(), update_states(), varerr(), varerr(), varerr(), and write_rtcm3_msm().

◆ SYS_SBS

#define SYS_SBS   0x02

Definition at line 66 of file mrtk_eph.c.

Referenced by convcode(), convcode(), convnav(), convrnx(), convsbs(), cssr_gnss2sys(), cssr_sys2gnss(), ddidx(), decode_bnx_01_03(), decode_bnx_7f_05(), decode_bnx_7f_05_obs(), decode_cresraw(), decode_cresraw2(), decode_georawl1(), decode_obsdata(), decode_obsh(), decode_rangeb(), decode_rangecmpb(), decode_rgeb(), decode_rged(), decode_rtcm3(), decode_rx(), decode_rxmraw(), decode_rxmsfrb(), decode_rxmsfrbx(), decode_sbstype1(), decode_sbstype9(), decode_seph(), decode_SI(), decode_ss2meas(), decode_ssr1(), decode_ssr2(), decode_ssr3(), decode_ssr4(), decode_ssr5(), decode_ssr6(), decode_ssr7(), decode_stqrawx(), decode_track_stat(), decode_trkd5(), decode_trkmeas(), decode_trksfrbx(), decode_type1002(), decode_type1004(), decode_type1019(), decode_type4076(), decode_WE(), decode_xf5raw(), encode_msm_head(), encode_rtcm3(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_ssr_head(), encode_type1001(), encode_type1002(), encode_type1003(), encode_type1004(), encode_type4076(), ephclk(), ephpos(), freq_num2ant_idx(), get_obsdef(), get_obsdef_default(), getcodepri(), getseleph(), iflc_freq2_idx(), input_rnxctr(), manage_amb_LAMBDA(), mrtk_band_to_freq_num(), mrtk_parse_signal_str(), mrtk_rinex_freq_to_band(), mrtk_sigcfg_to_obsdef(), navsys_str2mask(), obsindex(), out_time(), outnmea_gsa(), outnmea_gsv(), outprcopts(), outrnxhnavb(), outrnxhnavh(), outrnxnavh(), outrnxobsb(), outrnxobsh(), readbnxfp(), readrnxfp(), readrnxh(), readrnxnavb(), readrnxobsb(), readsp3b(), sat2code(), satid2no(), satno(), satno2id(), satsys(), save_msm_obs(), sbslongcorr(), seph2pos(), set_index(), set_sysmask(), setseleph(), sig2code(), sig2idx(), sigmask2sig(), svid2sat(), sys2sigcfg_idx(), test_sys(), test_sys(), test_sys(), to_satid(), to_sigid(), ubx_sig(), ubx_sys(), varerr(), varerr(), varerr(), varerr(), varerr(), and write_rtcm3_msm().

◆ TSTEP

#define TSTEP   60.0 /* integration step glonass ephemeris (s) */

Definition at line 57 of file mrtk_eph.c.

Referenced by geph2pos().

Function Documentation

◆ alm2pos()

void alm2pos ( gtime_t time,
const alm_t * alm,
double * rs,
double * dts )
extern

Compute satellite position and clock bias with almanac.

Parameters
[in]timeTime (GPST)
[in]almAlmanac
[out]rsSatellite position (ecef) {x,y,z} (m)
[out]dtsSatellite clock bias (s)

Definition at line 185 of file mrtk_eph.c.

References alm_t::A, alm_t::e, alm_t::f0, alm_t::f1, alm_t::i0, alm_t::M0, MAX_ITER_KEPLER, MU_GAL, MU_GPS, alm_t::omg, alm_t::OMG0, alm_t::OMGd, OMGE, RTOL_KEPLER, alm_t::sat, satsys(), SYS_GAL, time_str(), timediff(), alm_t::toa, alm_t::toas, and trace().

Here is the call graph for this function:

◆ deq()

void deq ( const double * x,
double * xdot,
const double * acc )
static

Definition at line 131 of file mrtk_eph.c.

References dot(), J2_GLO, MU_GLO, OMGE_GLO, RE_GLO, and SQR.

Referenced by glorbit().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ eph2clk()

double eph2clk ( gtime_t time,
const eph_t * eph )
extern

Compute satellite clock bias with broadcast ephemeris (GPS/GAL/QZS).

Parameters
[in]timeTime by satellite clock (GPST)
[in]ephBroadcast ephemeris
Returns
Satellite clock bias (s) without relativity correction

Definition at line 232 of file mrtk_eph.c.

References eph_t::f0, eph_t::f1, eph_t::f2, eph_t::sat, time_str(), timediff(), eph_t::toc, and trace().

Referenced by clas_osr_adjust_r_dts(), and ephclk().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ eph2pos()

void eph2pos ( gtime_t time,
const eph_t * eph,
double * rs,
double * dts,
double * var )
extern

Compute satellite position and clock with broadcast ephemeris (GPS/GAL/QZS/BDS/IRN).

Parameters
[in]timeTime (GPST)
[in]ephBroadcast ephemeris
[out]rsSatellite position (ecef) {x,y,z} (m)
[out]dtsSatellite clock bias (s)
[out]varSatellite position and clock variance (m^2)

Definition at line 258 of file mrtk_eph.c.

References eph_t::A, eph_t::cic, eph_t::cis, CLIGHT, COS_5, eph_t::crc, eph_t::crs, eph_t::cuc, eph_t::cus, eph_t::deln, eph_t::e, eph_t::f0, eph_t::f1, eph_t::f2, eph_t::i0, eph_t::idot, eph_t::M0, MAX_ITER_KEPLER, MU_CMP, MU_GAL, MU_GPS, eph_t::omg, eph_t::OMG0, eph_t::OMGd, OMGE, OMGE_CMP, OMGE_GAL, RTOL_KEPLER, eph_t::sat, satsys(), SIN_5, SQR, eph_t::sva, SYS_CMP, SYS_GAL, time_str(), timediff(), eph_t::toc, eph_t::toe, eph_t::toes, trace(), and var_uraeph().

Referenced by ephpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ephclk()

int ephclk ( gtime_t time,
gtime_t teph,
int sat,
const nav_t * nav,
double * dts )
static

Definition at line 638 of file mrtk_eph.c.

References eph2clk(), geph2clk(), satsys(), seleph(), selgeph(), selseph(), seph2clk(), SYS_CMP, SYS_GAL, SYS_GLO, SYS_GPS, SYS_IRN, SYS_QZS, SYS_SBS, geph_t::taun, time_str(), and trace().

Referenced by satposs().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ephpos()

int ephpos ( gtime_t time,
gtime_t teph,
int sat,
const nav_t * nav,
int iode,
double * rs,
double * dts,
double * var,
int * svh )

Satellite position and clock by broadcast ephemeris.

Parameters
[in]timeTransmission time
[in]tephTime for ephemeris selection
[in]satSatellite number
[in]navNavigation data
[in]iodeIODE (-1: any)
[out]rsSatellite position/velocity {x,y,z,vx,vy,vz} (m,m/s)
[out]dtsSatellite clock {bias,drift} (s,s/s)
[out]varSatellite position variance (m^2)
[out]svhSatellite health flag
Returns
1:ok, 0:error

Definition at line 673 of file mrtk_eph.c.

References eph2pos(), geph2pos(), satsys(), seleph(), selgeph(), selseph(), seph2pos(), eph_t::svh, geph_t::svh, seph_t::svh, SYS_CMP, SYS_GAL, SYS_GLO, SYS_GPS, SYS_IRN, SYS_QZS, SYS_SBS, geph_t::taun, time_str(), timeadd(), and trace().

Referenced by clas_osr_adjust_r_dts(), clas_osr_satcorr_update(), satpos(), satpos_sbas(), and satpos_ssr().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ geph2clk()

double geph2clk ( gtime_t time,
const geph_t * geph )
extern

Compute satellite clock bias with GLONASS ephemeris.

Parameters
[in]timeTime by satellite clock (GPST)
[in]gephGLONASS ephemeris
Returns
Satellite clock bias (s)

Definition at line 349 of file mrtk_eph.c.

References geph_t::gamn, geph_t::sat, geph_t::taun, time_str(), timediff(), geph_t::toe, and trace().

Referenced by ephclk().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ geph2pos()

void geph2pos ( gtime_t time,
const geph_t * geph,
double * rs,
double * dts,
double * var )
extern

Compute satellite position and clock with GLONASS ephemeris.

Parameters
[in]timeTime (GPST)
[in]gephGLONASS ephemeris
[out]rsSatellite position {x,y,z} (ecef) (m)
[out]dtsSatellite clock bias (s)
[out]varSatellite position and clock variance (m^2)

Definition at line 372 of file mrtk_eph.c.

References geph_t::acc, ERREPH_GLO, geph_t::gamn, glorbit(), geph_t::pos, geph_t::sat, SQR, geph_t::taun, time_str(), timediff(), geph_t::toe, trace(), TSTEP, and geph_t::vel.

Referenced by ephpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_ssr_ch_idx()

int get_ssr_ch_idx ( void )
extern

Get current SSR channel index.

Returns
Current channel index

Definition at line 766 of file mrtk_eph.c.

References _ssr_ch_idx.

◆ getseleph()

int getseleph ( int sys)
extern

Get selected satellite ephemeris.

Parameters
[in]sysSatellite system (SYS_???)
Returns
Selected ephemeris (refer setseleph())

Definition at line 1040 of file mrtk_eph.c.

References eph_sel, SYS_CMP, SYS_GAL, SYS_GLO, SYS_GPS, SYS_IRN, SYS_QZS, and SYS_SBS.

Referenced by prange(), and seleph().

Here is the caller graph for this function:

◆ glorbit()

void glorbit ( double t,
double * x,
const double * acc )
static

Definition at line 150 of file mrtk_eph.c.

References deq().

Referenced by geph2pos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ satpos()

int satpos ( gtime_t time,
gtime_t teph,
int sat,
int ephopt,
const nav_t * nav,
double * rs,
double * dts,
double * var,
int * svh )
extern

Compute satellite position, velocity and clock.

Parameters
[in]timeTime (GPST)
[in]tephTime to select ephemeris (GPST)
[in]satSatellite number
[in]ephoptEphemeris option (EPHOPT_???)
[in]navNavigation data
[out]rsSat position and velocity (ecef) {x,y,z,vx,vy,vz} (m|m/s)
[out]dtsSat clock {bias,drift} (s|s/s)
[out]varSat position and clock error variance (m^2)
[out]svhSat health flag (-1:correction not available)
Returns
Status (1:ok, 0:error)

Definition at line 891 of file mrtk_eph.c.

References EPHOPT_BRDC, EPHOPT_PREC, EPHOPT_SBAS, EPHOPT_SSRAPC, EPHOPT_SSRCOM, ephpos(), peph2pos(), satpos_sbas(), satpos_ssr(), time_str(), and trace().

Referenced by satposs(), and windupcorr().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ satpos_sbas()

int satpos_sbas ( gtime_t time,
gtime_t teph,
int sat,
const nav_t * nav,
double * rs,
double * dts,
double * var,
int * svh )
static

Definition at line 727 of file mrtk_eph.c.

References ephpos(), sbslcorr_t::iode, sbssatp_t::lcorr, sbssat_t::nsat, sbssat_t::sat, sbssatp_t::sat, nav_s::sbssat, sbssatcorr(), time_str(), and trace().

Referenced by satpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ satpos_ssr()

int satpos_ssr ( gtime_t time,
gtime_t teph,
int sat,
const nav_t * nav,
int opt,
double * rs,
double * dts,
double * var,
int * svh )
static

Definition at line 769 of file mrtk_eph.c.

References _ssr_ch_idx, CLIGHT, cross3(), ssr_t::dclk, ssr_t::ddeph, ssr_t::deph, dot(), ephpos(), eph_t::f0, eph_t::f1, eph_t::f2, ssr_t::hrclk, ssr_t::iod, ssr_t::iode, MAXAGESSR, MAXAGESSR_HRCLK, MAXCCORSSR, MAXECORSSR, norm(), normv3(), satantoff(), satsys(), seleph(), nav_s::ssr_ch, SYS_CMP, SYS_GAL, SYS_GPS, SYS_QZS, ssr_t::t0, gtime_t::time, time_str(), timediff(), eph_t::toc, trace(), ssr_t::udi, ssr_t::ura, and var_urassr().

Referenced by satpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ satposs()

void satposs ( gtime_t teph,
const obsd_t * obs,
int n,
const nav_t * nav,
int ephopt,
double * rs,
double * dts,
double * var,
int * svh )
extern

Compute satellite positions, velocities and clocks.

Parameters
[in]tephTime to select ephemeris (GPST)
[in]obsObservation data
[in]nNumber of observation data
[in]navNavigation data
[in]ephoptEphemeris option (EPHOPT_???)
[out]rsSatellite positions and velocities (ecef)
[out]dtsSatellite clocks
[out]varSat position and clock error variances (m^2)
[out]svhSat health flag (-1:correction not available)

Definition at line 940 of file mrtk_eph.c.

References CLIGHT, ephclk(), MAXOBS, satpos(), SQR, STD_BRDCCLK, time_str(), timeadd(), and trace().

Referenced by clas_ssr2osr(), intpres(), intpres(), pntpos(), ppp_rtk_pos(), pppos(), relpos(), and relposvrs().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ satsys()

int satsys ( int sat,
int * prn )
extern

Definition at line 117 of file mrtk_nav.c.

References MAXSAT, MINPRNCMP, MINPRNGAL, MINPRNGLO, MINPRNGPS, MINPRNIRN, MINPRNLEO, MINPRNQZS, MINPRNSBS, NSATCMP, NSATGAL, NSATGLO, NSATGPS, NSATIRN, NSATLEO, NSATQZS, NSATSBS, SYS_CMP, SYS_GAL, SYS_GLO, SYS_GPS, SYS_IRN, SYS_LEO, SYS_NONE, SYS_QZS, and SYS_SBS.

Referenced by alm2pos(), avepos(), check_bit_width_combo(), check_bit_width_oc(), clas_osr_adjust_r_dts(), clas_osr_corrmeas(), clas_osr_selfreqpair(), clas_osr_zdres(), clas_ssr2osr(), convnav(), ddidx(), decode_alm1(), decode_alm2(), decode_bdsraw(), decode_bnx_7f_05_obs(), decode_cnav(), decode_cssr_combo(), decode_cssr_oc(), decode_Dx(), decode_eph(), decode_eph_bds_cnav(), decode_eph_cnav(), decode_Ex(), decode_Fx(), decode_galrawfnav(), decode_galrawinav(), decode_georawl1(), decode_geph(), decode_glorawca(), decode_gnav(), decode_ionutc(), decode_ionutc(), decode_L1ionutc(), decode_L1nav(), decode_measepoch(), decode_navicraw(), decode_obsdata(), decode_Px(), decode_px(), decode_rawca(), decode_Rx(), decode_rx(), decode_seph(), decode_track_stat(), decode_xd(), decode_xE(), decode_xP(), decode_xp(), decode_xR(), decode_xr(), encode_lcliono(), encode_ssr1(), encode_ssr2(), encode_ssr3(), encode_ssr4(), encode_ssr5(), encode_ssr6(), encode_ssr7(), encode_type1001(), encode_type1002(), encode_type1003(), encode_type1004(), encode_type1005(), encode_type1006(), encode_type1009(), encode_type1010(), encode_type1011(), encode_type1012(), encode_type1019(), encode_type1020(), encode_type1041(), encode_type1042(), encode_type1044(), encode_type1045(), encode_type1046(), encode_type63(), eph2pos(), ephclk(), ephpos(), fcn_glo(), flushobuf(), gettgd(), iflc_freq2_idx(), input_rnxctr(), nextsat(), obs_code_for_freq(), obs_code_for_freq_vrs(), outnmea_gsa(), outnmea_gsv(), outrnxgnavb(), outrnxhnavb(), outrnxnavb(), outrnxobsb(), ppp_rtk_pos(), prange(), procpos(), raw2rtcm(), readbnxfp(), readrnxclk(), readrnxnavb(), relpos(), relposvrs(), rtcm2rtcm(), sat2code(), sat_lambda(), satpos_ssr(), sbslongcorr(), scan_file(), seleph(), selfreqpair(), setpcv(), sig2idx(), sigmask2sig(), sigmask2sig_p(), to_satid(), udsatcb(), udsatpb(), update_eph(), update_obs(), update_ssr(), write_rtcm3_msm(), and zdres_sat().

◆ sbssatcorr()

int sbssatcorr ( gtime_t time,
int sat,
const nav_t * nav,
double * rs,
double * dts,
double * var )
extern

Definition at line 1047 of file mrtk_sbas.c.

References CLIGHT, sbsfastcorr(), sbslongcorr(), nav_s::sbssat, and trace().

Referenced by satpos_sbas().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ seleph()

eph_t * seleph ( gtime_t time,
int sat,
int iode,
const nav_t * nav )

Select broadcast ephemeris by satellite and IODE.

Parameters
[in]timeTime for ephemeris selection
[in]satSatellite number
[in]iodeIODE (-1: any)
[in]navNavigation data
Returns
Pointer to selected ephemeris, NULL if not found

Definition at line 465 of file mrtk_eph.c.

References eph_t::code, nav_s::eph, nav_s::eph_prev, eph_sel, getseleph(), eph_t::iode, MAXDTOE, MAXDTOE_CMP, MAXDTOE_GAL, MAXDTOE_IRN, MAXDTOE_QZS, MAXSAT, nav_s::n, eph_t::sat, satsys(), SYS_CMP, SYS_GAL, SYS_GPS, SYS_IRN, SYS_QZS, time_str(), timediff(), eph_t::toe, eph_t::toes, and trace().

Referenced by clas_osr_adjust_r_dts(), ephclk(), ephpos(), and satpos_ssr().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ selgeph()

geph_t * selgeph ( gtime_t time,
int sat,
int iode,
const nav_t * nav )
static

Definition at line 582 of file mrtk_eph.c.

References nav_s::geph, geph_t::iode, MAXDTOE_GLO, nav_s::ng, geph_t::sat, time_str(), timediff(), geph_t::toe, and trace().

Referenced by ephclk(), and ephpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ selseph()

seph_t * selseph ( gtime_t time,
int sat,
const nav_t * nav )
static

Definition at line 613 of file mrtk_eph.c.

References MAXDTOE_SBS, nav_s::ns, seph_t::sat, nav_s::seph, seph_t::t0, time_str(), timediff(), and trace().

Referenced by ephclk(), and ephpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ seph2clk()

double seph2clk ( gtime_t time,
const seph_t * seph )
extern

Compute satellite clock bias with SBAS ephemeris.

Parameters
[in]timeTime by satellite clock (GPST)
[in]sephSBAS ephemeris
Returns
Satellite clock bias (s)

Definition at line 405 of file mrtk_eph.c.

References seph_t::af0, seph_t::af1, seph_t::sat, seph_t::t0, time_str(), timediff(), and trace().

Referenced by ephclk().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ seph2pos()

void seph2pos ( gtime_t time,
const seph_t * seph,
double * rs,
double * dts,
double * var )
extern

Compute satellite position and clock with SBAS ephemeris.

Parameters
[in]timeTime (GPST)
[in]sephSBAS ephemeris
[out]rsSatellite position {x,y,z} (ecef) (m)
[out]dtsSatellite clock bias (s)
[out]varSatellite position and clock variance (m^2)

Definition at line 428 of file mrtk_eph.c.

References seph_t::acc, seph_t::af0, seph_t::af1, seph_t::pos, seph_t::sat, seph_t::sva, SYS_SBS, seph_t::t0, time_str(), timediff(), trace(), var_uraeph(), and seph_t::vel.

Referenced by ephpos().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ set_ssr_ch_idx()

void set_ssr_ch_idx ( int ch)
extern

Set SSR channel index for satpos_ssr() (multi-L6E).

Parameters
[in]chChannel index (0 or 1)

Definition at line 761 of file mrtk_eph.c.

References _ssr_ch_idx, and SSR_CH_NUM.

Referenced by clas_ssr2osr(), and ppp_rtk_pos().

Here is the caller graph for this function:

◆ setseleph()

void setseleph ( int sys,
int sel )
extern

Set selected satellite ephemeris for multiple ones.

Parameters
[in]sysSatellite system (SYS_???)
[in]selSelection of ephemeris GPS,QZS : 0:LNAV ,1:CNAV (default: LNAV) GAL : 0:I/NAV,1:F/NAV (default: I/NAV) others : undefined

Definition at line 1009 of file mrtk_eph.c.

References eph_sel, SYS_CMP, SYS_GAL, SYS_GLO, SYS_GPS, SYS_IRN, SYS_QZS, and SYS_SBS.

◆ var_uraeph()

double var_uraeph ( int sys,
int ura )
static

Definition at line 109 of file mrtk_eph.c.

References SQR, STD_GAL_NAPA, and SYS_GAL.

Referenced by eph2pos(), and seph2pos().

Here is the caller graph for this function:

◆ var_urassr()

double var_urassr ( int ura)
static

Definition at line 453 of file mrtk_eph.c.

References DEFURASSR, and SQR.

Referenced by satpos_ssr().

Here is the caller graph for this function:

Variable Documentation

◆ _ssr_ch_idx

int _ssr_ch_idx = 0
static

Definition at line 760 of file mrtk_eph.c.

Referenced by get_ssr_ch_idx(), satpos_ssr(), and set_ssr_ch_idx().

◆ eph_sel

int eph_sel[]
static
Initial value:
= {
0, 0, 0, 0, 0, 0, 0}

Definition at line 450 of file mrtk_eph.c.

Referenced by decode_bnx_01_04(), decode_bnx_01_14(), decode_eph(), getseleph(), seleph(), and setseleph().