Skip to content
Snippets Groups Projects
Commit f1bdd66b authored by mehtank's avatar mehtank
Browse files

Bugfix matrix multiplication with np.dot instead of *

parent 54365079
No related merge requests found
......@@ -3,6 +3,7 @@ from rocolib.api.composables.graph.Face import Rectangle as Shape
from rocolib.api.ports import AnchorPort
from rocolib.utils.dimensions import getDim
from rocolib.utils.transforms import Translate, RotateZ
from rocolib.utils.numsym import dot
class ServoMotor(FoldedComponent):
......@@ -18,7 +19,7 @@ class ServoMotor(FoldedComponent):
dz = getDim(s, "hornheight")
self.addFace(Shape("h", 0, 0))
self.setInterface("horn", AnchorPort(self, self.getGraph(), "h", RotateZ(a) * Translate([0,0,dz])))
self.setInterface("horn", AnchorPort(self, self.getGraph(), "h", dot(RotateZ(a), Translate([0,0,dz]))))
if __name__ == "__main__":
ServoMotor.test()
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment