File tree Expand file tree Collapse file tree 2 files changed +12
-3
lines changed Expand file tree Collapse file tree 2 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,8 @@ use hal::pac;
3030
3131use embedded_hal:: delay:: blocking:: DelayUs ;
3232
33+ include ! ( "secrets.rs" ) ;
34+
3335/// The linker will place this boot block at the start of our program image. We
3436/// need this to help the ROM bootloader get our code up and running.
3537#[ link_section = ".boot2" ]
@@ -127,11 +129,9 @@ fn main() -> ! {
127129 // ACK on pin x (GPIO10)
128130 ack : pins. gpio10 . into_mode :: < hal:: gpio:: FloatingInput > ( ) ,
129131 } ;
130- let ssid: & str = "SSID" ;
131- let passphrase: & str = "Passphrase" ;
132132
133133 let mut wifi = esp32_wroom_rp:: wifi:: Wifi :: init ( spi, esp_pins, & mut delay) . unwrap ( ) ;
134- let result = wifi. join ( ssid , passphrase ) ;
134+ let result = wifi. join ( SSID , PASSPHRASE ) ;
135135 defmt:: info!( "Join Result: {:?}" , result) ;
136136
137137 defmt:: info!( "Entering main loop" ) ;
Original file line number Diff line number Diff line change 1+ //
2+ // secrets.rs - stores WiFi secrets like SSID, passphrase, etc shared across
3+ // all example applications
4+ //
5+
6+ use heapless:: String ;
7+
8+ const SSID : & str = "ssid" ;
9+ const PASSPHRASE : & str = "passphrase" ;
You can’t perform that action at this time.
0 commit comments