app: disable homing since reed switch code is buggy

This commit is contained in:
King Kévin 2022-08-11 14:21:19 +02:00
parent aa1d7b1dde
commit 938e2467a4
1 changed files with 5 additions and 0 deletions

View File

@ -666,6 +666,7 @@ static void command_dials(void* argument)
const uint32_t seconds = *(uint32_t*)argument; // get provide value
drv8825_goal = seconds;
drv8825_speed(100);
/*
if (seconds < 12 * 60 * 60) {
const uint32_t goal = DIAL_CYCLE_STEPS * seconds * 1.0 / (12 * 60 * 60);
if (goal != drv8825_goal) {
@ -674,6 +675,7 @@ static void command_dials(void* argument)
command_speed(&speed);
}
}
*/
}
printf("dial position/goal: %u/%u\n", drv8825_steps, drv8825_goal);
@ -972,6 +974,7 @@ void main(void)
gpio_set(GPIO_PORT(DRV8825_RESET_PIN), GPIO_PIN(DRV8825_RESET_PIN)); // power up driver
puts_debug("OK\n");
/*
puts_debug("setup dial position: ");
// dial position detection pin
rcc_periph_clock_enable(GPIO_RCC(DIAL_SWITCH_PIN)); // enable clock for GPIO port peripheral
@ -982,6 +985,8 @@ void main(void)
exti_enable_request(GPIO_EXTI(DIAL_SWITCH_PIN)); // enable external interrupt
nvic_enable_irq(GPIO_NVIC_EXTI_IRQ(DIAL_SWITCH_PIN)); // enable interrupt
puts_debug("OK\n");
*
*/
puts_debug("setup WS2812b LED matrix: ");
led_ws2812b_setup(); // configure peripheral for communication with WS2812b LEDs