fix rotated bottom modules

This commit is contained in:
andreika-git 2022-03-28 10:29:04 +03:00
parent 911aa94fcf
commit a053c6f79e
1 changed files with 3 additions and 1 deletions

View File

@ -309,7 +309,9 @@ with open(frame_path + "/" + frame_name + "-BOM.csv", 'r') as bom_f:
# add module gerbers
module_path = "modules/" + module_name + "/" + module_rev
print_module(module_unique_name, module_path, module_name, board_cfg_path, 0, isBottom)
irot = int(float(rot) + 360.0) % 360
# inverse rot (CW<->CCW) for bottom modules
rot = -float(rot) if (isBottom) else float(rot)
irot = int(rot + 360.0) % 360
rotated = ("*rotated" + str(irot)) if (irot != 0) else ""
if (isBottom):
rotated += "*flippedV"