Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 4906

SDK • hello_rtc example doesn't compile on Pico 2 W

$
0
0
I would like to run the hello_rtc example on Pico 2 W.

I am using Visual Studio code (1.95.3) and Raspberry Pi Pico extension (0.17.2) and I have updated the CMakeLists.txt as follows:

Code:

cmake_minimum_required(VERSION 3.13)...set(sdkVersion 2.1.0)set(toolchainVersion 13_3_Rel1)set(picotoolVersion 2.1.0)...set(PICO_BOARD pico2_w CACHE STRING "Board type")...target_link_libraries(hello_rtc pico_stdlib hardware_rtc)
but when I compile I get the following error:

.../hello_rtc.c:8:10: fatal error: hardware/rtc.h: No such file or directory
8 | #include "hardware/rtc.h"
| ^~~~~~~~~~~~~~~~
compilation terminated.
What am I doing wrong?

Statistics: Posted by fab64 — Sun Dec 08, 2024 3:55 pm — Replies 2 — Views 8



Viewing all articles
Browse latest Browse all 4906

Trending Articles