-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
54 lines (42 loc) · 1.19 KB
/
CMakeLists.txt
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
cmake_minimum_required(VERSION 3.18)
# pull in PICO SDK (must be before project)
include(pico_sdk_import.cmake)
# we also need PICO EXTRAS
include(pico_extras_import.cmake)
project(simple-stupid-synth)
set(CMAKE_C_STANDARD 11)
set(CMAKE_CXX_STANDARD 17)
set(PICO_CXX_ENABLE_EXCEPTIONS 1)
add_compile_options(-Wall -Wextra -Wnull-dereference)
# initialize the Pico SDK
pico_sdk_init()
add_executable(simple-stupid-synth
src/simple-stupid-synth.cpp
src/midi-state-machine.cpp
src/audio-target.cpp
src/i2s-audio-target.cpp
src/pwm-audio-target.cpp
src/usb_descriptors.c)
target_compile_definitions(simple-stupid-synth PRIVATE
PICO_AUDIO_I2S_MONO_OUTPUT=0
PICO_AUDIO_I2S_MONO_INPUT=0)
target_include_directories(simple-stupid-synth PRIVATE
src
../pico-sdk/lib/tinyusb/src
../pico-sdk/lib/tinyusb/hw)
# enable serial output via UART
#pico_enable_stdio_uart(simple-stupid-synth 1)
# pull in common dependencies
target_link_libraries(simple-stupid-synth
pico_stdlib
pico_multicore
tinyusb_device
tinyusb_board
pico_audio_i2s
pico_audio_pwm)
# create map/bin/hex file etc.
pico_add_extra_outputs(simple-stupid-synth)
# Local variables:
# mode: cmake
# coding: utf-8
# End: