Commit 14cd272
stm32/main: Initialize network before boot.py to fix LAN instantiation.
Move mod_network_init() to run before boot.py instead of after, allowing
network interfaces like network.LAN() to be instantiated in boot.py.
The previous order caused failures when users tried to create network
interfaces in boot.py because the network subsystem wasn't initialized
until after boot.py completed. This change is safe because:
- LWIP is already initialized earlier in main()
- mod_network_init() only initializes the NIC list
- network.country() and network.hostname() still work correctly as
they just set global variables that are used later
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <[email protected]>
Signed-off-by: Andrew Leech <[email protected]>1 parent d6db47c commit 14cd272
2 files changed
+7
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
589 | 589 | | |
590 | 590 | | |
591 | 591 | | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
592 | 598 | | |
593 | 599 | | |
594 | 600 | | |
| |||
626 | 632 | | |
627 | 633 | | |
628 | 634 | | |
629 | | - | |
630 | | - | |
631 | | - | |
632 | | - | |
633 | 635 | | |
634 | 636 | | |
635 | 637 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
0 commit comments