fix some shit

This commit is contained in:
2024-12-03 16:00:35 +08:00
parent 0a85320c68
commit 0398076df2
2 changed files with 1 additions and 6 deletions

View File

@@ -35,9 +35,6 @@ int main(void)
/* ---------- debug start ---------- */
/* ---------- debug end ---------- */
printf("\r\n");
@@ -52,12 +49,12 @@ int main(void)
UltraSonic_PwmOut_Cycles(ULTRASONIC_CYCLES);
delay_ms(2);
// printf("cap_val:%ld\t", g_capture_value);
// const char* result = (g_capture_value <= CAPTURE_VALUE_MAX) ? "Distance: %d\t" : "Over Range\t";
if (g_capture_value <= CAPTURE_VALUE_MAX) {
g_distance_uint16 = UltraSonic_CalcDistance(g_capture_value);
} else {
g_distance_uint16 = 0x0000;
}
// const char* result = (g_capture_value <= CAPTURE_VALUE_MAX) ? "Distance: %d\t" : "Over Range\t";
// printf(result, distance_uint16);
// printf("Temp:%d\n", MLX90614_GetObjectTemperature());