blob: ec8beaed910d0f1a95ec8f39e4c75df172db21ea (
plain)
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
|
cmake_minimum_required(VERSION 3.13)
include(/home/dwlr/projects/current/rp2040/pico-sdk/pico_sdk_init.cmake)
pico_sdk_init()
project(eeprom2blk)
enable_language(C CXX ASM)
add_executable(eeprom2blk main.c)
set_source_files_properties(main.c PROPERTIES
COMPILE_FLAGS -Wall -Wextra -pedantic
C_STANDARD 90
)
file(MAKE_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/generated)
pico_generate_pio_header(eeprom2blk ${CMAKE_CURRENT_LIST_DIR}/ws2812.pio OUTPUT_DIR ${CMAKE_CURRENT_LIST_DIR}/generated)
target_link_libraries(eeprom2blk pico_stdlib hardware_pio hardware_dma)
# change default stdout
pico_enable_stdio_usb(eeprom2blk 1)
pico_enable_stdio_uart(eeprom2blk 0)
# create map/bin/hex/uf2 file in addition to ELF.
pico_add_extra_outputs(eeprom2blk)
|