jonny_ji7 17d8db2193 Add 'stepper_home' function, disable testing mode
- Add function stepper_home
- disable STEPPER_TESTING and STEPPER_SIMULATE_ENCODER for normal
  for testing in operation
2023-04-26 21:56:25 +02:00

23 lines
641 B
C++

#pragma once
//init stepper pins and timer
void stepper_init();
//run to limit and define zero/start position. (busy until finished)
//Currently simply runs stepper for travelMm and bumps into hardware limit
void stepper_home(uint32_t travelMm = 60);
//set absolute target position in steps
void stepper_setTargetPosSteps(uint64_t steps);
//set absolute target position in millimeters
void stepper_setTargetPosMm(uint32_t posMm);
//set target speed in millimeters per second
void stepper_setSpeed(uint32_t speedMmPerS);
//task that periodically logs variables for debugging stepper driver
void task_stepper_debug(void *pvParameter);