Commit 3ed7be8
committed
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
Signed-off-by: Andrew Leech <[email protected]>1 parent f3dd486 commit 3ed7be8
2 files changed
+7
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
649 | 649 | | |
650 | 650 | | |
651 | 651 | | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
652 | 658 | | |
653 | 659 | | |
654 | 660 | | |
| |||
686 | 692 | | |
687 | 693 | | |
688 | 694 | | |
689 | | - | |
690 | | - | |
691 | | - | |
692 | | - | |
693 | 695 | | |
694 | 696 | | |
695 | 697 | | |
| |||
| 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