From 06812a1c524c3cb9aaee68b36690331d8a362960 Mon Sep 17 00:00:00 2001
From: iggy <iggy@muc.ccc.de>
Date: Mon, 5 Jun 2023 00:13:17 +0200
Subject: [PATCH] sim: added missing fake stubs for ctx.arc and positional
 captouch (fake fakes for those)

---
 sim/fakes/ctx.py      | 4 ++++
 sim/fakes/hardware.py | 7 +++++++
 2 files changed, 11 insertions(+)

diff --git a/sim/fakes/ctx.py b/sim/fakes/ctx.py
index 9b9a3365dd..f5606dbd73 100644
--- a/sim/fakes/ctx.py
+++ b/sim/fakes/ctx.py
@@ -122,3 +122,7 @@ class Ctx:
     def fill(self):
         self._emit(f"fill")
         return self
+
+    def arc(self, x, y , radius, arc_from, arc_to, direction):
+        self._emit(f"arc {x} {y} {radius} {arc_from} {arc_to} {direction}")
+        return self
\ No newline at end of file
diff --git a/sim/fakes/hardware.py b/sim/fakes/hardware.py
index c28e68eabb..5d5128dd3d 100644
--- a/sim/fakes/hardware.py
+++ b/sim/fakes/hardware.py
@@ -396,3 +396,10 @@ def get_captouch(a):
     _sim.process_events()
     _sim.render_gui_lazy()
     return _sim.petals.state()[a]
+
+#TODO(iggy/q3k do proper positional captouch)
+def captouch_get_petal_rad(a):
+    return 0
+
+def captouch_get_petal_phi(a):
+    return 0
\ No newline at end of file
-- 
GitLab