@@ -215,7 +215,7 @@ double jd2last(double JulianDay, double ut1, bool updateRTC) {
215
215
}
216
216
217
217
// passes Local Apparent Sidereal Time to stepper timer
218
- void update_lst (double t) {
218
+ void updateLST (double t) {
219
219
long lst1=(t/24.0 )*8640000.0 ;
220
220
221
221
// set the local sidereal time
@@ -266,7 +266,7 @@ double encodeTimeZone(double tz) {
266
266
267
267
// convert equatorial coordinates to horizon
268
268
// this takes approx. 1.4mS on a 16MHz Mega2560
269
- void EquToHor (double HA, double Dec, double *Alt, double *Azm) {
269
+ void equToHor (double HA, double Dec, double *Alt, double *Azm) {
270
270
while (HA<0.0 ) HA=HA+360.0 ;
271
271
while (HA>=360.0 ) HA=HA-360.0 ;
272
272
HA =HA/Rad;
@@ -282,7 +282,7 @@ void EquToHor(double HA, double Dec, double *Alt, double *Azm) {
282
282
283
283
// convert horizon coordinates to equatorial
284
284
// this takes approx. 1.4mS
285
- void HorToEqu (double Alt, double Azm, double *HA, double *Dec) {
285
+ void horToEqu (double Alt, double Azm, double *HA, double *Dec) {
286
286
while (Azm<0 ) Azm=Azm+360.0 ;
287
287
while (Azm>=360.0 ) Azm=Azm-360.0 ;
288
288
Alt = Alt/Rad;
@@ -302,7 +302,7 @@ void HorToEqu(double Alt, double Azm, double *HA, double *Dec) {
302
302
// _deltaAxis1/2 are in arc-seconds/second
303
303
double _deltaAxis1=15.0 ,_deltaAxis2=0.0 ;
304
304
305
- void SetDeltaTrackingRate () {
305
+ void setDeltaTrackingRate () {
306
306
#ifndef MOUNT_TYPE_ALTAZM
307
307
if ((rateCompensation!=RC_REFR_BOTH) && (rateCompensation!=RC_FULL_BOTH)) _deltaAxis2=0.0 ;
308
308
#endif
@@ -316,25 +316,25 @@ void SetDeltaTrackingRate() {
316
316
}
317
317
318
318
double _currentRate=1.0 ;
319
- void SetTrackingRate (double r) {
319
+ void setTrackingRate (double r) {
320
320
_currentRate=r;
321
321
#ifndef MOUNT_TYPE_ALTAZM
322
322
_deltaAxis1=r*15.0 ;
323
323
_deltaAxis2=0.0 ;
324
324
#endif
325
325
}
326
326
327
- double GetTrackingRate () {
327
+ double getTrackingRate () {
328
328
return _currentRate;
329
329
}
330
330
331
- double GetStepsPerSecondAxis1 () {
331
+ double getStepsPerSecondAxis1 () {
332
332
double s=(((double )StepsPerDegreeAxis1/240.0 )*(_deltaAxis1/15.0 ));
333
333
if (s<8.0 ) s=8.0 ;
334
334
return s;
335
335
}
336
336
337
- double GetStepsPerSecondAxis2 () {
337
+ double getStepsPerSecondAxis2 () {
338
338
double s=(((double )StepsPerDegreeAxis2/240.0 )*(_deltaAxis2/15.0 ));
339
339
if (s<8.0 ) s=8.0 ;
340
340
return s;
@@ -343,7 +343,7 @@ double GetStepsPerSecondAxis2() {
343
343
// -----------------------------------------------------------------------------------------------------------------------------
344
344
// Low overhead altitude calculation, 16 calls to complete
345
345
346
- boolean do_fastalt_calc () {
346
+ boolean doFastAltCalc () {
347
347
boolean done=false ;
348
348
349
349
static byte ac_step = 0 ;
@@ -394,16 +394,16 @@ boolean do_fastalt_calc() {
394
394
// Refraction adjusted tracking
395
395
396
396
// returns the amount of refraction (in arcminutes) at the given true altitude (degrees), pressure (millibars), and temperature (celsius)
397
- double TrueRefrac (double Alt, double Pressure=1010.0 , double Temperature=10.0 ) {
397
+ double trueRefrac (double Alt, double Pressure=1010.0 , double Temperature=10.0 ) {
398
398
double TPC=(Pressure/1010.0 ) * (283.0 /(273.0 +Temperature));
399
399
double r=( ( 1.02 *cot ( (Alt+(10.3 /(Alt+5.11 )))/Rad ) ) ) * TPC; if (r<0.0 ) r=0.0 ;
400
400
return r;
401
401
}
402
402
403
403
// returns the amount of refraction (in arcminutes) at the given apparent altitude (degrees), pressure (millibars), and temperature (celsius)
404
- double ApparentRefrac (double Alt, double Pressure=1010.0 , double Temperature=10.0 ) {
405
- double r=TrueRefrac (Alt,Pressure,Temperature);
406
- r=TrueRefrac (Alt-(r/60.0 ),Pressure,Temperature);
404
+ double apparentRefrac (double Alt, double Pressure=1010.0 , double Temperature=10.0 ) {
405
+ double r=trueRefrac (Alt,Pressure,Temperature);
406
+ r=trueRefrac (Alt-(r/60.0 ),Pressure,Temperature);
407
407
return r;
408
408
}
409
409
@@ -415,8 +415,8 @@ double ztr(double a) {
415
415
double Alt1=a+0.25 ; if (Alt1<0.0 ) Alt1=0.0 ;
416
416
double Alt2=a-0.25 ; if (Alt2<0.0 ) Alt2=0.0 ;
417
417
418
- double Alt1_ = Alt1 - ( TrueRefrac (Alt1) / 60.0 );
419
- double Alt2_ = Alt2 - ( TrueRefrac (Alt2) / 60.0 );
418
+ double Alt1_ = Alt1 - ( trueRefrac (Alt1) / 60.0 );
419
+ double Alt2_ = Alt2 - ( trueRefrac (Alt2) / 60.0 );
420
420
421
421
double x=15.0 * ((double )(( Alt1 - Alt2 ) / ( Alt1_ - Alt2_ ))); if (x>15.0 ) x=15.0 ;
422
422
return x;
@@ -431,7 +431,7 @@ double ztr(double a) {
431
431
#define RefractionRateRange 10
432
432
#endif
433
433
434
- boolean do_refractionRate_calc () {
434
+ boolean doRefractionRateCalc () {
435
435
boolean done=false ;
436
436
static boolean ot=false ;
437
437
@@ -462,24 +462,24 @@ boolean do_refractionRate_calc() {
462
462
// get the instrument coordinates
463
463
if ((rr_step==10 ) || (rr_step==110 )) {
464
464
if (ot) {
465
- Align.EquToInstr (latitude,rr_HA,rr_Dec,&rr_HA,&rr_Dec,getInstrPierSide ());
465
+ Align.equToInstr (latitude,rr_HA,rr_Dec,&rr_HA,&rr_Dec,getInstrPierSide ());
466
466
rr_HA+=indexAxis1; rr_Dec+=indexAxis2;
467
467
}
468
468
}
469
469
470
470
// get the Horizon coords
471
471
if ((rr_step==15 ) || (rr_step==115 )) {
472
- EquToHor (rr_HA,rr_Dec,&rr_Alt,&rr_Azm);
472
+ equToHor (rr_HA,rr_Dec,&rr_Alt,&rr_Azm);
473
473
} else
474
474
475
475
// apply refraction
476
476
if ((rr_step==20 ) || (rr_step==120 )) {
477
- rr_Alt+=ApparentRefrac (rr_Alt,ambient.getPressure (),ambient.getTemperature ())/60.0 ;
477
+ rr_Alt+=apparentRefrac (rr_Alt,ambient.getPressure (),ambient.getTemperature ())/60.0 ;
478
478
} else
479
479
480
480
// convert back to the Equtorial coords
481
481
if ((rr_step==25 ) || (rr_step==125 )) {
482
- HorToEqu (rr_Alt,rr_Azm,&rr_HA1,&rr_Dec1);
482
+ horToEqu (rr_Alt,rr_Azm,&rr_HA1,&rr_Dec1);
483
483
if (rr_HA1>180.0 ) rr_HA1-=360.0 ; // HA range +/-180
484
484
} else
485
485
@@ -525,7 +525,7 @@ boolean do_refractionRate_calc() {
525
525
526
526
#define AltAzTrackingRange 10 // distance in arc-min (10) ahead of and behind the current Equ position, used for rate calculation
527
527
528
- boolean do_altAzmRate_calc () {
528
+ boolean doHorRateCalc () {
529
529
boolean done=false ;
530
530
531
531
static int az_step=0 ;
@@ -560,7 +560,7 @@ boolean do_altAzmRate_calc() {
560
560
561
561
// convert to Equatorial coords
562
562
if ((az_step==5 )) {
563
- HorToEqu (az_Alt,az_Azm,&az_HA1,&az_Dec1);
563
+ horToEqu (az_Alt,az_Azm,&az_HA1,&az_Dec1);
564
564
} else
565
565
566
566
// look ahead of and behind the current position
@@ -572,7 +572,7 @@ boolean do_altAzmRate_calc() {
572
572
573
573
// each back to the Horizon coords
574
574
if ((az_step==15 ) || (az_step==115 )) {
575
- EquToHor (az_HA,az_Dec,&az_Alt,&az_Azm);
575
+ equToHor (az_HA,az_Dec,&az_Alt,&az_Azm);
576
576
if (az_Azm>180.0 ) az_Azm-=360.0 ;
577
577
if (az_Azm<-180.0 ) az_Azm+=360.0 ;
578
578
@@ -660,7 +660,7 @@ double cot(double n) {
660
660
}
661
661
662
662
// Acceleration rate calculation
663
- void SetAccelerationRates (double maxRate) {
663
+ void setAccelerationRates (double maxRate) {
664
664
665
665
// set the new guide acceleration rate
666
666
slewRateX = (RateToXPerSec/(maxRate/16.0 ))*5.0 ; // 5x for exponential factor average rate
0 commit comments