This commit is contained in:
2025-01-04 22:39:04 -05:00
parent f956dea18d
commit 0a5ee4cd9f

View File

@@ -34,8 +34,8 @@ static esp_err_t joystick_adc_init() {
static void joystick_get_raw_xy() {
ESP_ERROR_CHECK(adc_oneshot_read(adc_xy_handle, ADC1_CHANNEL_0, *x));
ESP_ERROR_CHECK(adc_oneshot_read(adc_xy_handle, ADC1_CHANNEL_1, *y));
ESP_ERROR_CHECK(adc_oneshot_read(adc_xy_handle, ADC1_CHANNEL_0, &x));
ESP_ERROR_CHECK(adc_oneshot_read(adc_xy_handle, ADC1_CHANNEL_1, &y));
ESP_LOGI("(x,y)", "( %d, %d )", x, y);
}