esp32,esp8266: Remove dead code for end_ticks in machine_bitstream.

The compiler was optimising this out already so it's a no-op change.

Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
This commit is contained in:
Jim Mussared 2021-08-20 12:09:36 +10:00 committed by Damien George
parent b51e7e9d01
commit 996f703166
2 changed files with 0 additions and 4 deletions

View File

@ -69,13 +69,11 @@ void IRAM_ATTR machine_bitstream_high_low(mp_hal_pin_obj_t pin, uint32_t *timing
GPIO_REG_WRITE(gpio_reg_set, pin_mask);
uint32_t start_ticks = mp_hal_ticks_cpu();
uint32_t *t = &timing_ns[b >> 6 & 2];
uint32_t end_ticks = start_ticks + t[0];
while (mp_hal_ticks_cpu() - start_ticks < t[0]) {
;
}
GPIO_REG_WRITE(gpio_reg_clear, pin_mask);
b <<= 1;
end_ticks += t[1];
while (mp_hal_ticks_cpu() - start_ticks < t[1]) {
;
}

View File

@ -57,13 +57,11 @@ void machine_bitstream_high_low(mp_hal_pin_obj_t pin, uint32_t *timing_ns, const
GPIO_REG_WRITE(GPIO_OUT_W1TS_ADDRESS, pin_mask);
uint32_t start_ticks = mp_hal_ticks_cpu();
uint32_t *t = &timing_ns[b >> 6 & 2];
uint32_t end_ticks = start_ticks + t[0];
while (mp_hal_ticks_cpu() - start_ticks < t[0]) {
;
}
GPIO_REG_WRITE(GPIO_OUT_W1TC_ADDRESS, pin_mask);
b <<= 1;
end_ticks += t[1];
while (mp_hal_ticks_cpu() - start_ticks < t[1]) {
;
}