C
Qt Quick Ultralite手表演示
cmake_minimum_required (VERSION 3.21.1) project(watch VERSION 0.0.1 LANGUAGES C CXX ASM) if (NOT TARGET Qul::Core) find_package(Qul) endif() if(QUL_PLATFORM MATCHES "^ek-ra6m3g") string(TOUPPER ${CMAKE_BUILD_TYPE} build_type) if(build_type STREQUAL "RELEASE" OR build_type STREQUAL "DEBUG") message(WARNING "For Release or Debug builds, watch demo binary may not fit in internal flash of EK-RA6M3G board. Sections QulResourceDataExtFlash and QulFontResourceDataExtFlash can be used to move image or font data into the external flash memory.") endif() endif() if(QUL_PLATFORM STREQUAL "qt") qul_add_target(watch QML_PROJECT qmlproject/mcu_watch.qmlproject GENERATE_ENTRYPOINT SELECTORS desktop normal) qul_add_target(watch_benchmark QML_PROJECT qmlproject/mcu_watch.qmlproject GENERATE_ENTRYPOINT SELECTORS desktop benchmark) elseif(QUL_PLATFORM MATCHES "^stm32h750b-discovery") qul_add_target(watch QML_PROJECT qmlproject/mcu_watch-stm32h750b-discovery.qmlproject GENERATE_ENTRYPOINT SELECTORS normal) qul_add_target(watch_benchmark QML_PROJECT qmlproject/mcu_watch-stm32h750b-discovery.qmlproject GENERATE_ENTRYPOINT SELECTORS benchmark) else() qul_add_target(watch QML_PROJECT qmlproject/mcu_watch.qmlproject GENERATE_ENTRYPOINT SELECTORS normal) qul_add_target(watch_benchmark QML_PROJECT qmlproject/mcu_watch.qmlproject GENERATE_ENTRYPOINT SELECTORS benchmark) endif() target_sources(watch_benchmark PRIVATE mode/+benchmark/simulation/flickControl.cpp) foreach(target watch watch_benchmark) target_include_directories(${target} PRIVATE inc) target_sources(${target} PRIVATE src/HealthModel.cpp) qul_get_module_target(watch_module_target ${target} qmlproject/watch_model.qmlproject) target_include_directories(${watch_module_target} PUBLIC inc) target_sources(${watch_module_target} PRIVATE src/WatchModel.cpp) app_target_setup_os(${target}) endforeach()