diff --git a/app/src/main/java/com/example/medilightv2android/AppState.kt b/app/src/main/java/com/example/medilightv2android/AppState.kt index 6a56153..904c308 100644 --- a/app/src/main/java/com/example/medilightv2android/AppState.kt +++ b/app/src/main/java/com/example/medilightv2android/AppState.kt @@ -96,7 +96,8 @@ class AppState(private val context: Context) { fun startFromHome() { sensorMode = SensorMode.PIEZO storage.sensorMode = SensorMode.PIEZO - currentScreen = if (isDeviceConnected) AppScreen.PIEZO_MONITORING else AppScreen.DEVICE_SCAN + // 페어링 완료 상태에서도 Personalization부터 시작해야 함 — Monitoring 직행 버그 fix + currentScreen = if (isDeviceConnected) AppScreen.PIEZO_PERSONALIZATION else AppScreen.DEVICE_SCAN } fun selectSensor(mode: SensorMode) { diff --git a/app/src/main/java/com/example/medilightv2android/ui/views/connection/DeviceScanView.kt b/app/src/main/java/com/example/medilightv2android/ui/views/connection/DeviceScanView.kt index ec68846..e9eda2b 100644 --- a/app/src/main/java/com/example/medilightv2android/ui/views/connection/DeviceScanView.kt +++ b/app/src/main/java/com/example/medilightv2android/ui/views/connection/DeviceScanView.kt @@ -259,6 +259,21 @@ fun DeviceScanView(appState: AppState) { TroubleshootItem("4.", "Try restarting the device") } } + // DEV: BLE 없이 측정 모드 진입 — 디자인 작업용 + if (appState.isDevMode) { + Spacer(modifier = Modifier.height(16.dp)) + Button( + onClick = { + appState.isDeviceConnected = true + appState.currentScreen = com.example.medilightv2android.AppScreen.PIEZO_PERSONALIZATION + }, + modifier = Modifier.fillMaxWidth().height(48.dp), + shape = RoundedCornerShape(12.dp), + colors = ButtonDefaults.buttonColors(containerColor = MlPrimary.copy(alpha = 0.15f)) + ) { + Text("Enter Measurement Mode (Dev)", color = MlPrimary, fontWeight = FontWeight.SemiBold) + } + } } } else { LazyColumn(