2023-10-22 16:48:14 +00:00
|
|
|
cmake_minimum_required(VERSION 3.13)
|
|
|
|
|
|
|
|
include(pico_sdk_import.cmake)
|
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
project(PAMI_Cours_Moteurs C CXX ASM)
|
2023-10-22 16:48:14 +00:00
|
|
|
set(CMAKE_C_STNDARD 11)
|
|
|
|
set(CMAKE_CXX_STANDARD 17)
|
|
|
|
|
|
|
|
set(PICO_EXAMPLES_PATH ${PROJECT_SOURCE_DIR})
|
|
|
|
|
|
|
|
pico_sdk_init()
|
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
add_executable(PAMI_Cours_Moteurs
|
2023-10-22 16:48:14 +00:00
|
|
|
main.c
|
2025-01-15 10:06:48 +00:00
|
|
|
|
|
|
|
Moteurs.c
|
2024-08-15 00:20:18 +00:00
|
|
|
Teleplot.c
|
2025-01-04 17:08:56 +00:00
|
|
|
Temps.c
|
2023-10-22 16:48:14 +00:00
|
|
|
)
|
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
target_include_directories(PAMI_Cours_Moteurs PRIVATE ${CMAKE_CURRENT_LIST_DIR})
|
2023-10-22 16:48:14 +00:00
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
target_link_libraries(PAMI_Cours_Moteurs
|
2023-10-22 16:48:14 +00:00
|
|
|
hardware_uart
|
2025-01-15 10:06:48 +00:00
|
|
|
hardware_pwm
|
2023-10-22 16:48:14 +00:00
|
|
|
pico_stdlib
|
|
|
|
pico_multicore
|
2024-08-15 00:20:18 +00:00
|
|
|
pico_cyw43_arch_lwip_poll
|
2023-10-22 16:48:14 +00:00
|
|
|
)
|
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
pico_enable_stdio_usb(PAMI_Cours_Moteurs 1)
|
|
|
|
pico_enable_stdio_uart(PAMI_Cours_Moteurs 1)
|
2023-10-22 16:48:14 +00:00
|
|
|
|
2025-01-15 10:06:48 +00:00
|
|
|
pico_add_extra_outputs(PAMI_Cours_Moteurs)
|
2023-10-22 16:48:14 +00:00
|
|
|
|
|
|
|
add_custom_target(Flash
|
2025-01-15 10:06:48 +00:00
|
|
|
DEPENDS PAMI_Cours_Moteurs
|
|
|
|
COMMAND sudo picotool load -f ${PROJECT_BINARY_DIR}/PAMI_Cours_Moteurs.uf2
|
2023-10-22 16:48:14 +00:00
|
|
|
)
|