The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
fix(device): Focus touch-to-talk names the agent on the face
0xdiego25ac3acef83426
diff --git a/devices/harness-device/firmware/main/ui/habitat/ui_habitat.c b/devices/harness-device/firmware/main/ui/habitat/ui_habitat.cindex 11074dcd5..155c62eec 100644--- a/devices/harness-device/firmware/main/ui/habitat/ui_habitat.c+++ b/devices/harness-device/firmware/main/ui/habitat/ui_habitat.c@@ -2716,7 +2716,9 @@ void habitat_touch(bool down, int x, int y, uint32_t now)ht_gesture_guard(&gesture, now);if (s.connected && !s.loading && active()) {ESP_LOGI("habitat", "focus touch: start voice");- dispatch((action_t){.kind = A_VOICE});+ // Built as the old microphone's was: make_action names the agent on the face, and+ // main-surface voice without a recipient is dropped.+ dispatch(make_action((hit_t){.action = A_VOICE}));}} else if (result == HT_TOUCH_TAP && pressed_action.kind == A_PET &&(surface || s.view == VOICE || s.view == SELECTION)) {diff --git a/devices/harness-device/firmware/test/test_touch_ui.py b/devices/harness-device/firmware/test/test_touch_ui.pyindex a4838c8a4..b60ebbfc2 100644--- a/devices/harness-device/firmware/test/test_touch_ui.py+++ b/devices/harness-device/firmware/test/test_touch_ui.py@@ -1771,6 +1771,7 @@ int main(int argc, char **argv) {workspace_setup(); ht_character_select(&character, HT_CHARACTER_FOCUS); strcpy(s.agents[0].engine, "claude");ui_project_emit(s.agents[0].id, "sess", "summary", "Retry queue shipped.", "Retry queue shipped.");scene_take(); tap(1000, at[k][0], at[k][1]); assert(starts == 1 && s.view == VOICE);+ assert(!strcmp(target, s.agents[0].id)); // to the agent on the face: none is dropped on glass}}// And on a face with nothing yet to say.@@ -1788,7 +1789,7 @@ int main(int argc, char **argv) {habitat_touch(true, 233, 260, 1000);habitat_touch(true, 233 + drift / 2, 260 + drift, 1000 + held / 2);habitat_touch(false, 233 + drift / 2, 260 + drift, 1000 + held);- assert(starts == 1 && s.view == VOICE);+ assert(starts == 1 && s.view == VOICE && !strcmp(target, s.agents[0].id));}workspace_setup(); ht_character_select(&character, HT_CHARACTER_FOCUS); scene_take();habitat_touch(true, 233, 260, 1000); habitat_touch(true, 233, 300, 1100); habitat_touch(false, 233, 300, 1200);