diff --git a/demo-esp32.xcodeproj/project.xcworkspace/xcuserdata/xinceioskaifa.xcuserdatad/UserInterfaceState.xcuserstate b/demo-esp32.xcodeproj/project.xcworkspace/xcuserdata/xinceioskaifa.xcuserdatad/UserInterfaceState.xcuserstate index 697abcd..bf8283b 100644 Binary files a/demo-esp32.xcodeproj/project.xcworkspace/xcuserdata/xinceioskaifa.xcuserdatad/UserInterfaceState.xcuserstate and b/demo-esp32.xcodeproj/project.xcworkspace/xcuserdata/xinceioskaifa.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/demo-esp32/ContentView.swift b/demo-esp32/ContentView.swift index 4049ae3..091e5dd 100644 --- a/demo-esp32/ContentView.swift +++ b/demo-esp32/ContentView.swift @@ -236,6 +236,22 @@ struct ContentView: View { private var wifiConfigForm: some View { VStack(spacing: 20) { + Button(action: { + if let url = URL(string: "App-Prefs:root=PERSONAL_HOTSPOT") { + UIApplication.shared.open(url) + } + }) { + HStack { + Image(systemName: "personalhotspot") + Text("开启个人热点") + } + .frame(maxWidth: .infinity) + .padding() + .background(Color.orange) + .foregroundColor(.white) + .cornerRadius(8) + } + Button(action: { viewModel.scanWiFi() }) {