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

SDK • Reducing clk_sys on Pico W ("Failed to start CYW43")

$
0
0
I am referencing to this example:

https://github.com/raspberrypi/pico-exa ... ello_48MHz

When I am adding lines 49 to 66 to my C-Code, my Pico W does not connect to the WiFi anymore.

Lines 49-66:

Code:

clock_configure(clk_sys,                    CLOCKS_CLK_SYS_CTRL_SRC_VALUE_CLKSRC_CLK_SYS_AUX,                    CLOCKS_CLK_SYS_CTRL_AUXSRC_VALUE_CLKSRC_PLL_USB,                    48 * MHZ,                    48 * MHZ);    // Turn off PLL sys for good measure    pll_deinit(pll_sys);    // CLK peri is clocked from clk_sys so need to change clk_peri's freq    clock_configure(clk_peri,                    0,                    CLOCKS_CLK_PERI_CTRL_AUXSRC_VALUE_CLK_SYS,                    48 * MHZ,                    48 * MHZ);  // Re init uart now that clk_peri has changed    stdio_init_all();
This is what I am seeing on the serial port when I am NOT adding those lines.
Messages-connect-status--UART.jpg
This is what I am seeing on the serial port when I am adding those lines (including the header files of course).
Messages-failed-connect-status--UART.jpg
I tried with a variant of the above, output on the serial port is the same.

Code:

clock_configure(clk_sys,                    CLOCKS_CLK_SYS_CTRL_SRC_VALUE_CLK_REF,                    0,                    12 * MHZ,                    12 * MHZ);    // Turn off PLL sys for good measure    pll_deinit(pll_sys);    // CLK peri is clocked from clk_sys so need to change clk_peri's freq    clock_configure(clk_peri,                    0,                    CLOCKS_CLK_PERI_CTRL_AUXSRC_VALUE_CLK_SYS,                    12 * MHZ,                    12 * MHZ);
So why does this not work? Why CYW43 does not like diminishing clk_sys?
I am not really familiar with the Pico W, but according to the documentation the CYW43439 driver makes use of one of the PIOs, so the PIO cannot deal with a changed clk_sys? Or what is the matter here?

With the "normal" Pico I've never seen any problems with changing clk_sys, and as one would expect the power consumption goes down when the system clock goes down (what is actually the reason I want to change it).

Statistics: Posted by FlorianJW — Fri Jan 16, 2026 5:24 am



Viewing all articles
Browse latest Browse all 8082

Trending Articles