Can you copy/paste the following into the left-hand side, and tell me what it says on a Pico where the clock has stopped?
var RCC = { "a": { "BDCR": 1073887344, "CSR": 1073887348, }, "f": { "BDCR": { "LSEON": 1, "LSERDY": 2, "LSEBYP": 4, "RTCSEL": 768, "RTCSEL_0": 256, "RTCSEL_1": 512, "RTCEN": 32768, "BDRST": 65536 }, "CSR": { "LSION": 1, "LSIRDY": 2, "RMVF": 16777216, "BORRSTF": 33554432, "PADRSTF": 67108864, "PORRSTF": 134217728, "SFTRSTF": 268435456, "WDGRSTF": 536870912, "WWDGRSTF": 1073741824, "LPWRRSTF": 2147483648 }, } }; function test() { console.log("LSEON",peek32(RCC.a.BDCR)&RCC.f.BDCR.LSEON); console.log("LSERDY",peek32(RCC.a.BDCR)&RCC.f.BDCR.LSERDY); console.log("LSION",peek32(RCC.a.CSR)&RCC.f.CSR.LSION); console.log("LSIRDY",peek32(RCC.a.CSR)&RCC.f.CSR.LSIRDY); console.log(["NONE","LSE","LSI","HSE"][((peek32(RCC.a.BDCR)&RCC.f.BDCR.RTCSEL)>>8)]); } test();
Thanks!
@Gordon started
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Can you copy/paste the following into the left-hand side, and tell me what it says on a Pico where the clock has stopped?
Thanks!