Skip to content

Commit ff3f8dd

Browse files
committed
picoruby-socket!
1 parent b502578 commit ff3f8dd

File tree

6 files changed

+19
-6
lines changed

6 files changed

+19
-6
lines changed

CMakeLists.txt

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,17 +51,28 @@ if(USE_WIFI)
5151
${PICO_SDK_PATH}/src/rp2_common/pico_mbedtls/pico_mbedtls.c
5252
)
5353
list(APPEND SOURCE_FILES ${ADD_WIFI_SOURCE_FILES})
54+
if(PICO_BOARD STREQUAL "pico2_w")
55+
file(GLOB REMOVE_WIFI_SRCS CONFIGURE_DEPENDS
56+
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-net/ports/rp2040/*.c
57+
)
58+
else()
59+
file(GLOB REMOVE_WIFI_SRCS CONFIGURE_DEPENDS
60+
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-socket/ports/rp2040/*.c
61+
)
62+
endif()
5463
else()
5564
file(GLOB REMOVE_WIFI_SRCS CONFIGURE_DEPENDS
5665
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-cyw43/ports/rp2040/*.c
5766
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-net/ports/rp2040/*.c
67+
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-socket/ports/rp2040/*.c
5868
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-ble/ports/rp2040/*.c
5969
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-mbedtls/ports/**/*.c
6070
${PICO_SDK_PATH}/src/rp2_common/pico_mbedtls/pico_mbedtls.c
6171
)
62-
list(REMOVE_ITEM SOURCE_FILES ${REMOVE_WIFI_SRCS})
6372
endif()
6473

74+
list(REMOVE_ITEM SOURCE_FILES ${REMOVE_WIFI_SRCS})
75+
6576
if(PICORB_VM_MRUBYC)
6677
file(GLOB REMOVE_MRUBY_SRCS CONFIGURE_DEPENDS
6778
${CMAKE_SOURCE_DIR}/lib/picoruby/mrbgems/picoruby-mruby/ports/rp2040/*.c

build_config/r2p2-microruby-pico2_w.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
conf.gembox "peripherals"
5555
conf.gem core: 'picoruby-shinonome'
5656
conf.gem core: 'picoruby-psg'
57-
conf.gem core: 'picoruby-net'
5857
conf.gem core: 'picoruby-ble'
58+
conf.gem core: 'picoruby-net-http'
59+
conf.gem core: 'picoruby-net-ntp'
5960
end

build_config/r2p2-picoruby-pico2_w.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656
conf.gembox "peripheral_utils"
5757
conf.gembox "peripherals"
5858
conf.gem core: 'picoruby-shinonome'
59-
conf.gem core: 'picoruby-net'
6059
conf.gem core: 'picoruby-ble'
60+
conf.gem core: 'picoruby-net-http'
61+
conf.gem core: 'picoruby-net-ntp'
6162
end

lib/picoruby

Submodule picoruby updated 247 files

mrblib/main_task.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
STDOUT = IO.new
1010
STDIN = IO.new
1111

12-
Machine.set_hwclock(0, 0)
12+
Machine.set_hwclock(0)
1313

1414
begin
1515
sleep 1

src/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#if !defined(HEAP_SIZE)
1818
#if defined(PICO_RP2040)
1919
#define RAM_SIZE_KB 264
20-
#define WIFI_STACK_SIZE_KB 31
20+
#define WIFI_STACK_SIZE_KB 32
2121
#elif defined(PICO_RP2350)
2222
#define RAM_SIZE_KB 524
2323
#define WIFI_STACK_SIZE_KB 80

0 commit comments

Comments
 (0)