Skip to content

Commit d7db4c0

Browse files
committed
Speedup and add hashing
1 parent 931d6db commit d7db4c0

File tree

3 files changed

+156
-143
lines changed

3 files changed

+156
-143
lines changed

pico_w/wifi/ota_update/CMakeLists.txt

+12-1
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,15 @@ target_include_directories(picow_ota_update_background PRIVATE
1313
target_link_libraries(picow_ota_update_background
1414
pico_cyw43_arch_lwip_threadsafe_background
1515
pico_stdlib
16+
pico_sha256
1617
boot_uf2_headers
1718
)
1819

19-
pico_sign_binary(picow_ota_update_background)
20+
pico_hash_binary(picow_ota_update_background)
21+
get_target_property(hasSigfile picow_ota_update_background PICOTOOL_SIGFILE)
22+
if (hasSigfile)
23+
pico_sign_binary(picow_ota_update_background)
24+
endif()
2025
# pico_set_binary_type(picow_ota_update_background no_flash)
2126
# pico_package_uf2_output(picow_ota_update_background 0x10000000)
2227

@@ -37,9 +42,15 @@ target_include_directories(picow_ota_update_poll PRIVATE
3742
target_link_libraries(picow_ota_update_poll
3843
pico_cyw43_arch_lwip_poll
3944
pico_stdlib
45+
pico_sha256
4046
boot_uf2_headers
4147
)
4248

49+
pico_hash_binary(picow_ota_update_poll)
50+
get_target_property(hasSigfile picow_ota_update_poll PICOTOOL_SIGFILE)
51+
if (hasSigfile)
52+
pico_sign_binary(picow_ota_update_poll)
53+
endif()
4354
# pico_set_binary_type(picow_ota_update_background no_flash)
4455
# pico_package_uf2_output(picow_ota_update_background 0x10000000)
4556

0 commit comments

Comments
 (0)