MCPcopy Create free account
hub / github.com/Hamlib/Hamlib / ars_stop

Function ars_stop

rotators/ars/ars.c:227–253  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225}
226
227int
228ars_stop(ROT *rot)
229{
230 struct ars_priv_data *priv = (struct ars_priv_data *)ROTSTATE(rot)->priv;
231 hamlib_port_t *pport = ROTPORT(rot);
232
233 rig_debug(RIG_DEBUG_TRACE, "%s called, brake was %s\n", __func__,
234 priv->brake_off ? "OFF" : "ON");
235
236 priv->set_pos_active = 0;
237
238 par_lock(pport);
239
240 priv->brake_off = 0;
241 priv->curr_move = 0;
242
243 // Relay AUX -> Off
244 CHKPPRET(ars_clear_data_pin(rot, DTA_PIN02 | DTA_PIN04 | DTA_PIN08));
245 CHKPPRET(ars_clear_ctrl_pin(rot, CTL_PIN17 | CTL_PIN16));
246
247 // Elevation Relays -> Off
248 CHKPPRET(ars_clear_data_pin(rot, DTA_PIN03 | DTA_PIN07));
249
250 par_unlock(pport);
251
252 return RIG_OK;
253}
254
255int
256ars_move(ROT *rot, int direction, int speed)

Callers 3

ars_openFunction · 0.85
ars_closeFunction · 0.85
ars_set_position_syncFunction · 0.85

Calls 5

rig_debugFunction · 0.85
par_lockFunction · 0.85
ars_clear_data_pinFunction · 0.85
ars_clear_ctrl_pinFunction · 0.85
par_unlockFunction · 0.85

Tested by

no test coverage detected