-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCmakeLists.txt
More file actions
60 lines (49 loc) · 1.43 KB
/
Copy pathCmakeLists.txt
File metadata and controls
60 lines (49 loc) · 1.43 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
cmake_minimum_required(VERSION 3.27.4)
include($ENV{PICO_SDK_PATH}/external/pico_sdk_import.cmake)
project(metal_detection_vehicle C CXX ASM)
set(CMAKE_C_STANDARD 11)
set(CMAKE_CXX_STANDARD 17)
pico_sdk_init()
#set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2")
add_executable(${PROJECT_NAME}
main.c
servo/servo.c
metal_detection/metal_detection.c
motion/motion.c
motion/mpu6050.c
RingBuffer/ring_Buffer.c
pico_irq/pico_irq.c
buffer/buffer.c
GPS/GPS.c
UDP/UDP.c
robot_Boot_Strap/robot_Boot_Strap.c)
pico_enable_stdio_usb(${PROJECT_NAME} 1)
pico_enable_stdio_uart(${PROJECT_NAME} 0)
pico_add_extra_outputs(${PROJECT_NAME})
target_include_directories(${PROJECT_NAME} PRIVATE
${CMAKE_SOURCE_DIR}
${PICO_SDK_PATH}/src/common/pico_util/include
${CMAKE_SOURCE_DIR}/servo
${CMAKE_SOURCE_DIR}/metal_detection
${CMAKE_SOURCE_DIR}/motion
${CMAKE_SOURCE_DIR}/RingBuffer
${CMAKE_SOURCE_DIR}/pico_irq
${CMAKE_SOURCE_DIR}/buffer
${CMAKE_SOURCE_DIR}/GPS
${CMAKE_SOURCE_DIR}/UDP
${CMAKE_SOURCE_DIR}/robot_Boot_Strap
)
target_link_libraries(${PROJECT_NAME}
pico_stdlib
hardware_pwm
hardware_gpio
hardware_timer
hardware_uart
hardware_i2c
hardware_irq
hardware_dma
pico_multicore
pico_util
pico_cyw43_arch_lwip_threadsafe_background
)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)