File tree Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ pico_use_wifi_firmware_partition(picow_ota_update_poll)
49
49
50
50
pico_hash_binary (picow_ota_update_poll )
51
51
pico_sign_binary (picow_ota_update_poll ${CMAKE_CURRENT_LIST_DIR} /private.pem )
52
- # pico_set_binary_type(picow_ota_update_background no_flash)
53
- # pico_package_uf2_output(picow_ota_update_background 0x10000000)
52
+ # pico_set_binary_type(picow_ota_update_poll no_flash)
53
+ # pico_package_uf2_output(picow_ota_update_poll 0x10000000)
54
54
55
55
pico_add_extra_outputs (picow_ota_update_poll )
Original file line number Diff line number Diff line change @@ -30,8 +30,8 @@ typedef struct TCP_UPDATE_SERVER_T_ {
30
30
struct tcp_pcb * server_pcb ;
31
31
struct tcp_pcb * client_pcb ;
32
32
bool complete ;
33
- uint8_t buffer_sent [SHA256_RESULT_BYTES ];
34
- uint8_t buffer_recv [BUF_SIZE ];
33
+ __attribute__(( aligned ( 4 ))) uint8_t buffer_sent [SHA256_RESULT_BYTES ];
34
+ __attribute__(( aligned ( 4 ))) uint8_t buffer_recv [BUF_SIZE ];
35
35
int sent_len ;
36
36
int recv_len ;
37
37
int num_blocks ;
@@ -300,6 +300,15 @@ static bool tcp_update_server_open(void *arg) {
300
300
int main () {
301
301
stdio_init_all ();
302
302
303
+ #ifdef __riscv
304
+ // Increased bootrom stack is required for some of the functions in this example
305
+ bootrom_stack_t stack = {
306
+ .base = malloc (0x400 ),
307
+ .size = 0x400
308
+ };
309
+ rom_set_bootrom_stack (& stack );
310
+ #endif
311
+
303
312
if (cyw43_arch_init ()) {
304
313
printf ("failed to initialise\n" );
305
314
return 1 ;
You can’t perform that action at this time.
0 commit comments