Ignore:
Timestamp:
Apr 16, 2010, 8:14:00 AM (12 years ago)
Author:
stoecker
Message:

fixed bug

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/clock_and_orbit/clock_orbit_rtcm.c

    r2421 r2432  
    33        Name:           clock_orbit_rtcm.c
    44        Project:        RTCM3
    5         Version:        $Id: clock_orbit_rtcm.c,v 1.9 2010/02/22 13:42:26 stoecker Exp $
     5        Version:        $Id: clock_orbit_rtcm.c,v 1.10 2010/04/14 11:09:18 stoecker Exp $
    66        Authors:        Dirk Stöcker
    77        Description:    state space approach for RTCM3
     
    9494/* standard values */
    9595#define T_MESSAGE_NUMBER(a)              ADDBITS(12, a) /* DF002 */
    96 #define T_RESERVED4                      ADDBITS(1, 0)  /* DF001 */
     96#define T_RESERVED4                      ADDBITS(4, 0)  /* DF001 */
    9797#define T_RESERVED5                      ADDBITS(5, 0)  /* DF001 */
    9898#define T_GPS_SATELLITE_ID(a)            ADDBITS(6, a)  /* DF068 */
     
    242242  if(gpsco)
    243243  {
    244     int nums, left, start = 0;
    245     nums = co->NumberOfGPSSat;
     244#ifdef SPLITBLOCK
     245    int nums = co->NumberOfGPSSat;
     246    int left, start = 0;
    246247    if(nums > 28) /* split block when more than 28 sats */
    247248    {
     
    255256    while(nums)
    256257    {
     258#endif
    257259      INITBLOCK
    258260      T_MESSAGE_NUMBER(COTYPE_GPSCOMBINED)
    259261      T_GPS_EPOCH_TIME(co->GPSEpochTime)
    260262      T_SSR_UPDATE_INTERVAL(co->UpdateInterval)
     263#ifdef SPLITBLOCK
    261264      T_MULTIPLE_MESSAGE_INDICATOR(/*mmi || */ left ? 1 : 0)
     265#else
     266      T_MULTIPLE_MESSAGE_INDICATOR(/*mmi || */ 0)
     267#endif
    262268      --mmi;
    263269      T_SATELLITE_REFERENCE_DATUM(co->SatRefDatum)
    264270      T_RESERVED4
     271#ifdef SPLITBLOCK
    265272      T_NO_OF_SATELLITES(nums)
    266273      for(i = start; i < start+nums; ++i)
     274#else
     275      T_NO_OF_SATELLITES(co->NumberOfGPSSat)
     276      for(i = 0; i < co->NumberOfGPSSat; ++i)
     277#endif
    267278      {
    268279        T_GPS_SATELLITE_ID(co->Sat[i].ID)
     
    279290      }
    280291      ENDBLOCK
     292#ifdef SPLITBLOCK
    281293      start += nums;
    282294      nums = left;
    283295      left = 0;
    284296    }
     297#endif
    285298  }
    286299  if(gpshr)
Note: See TracChangeset for help on using the changeset viewer.