Skip to content

Commit 5641dd9

Browse files
committed
added horizon test file
1 parent dc60467 commit 5641dd9

File tree

5 files changed

+28
-10
lines changed

5 files changed

+28
-10
lines changed

checks/check_message.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ START_TEST(message_format)
2424

2525
ck_assert_str_eq ("moving from 00:49:21.600 +056:06:00.00 (altaz 0:21:00.00 0:00:00.00) to 00:41:19.200 -056:06:00.00 (altaz 270:21:36.00 -80:12:00.00)", m2.expandString ("moving from $H1 $D2 (altaz $A5 $A6) to $H3 $D4 (altaz $A7 $A8)").c_str ());
2626

27-
rts2core::Message m3 (1700002, "T0", MESSAGE_INFO | DEBUG_MOUNT_TRACKING_LOG, "270.319554 -49.995853 270.326394 -49.999734 270.323712 -49.997449 270.320508 -49.999833 0.004076 -0.159195 -0.076785");
28-
ck_assert_str_eq ("target 270.319554 -49.995853 precession 270.326394 -49.999734 nutation 270.323712 -49.997449 aberation 270.320508 -49.999833 refraction 0.004076 model -0.159195 -0.076785", m3.expandString ("target $1 $2 precession $3 $4 nutation $5 $6 aberation $7 $8 refraction $9 model $10 $11").c_str ());
27+
rts2core::Message m3 (1700002, "T0", MESSAGE_INFO | DEBUG_MOUNT_TRACKING_LOG, "270.319554 -49.995853 270.326394 -49.999734 270.323712 -49.997449 270.320508 -49.999833 0.004076 -0.159195 -0.076785 -0 -0 0.456 0.678");
28+
ck_assert_str_eq ("target 270.319554 -49.995853 precession 270.326394 -49.999734 nutation 270.323712 -49.997449 aberation 270.320508 -49.999833 refraction 0.004076 model -0.159195 -0.076785 etar -0 -0 htar 0.456 0.678", m3.expandString ("target $1 $2 precession $3 $4 nutation $5 $6 aberation $7 $8 refraction $9 model $10 $11 etar $12 $13 htar $14 $15").c_str ());
2929
}
3030
END_TEST
3131

conf/horizon_flat_19_flip.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
AZ-ALT
2+
1:00 +19:00
3+
90:00 +19:00
4+
120:00 +19:00
5+
151:00 +14:00
6+
209:00 +14:00
7+
240:00 +19:00
8+
270:00 +19:00
9+
359:00 +19:00

lib/rts2/message.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ const std::string Message::getMessageString ()
113113
os << expandString ("moved to $H1 $D2 requested $H3 $D4 target $H5 $D6");
114114
break;
115115
case DEBUG_MOUNT_TRACKING_LOG:
116-
os << expandString ("target $1 $2 precession $3 $4 nutation $5 $6 aberation $7 $8 refraction $9 model $10 $11");
116+
os << expandString ("target $1 $2 precession $3 $4 nutation $5 $6 aberation $7 $8 refraction $9 model $10 $11 etar $12 $13 htar $14 $15");
117117
break;
118118
default:
119119
return messageString;

lib/rts2tel/teld.cpp

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1528,9 +1528,9 @@ void Telescope::runTracking ()
15281528

15291529
void Telescope::logTracking ()
15301530
{
1531-
logStream (MESSAGE_DEBUG | DEBUG_MOUNT_TRACKING_LOG)
1531+
rts2core::LogStream ls = logStream (MESSAGE_DEBUG | DEBUG_MOUNT_TRACKING_LOG);
15321532
// 1 2
1533-
<< tarRaDec->getRa () << " " << tarRaDec->getDec () << " "
1533+
ls << tarRaDec->getRa () << " " << tarRaDec->getDec () << " "
15341534
// 3 4
15351535
<< precessed->getRa () << " " << precessed->getDec () << " "
15361536
// 5 6
@@ -1540,10 +1540,19 @@ void Telescope::logTracking ()
15401540
// 9
15411541
<< refraction->getValueDouble () << " "
15421542
// 10 11
1543-
<< modelRaDec->getRa () << " " << modelRaDec->getDec ()
1544-
// 12 13
1545-
<< tarAltAz->getAz () << " " << tarAltAz->getAlt ()
1546-
<< sendLog;
1543+
<< modelRaDec->getRa () << " " << modelRaDec->getDec () << " ";
1544+
if (tarTelRaDec != NULL)
1545+
// 12 13
1546+
ls << tarTelRaDec->getRa () << " " << tarTelRaDec->getDec () << " ";
1547+
else
1548+
ls << "-0 -0 ";
1549+
1550+
if (tarTelAltAz != NULL)
1551+
// 14 15
1552+
ls << tarTelAltAz->getAz () << " " << tarTelAltAz->getAlt ();
1553+
else
1554+
ls << "-0 -0 ";
1555+
ls << sendLog;
15471556
}
15481557

15491558
void Telescope::updateTrackingFrequency ()

src/teld/sitech-altaz.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ SitechAltAz::SitechAltAz (int argc, char **argv):AltAz (argc,argv, true, true, t
203203
{
204204
unlockPointing ();
205205

206-
setCorrections (true, false, true, true);
206+
setCorrections (true, true, true, true);
207207

208208
tel_tty = "/dev/ttyUSB0";
209209
telConn = NULL;

0 commit comments

Comments
 (0)