MITHaystack / srt-py

BSD 3-Clause "New" or "Revised" License
10 stars 14 forks source link

H180 class: calculated self.az_count, self.el_count values not passed to next command (tracking object) construction #24

Open AlexKurek opened 5 months ago

AlexKurek commented 5 months ago

Values of self.az_count and self.el_count calculated here: https://github.com/MITHaystack/srt-py/blob/master/srt/daemon/rotor_control/motors.py#L446 are not passed to here: https://github.com/MITHaystack/srt-py/blob/master/srt/daemon/rotor_control/motors.py#L396 https://github.com/MITHaystack/srt-py/blob/master/srt/daemon/rotor_control/motors.py#L410 for subtraction - to calculate the next (tracking) command. So the value of 0 is subtracted and the commands sent to the serial port are e.g (first two are Direct Point, third is for tracking):

move 1 396 move 3 54 move 1 396

etc., whereas they should be:

move 1 396 move 3 54 move 1 2

AlexKurek commented 5 months ago

Also in case of Cassi motor (I have no way to test if this is true for H180) here: https://github.com/MITHaystack/srt-py/blob/master/srt/daemon/rotor_control/motors.py#L445 should be -3 (not -1).

AlexKurek commented 5 months ago

Fixed in https://github.com/AlexKurek/srt-py/commit/c77f7357c4496fc947352c94b876ca6084264830.