예제 #1
0
파일: rmb.cpp 프로젝트: AluOne/OpenCPN
bool RMB::Write( SENTENCE& sentence )
{

   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += IsDataValid;
   sentence += CrossTrackError;
   if(DirectionToSteer == Left)
       sentence += _T("L");
   else
       sentence += _T("R");

   sentence += From;
   sentence += To;
   sentence += DestinationPosition;
   sentence += RangeToDestinationNauticalMiles;
   sentence += BearingToDestinationDegreesTrue;
   sentence += DestinationClosingVelocityKnots;
   sentence += IsArrivalCircleEntered;

   sentence.Finish();

//   NMEA0183_BOOLEAN check = sentence.IsChecksumBad( 14 );

   return( TRUE );
}
예제 #2
0
파일: gga.cpp 프로젝트: SethDart/logbook_pi
bool GGA::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += UTCTime;
   sentence += Position;
   sentence += GPSQuality;
   sentence += NumberOfSatellitesInUse;
   sentence += HorizontalDilutionOfPrecision;
   sentence += AntennaAltitudeMeters;
   sentence += _T("M");
   sentence += GeoidalSeparationMeters;
   sentence += _T("M");
   sentence += AgeOfDifferentialGPSDataSeconds;
   sentence += DifferentialReferenceStationID;

   sentence.Finish();

   return( TRUE );
}
예제 #3
0
파일: xte.cpp 프로젝트: AluOne/OpenCPN
bool XTE::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += IsLoranBlinkOK;
   sentence += IsLoranCCycleLockOK;
   sentence += CrossTrackErrorDistance;

   if(DirectionToSteer == Left)
       sentence += _T("L");
   else
       sentence += _T("R");
   
   sentence += CrossTrackUnits;

   sentence.Finish();

   return( TRUE );
}
예제 #4
0
파일: apb.cpp 프로젝트: AluOne/OpenCPN
bool APB::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += IsLoranBlinkOK;
   sentence += IsLoranCCycleLockOK;
   sentence.Add( CrossTrackErrorMagnitude, g_NMEAAPBPrecision);

   if(DirectionToSteer == Left)
       sentence += _T("L");
   else
       sentence += _T("R");
   
   sentence += CrossTrackUnits;
   sentence += IsArrivalCircleEntered;
   sentence += IsPerpendicular;
   sentence.Add( BearingOriginToDestination, g_NMEAAPBPrecision);
   sentence += BearingOriginToDestinationUnits;
   sentence += To;
   sentence.Add( BearingPresentPositionToDestination, g_NMEAAPBPrecision );
   sentence += BearingPresentPositionToDestinationUnits;
   sentence.Add( HeadingToSteer, g_NMEAAPBPrecision );
   sentence += HeadingToSteerUnits;

   sentence.Finish();

   return( TRUE );
}
예제 #5
0
bool RMC::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += UTCTime;
   sentence += IsDataValid;
   sentence += Position;
   sentence += SpeedOverGroundKnots;
   sentence += TrackMadeGoodDegreesTrue;
   sentence += Date;

   if(MagneticVariation > 360.)
         sentence += _T(",,");
   else
   {
         sentence += MagneticVariation;
         sentence += MagneticVariationDirection;
   }

   sentence.Finish();

   return( TRUE );
}
예제 #6
0
파일: gsv.cpp 프로젝트: AluOne/OpenCPN
bool GSV::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence.Finish();

   return( TRUE );
}
예제 #7
0
파일: ZZU.CPP 프로젝트: SammyB428/NMEA0183
bool ZZU::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += UTCTimeString;

   sentence.Finish();

   return( true );
}
예제 #8
0
bool HDM::Write(SENTENCE& sentence) {
  /*
  ** Let the parent do its thing
  */

  RESPONSE::Write(sentence);

  sentence += DegreesMagnetic;
  sentence += _T("M");

  sentence.Finish();

  return (TRUE);
}
예제 #9
0
파일: VWE.CPP 프로젝트: SammyB428/NMEA0183
bool VWE::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += EfficiencyPercent;

   sentence.Finish();

   return( true );
}
예제 #10
0
파일: HDM.CPP 프로젝트: SammyB428/NMEA0183
bool HDM::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += HeadingDegrees;
   sentence += "M";

   sentence.Finish();

   return( true );
}
예제 #11
0
파일: wpl.cpp 프로젝트: AluOne/OpenCPN
bool WPL::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += Position;
   sentence += To;

   sentence.Finish();

   return( TRUE );
}
예제 #12
0
파일: TEP.CPP 프로젝트: SammyB428/NMEA0183
bool TEP::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += ElevationDegrees;
   sentence += "D";

   sentence.Finish();

   return( true );
}
예제 #13
0
파일: hdt.cpp 프로젝트: AluOne/OpenCPN
bool HDT::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += DegreesTrue;
   sentence += _T("T");

   sentence.Finish();

   return( TRUE );
}
예제 #14
0
파일: stn.cpp 프로젝트: mikejwatts/epl_pi
BOOL STN::Write( SENTENCE& sentence )
{
   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += TalkerIDNumber;

   sentence.Finish();

   return( TRUE );
}
예제 #15
0
파일: WDR.CPP 프로젝트: SammyB428/NMEA0183
bool WDR::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += NauticalMiles;
   sentence += "N";
   sentence += To;

   sentence.Finish();

   return( true );
}
예제 #16
0
파일: ZLZ.CPP 프로젝트: SammyB428/NMEA0183
bool ZLZ::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += UTCTimeString;
   sentence += LocalTimeString;
   sentence += LocalHourDeviation;

   sentence.Finish();

   return( true );
}
예제 #17
0
파일: rte.cpp 프로젝트: CarCode/Cocoa-OCPN
bool RTE::Write( SENTENCE& sentence )
{

   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += total_number_of_messages;
   sentence += message_number;

   switch( TypeOfRoute )
   {
      case CompleteRoute:

//            sentence += _T("C");             // uppercase required for GPS MLR FFX312
           //            sentence += _T("c");             // trying lowercase for generic NMEA device
           sentence += wxString((wxChar)m_complete_char);
            break;

      case WorkingRoute:

         sentence += _T("w");
         break;

      default:

//         sentence += "";
         break;
   }

   sentence += RouteName;

   for(unsigned int i=0 ; i < Waypoints.GetCount() ; i++)
         sentence += Waypoints[i];

    if(m_skip_checksum){
        wxString temp_string;
        temp_string.Printf(_T("%c%c"), CARRIAGE_RETURN, LINE_FEED );
        sentence.Sentence += temp_string;
    }
    else
        sentence.Finish();

   return( TRUE );
}
예제 #18
0
파일: dpt.cpp 프로젝트: AluOne/OpenCPN
bool DPT::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += DepthMeters;
   sentence += OffsetFromTransducerMeters;

   sentence.Finish();

   return( TRUE );
}
예제 #19
0
bool MTW::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   CRESPONSE::Write( sentence );

   sentence += Temperature;
   sentence += UnitOfMeasurement;

   sentence.Finish();

   return( TRUE );
}
예제 #20
0
파일: VPW.CPP 프로젝트: SammyB428/NMEA0183
bool VPW::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += Knots;
   sentence += "N";
   sentence += MetersPerSecond;
   sentence += "M";

   sentence.Finish();

   return( true );
}
예제 #21
0
파일: HSC.CPP 프로젝트: SammyB428/NMEA0183
bool HSC::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += DegreesTrue;
   sentence += "T";
   sentence += DegreesMagnetic;
   sentence += "M";

   sentence.Finish();

   return( true );
}
예제 #22
0
파일: RPM.CPP 프로젝트: SammyB428/NMEA0183
bool RPM::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += Source;
   sentence += SourceNumber;
   sentence += RevolutionsPerMinute;
   sentence += PropellerPitchPercentage;
   sentence += IsDataValid;
   
   sentence.Finish();

   return( true );
}
예제 #23
0
파일: hdg.cpp 프로젝트: AluOne/OpenCPN
bool HDG::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += MagneticSensorHeadingDegrees;
   sentence += MagneticDeviationDegrees;
   sentence += MagneticDeviationDirection;
   sentence += MagneticVariationDegrees;
   sentence += MagneticVariationDirection;

   sentence.Finish();

   return( TRUE );
}
예제 #24
0
파일: GTD.CPP 프로젝트: SammyB428/NMEA0183
bool GTD::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += TimeDifference1;
   sentence += TimeDifference2;
   sentence += TimeDifference3;
   sentence += TimeDifference4;
   sentence += TimeDifference5;

   sentence.Finish();

   return( true );
}
예제 #25
0
파일: ztg.cpp 프로젝트: mikejwatts/epl_pi
BOOL ZTG::Write( SENTENCE& sentence )
{
   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += UTCTime;
   sentence += TimeRemaining;
   sentence += To;

   sentence.Finish();

   return( TRUE );
}
예제 #26
0
파일: gll.cpp 프로젝트: AluOne/OpenCPN
bool GLL::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */

   RESPONSE::Write( sentence );

   sentence += Position;
   sentence += UTCTime;
   sentence += IsDataValid;

   sentence.Finish();

   return( TRUE );
}
예제 #27
0
파일: WNC.CPP 프로젝트: SammyB428/NMEA0183
bool WNC::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += MilesDistance;
   sentence += "N";
   sentence += KilometersDistance;
   sentence += "K";
   sentence += To;
   sentence += From;

   sentence.Finish();

   return( true );
}
예제 #28
0
파일: BOD.CPP 프로젝트: SammyB428/NMEA0183
bool BOD::Write( SENTENCE& sentence )
{
   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += BearingTrue;
   sentence += "T";
   sentence += BearingMagnetic;
   sentence += "M";
   sentence += To;
   sentence += From;

   sentence.Finish();

   return( true );
}
예제 #29
0
bool RSA::Write( SENTENCE& sentence )
{
//   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   CRESPONSE::Write( sentence );

   sentence += Starboard;
   sentence += IsStarboardDataValid;
   sentence += Port;
   sentence += IsPortDataValid;
   
   sentence.Finish();

   return( TRUE );
}
예제 #30
0
파일: hsc.cpp 프로젝트: mikejwatts/epl_pi
BOOL HSC::Write( SENTENCE& sentence )
{
   ASSERT_VALID( this );

   /*
   ** Let the parent do its thing
   */
   
   RESPONSE::Write( sentence );

   sentence += DegreesTrue;
   sentence += "T";
   sentence += DegreesMagnetic;
   sentence += "M";

   sentence.Finish();

   return( TRUE );
}