Merge branch 'master' into pio
This commit is contained in:
@ -59,7 +59,7 @@ async fn main(spawner: Spawner) {
|
||||
// To make flashing faster for development, you may want to flash the firmwares independently
|
||||
// at hardcoded addresses, instead of baking them into the program with `include_bytes!`:
|
||||
// probe-rs-cli download 43439A0.bin --format bin --chip RP2040 --base-address 0x10100000
|
||||
// probe-rs-cli download 43439A0.clm_blob --format bin --chip RP2040 --base-address 0x10140000
|
||||
// probe-rs-cli download 43439A0_clm.bin --format bin --chip RP2040 --base-address 0x10140000
|
||||
//let fw = unsafe { core::slice::from_raw_parts(0x10100000 as *const u8, 224190) };
|
||||
//let clm = unsafe { core::slice::from_raw_parts(0x10140000 as *const u8, 4752) };
|
||||
|
||||
@ -78,16 +78,11 @@ async fn main(spawner: Spawner) {
|
||||
let state = singleton!(cyw43::State::new());
|
||||
let (net_device, mut control, runner) = cyw43::new(state, pwr, spi, fw).await;
|
||||
|
||||
spawner.spawn(wifi_task(runner)).unwrap();
|
||||
|
||||
control.init(clm).await;
|
||||
control
|
||||
.set_power_management(cyw43::PowerManagementMode::PowerSave)
|
||||
.await;
|
||||
|
||||
//control.join_open(env!("WIFI_NETWORK")).await;
|
||||
control.join_wpa2(env!("WIFI_NETWORK"), env!("WIFI_PASSWORD")).await;
|
||||
|
||||
let config = Config::Dhcp(Default::default());
|
||||
//let config = embassy_net::Config::Static(embassy_net::Config {
|
||||
// address: Ipv4Cidr::new(Ipv4Address::new(192, 168, 69, 2), 24),
|
||||
@ -106,8 +101,12 @@ async fn main(spawner: Spawner) {
|
||||
seed
|
||||
));
|
||||
|
||||
unwrap!(spawner.spawn(wifi_task(runner)));
|
||||
unwrap!(spawner.spawn(net_task(stack)));
|
||||
|
||||
//control.join_open(env!("WIFI_NETWORK")).await;
|
||||
control.join_wpa2(env!("WIFI_NETWORK"), env!("WIFI_PASSWORD")).await;
|
||||
|
||||
// And now we can use it!
|
||||
|
||||
let mut rx_buffer = [0; 4096];
|
||||
|
Reference in New Issue
Block a user