RTKLIB专题学习(四)---单点定位实现初识(二)

本文详细介绍了RTKLIB中单点定位的实现过程,从调用procpos的函数execses开始,深入讲解了execses_r和execses_b函数的作用,以及如何根据接收机和基站数据执行处理。在主函数postpos中,设置了处理选项和求解格式,并通过postpos进行单点定位计算。最后展示了程序运行的时间消耗。

RTKLIB专题学习(四)—单点定位实现初识(二)
今天我们来继续学习RTKLIB中单点定位的调用情况,上一篇在这里:RTKLIB专题学习(四)—单点定位实现初识(一)
1.上篇说到了调用procpos的函数是execsesexecses中调用的函数有readtec读取电离层数据文件函数;readerp读取erp数据文件函数;readobsnav读取观测值和导航文件函数;readdcb读取DCB文件函数;setpcv设置天线参数函数;readotl读取海洋潮汐数据文件函数
2.然后呢,调用execses函数的是execses_r函数,该函数是为每一个接收机执行处理的部分

/* execute processing session for each rover ---------------------------------*/
static int execses_r(gtime_t ts, gtime_t te, double ti, const prcopt_t *popt,
                     const solopt_t *sopt, const filopt_t *fopt, int flag,
                     char **infile, const int *index, int n, char *outfile,
                     const char *rov)
{
   
   
    gtime_t t0={
   
   0};
    int i,stat=0;
    char *ifile[MAXINFILE],ofile[1024],*rov_,*p,*q,s[64]="";
    
    trace(3,"execses_r: n=%d outfile=%s\n",n,outfile);
    
    for (i=0;i<n;i++) if (strstr(infile[i],"%r")) break;
    
    if (i<n) {
   
    /* include rover keywords */
        if (!(rov_=(char *)malloc(strlen(rov)+1))) return 0;
        strcpy(rov_,rov);
        
        for (i=0;i<n;i++) {
   
   
            if (!(ifile[i]=(char *)malloc(1024))) {
   
   
                free(rov_); for (;i>=0;i--) free(ifile[i]);
                return 0;
            }
        }
        for (p=rov_;;p=q+1) {
   
    /* for each rover */
            if ((q=strchr(p,' '))) *q='\0';
            
            if (*p) {
   
   
                strcpy(proc_rov,p);
                if (ts.time) time2str(ts,s,0); else *s='\0';
                if (checkbrk("reading    : %s",s)) {
   
   
                    stat=1;
                    break;
                }
                for (i=0;i<n;i++) reppath(infile[i],ifile[i],t0,p,"");
                reppath(outfile,ofile,t0,p,"");
                
                /* execute processing session */
                stat=execses(ts,te,ti,popt,sopt,fopt,flag,ifile,index,n,ofile);
            }
            if (stat==1||!q) break;
        }
        free(rov_); for (i=0;i<n;i++) free(ifile[i])
评论 3
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

十八与她

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值