检查障碍测试

This commit is contained in:
Glz
2024-03-23 09:43:06 +08:00
parent 200d67b8bd
commit 77966b874f
5 changed files with 46 additions and 1 deletions

15
app/gl_barrier.c Normal file
View File

@@ -0,0 +1,15 @@
#include "zf_common_headfile.h"
#include "gl_headfile.h"
enum barrier_type_e barrier_type = BARRIER_NONE;
void CheckBarrier() {
if (barrier_type == BARRIER_NONE && Lpt0_found_barrier_in && !Lpt1_found_barrier_in && is_straight1) {
barrier_type = BARRIER_LEFT_BEGIN;
}
if (barrier_type == BARRIER_NONE && !Lpt0_found_barrier_in && Lpt1_found_barrier_in && is_straight0) {
barrier_type = BARRIER_RIGHT_BEGIN;
}
}