Skip to content

Commit

Permalink
[RP2XXX] build is possible for Pico 2 (RP3250)
Browse files Browse the repository at this point in the history
  • Loading branch information
lyusupov committed Aug 26, 2024
1 parent 4b2fa20 commit 5917ff6
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ jobs:
'arduino:renesas_uno:unor4wifi',
'rp2040:rp2040:generic',
'rp2040:rp2040:rpipicow',
'rp2040:rp2040:rpipico2',
'arduino:mbed_rp2040:pico',
#'arduino:mbed_nano:nanorp2040connect',
'SiliconLabs:silabs:nano_matter:protocol_stack=ble_arduino',
Expand Down
5 changes: 5 additions & 0 deletions software/firmware/source/SkyView/Platform_RP2040.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,10 @@ extern "C"
}
#endif /* ARDUINO_ARCH_MBED */

#if !defined(ARDUINO_RASPBERRY_PI_PICO_2)
#include <pico_sleep.h>
#include <pico_rosc.h>
#endif /* ARDUINO_RASPBERRY_PI_PICO_2 */

#if defined(USE_TINYUSB)
#if defined(USE_USB_HOST)
Expand Down Expand Up @@ -525,6 +527,7 @@ static void RP2040_fini()
USBDevice.detach();
#endif /* USE_TINYUSB */

#if !defined(ARDUINO_RASPBERRY_PI_PICO_2)
sleep_run_from_xosc();

#if SOC_GPIO_PIN_KEY1 != SOC_UNUSED_PIN
Expand All @@ -542,6 +545,8 @@ static void RP2040_fini()

// back from dormant state
rosc_enable();
#endif /* ARDUINO_RASPBERRY_PI_PICO_2 */

#if PICO_SDK_VERSION_MAJOR < 2
clocks_init();
#endif /* PICO_SDK_VERSION_MAJOR */
Expand Down
2 changes: 2 additions & 0 deletions software/firmware/source/SkyWatch/Platform_RP2040.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ extern "C"
}
#endif /* ARDUINO_ARCH_MBED */

#if !defined(ARDUINO_RASPBERRY_PI_PICO_2)
#include <pico_sleep.h>
#endif /* ARDUINO_RASPBERRY_PI_PICO_2 */

#if defined(USE_TINYUSB)
#if defined(USE_USB_HOST)
Expand Down
4 changes: 3 additions & 1 deletion software/firmware/source/SoftRF/src/platform/RP2XXX.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ extern "C" {
#include "pico/binary_info.h"
}

#if !defined(ARDUINO_RASPBERRY_PI_PICO_2)
#include <pico_sleep.h>
#endif /* ARDUINO_RASPBERRY_PI_PICO_2 */
#else
extern "C"
{
Expand Down Expand Up @@ -548,7 +550,7 @@ static void RP2xxx_fini(int reason)
USBDevice.detach();
#endif /* USE_TINYUSB */

#if !defined(ARDUINO_ARCH_MBED)
#if !defined(ARDUINO_ARCH_MBED) && !defined(ARDUINO_RASPBERRY_PI_PICO_2)
sleep_run_from_xosc();

#if SOC_GPIO_PIN_BUTTON != SOC_UNUSED_PIN
Expand Down

0 comments on commit 5917ff6

Please sign in to comment.