Page 1 of 2

How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 3:04 pm
by ifohancroft
Hi,

I have a FreeCAD document, that has two sketches, each of them looking like this:
one.png
one.png (9 KiB) Viewed 863 times
Together, from the top, they look like this:
two.png
two.png (9.08 KiB) Viewed 863 times
From the right side, they look like this:
three.png
three.png (8.2 KiB) Viewed 863 times
I want to rotate the second sketch so from the side, they will look like this:
four.png
four.png (8.63 KiB) Viewed 863 times
However, instead, when I rotate the second sketch on the X axis by 5 degrees, I get this:
five.png
five.png (8.85 KiB) Viewed 863 times
I presume this happens because the second sketch gets rotated around the middle as opposed to by the side.

How do I rotate it to achieve the result I want?

I will upload the FreeCAD file as an attachment in the next comment.

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 3:05 pm
by ifohancroft
Here is the FreeCAD file:
Curve-Test.FCStd
(15.08 KiB) Downloaded 27 times

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 3:26 pm
by bejant
In the Placement widget (not the Placement Properties in the Data tab) first tick "Apply Incremental Changes" to True, then change the Center, and finally do the Rotation.

Image


https://www.freecadweb.org/wiki/Tasks_Placement

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 3:28 pm
by papyblaise
hi it's that you went :?: : you have to type the position of the hinge

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 5:40 pm
by ifohancroft
@papyblaise Thank you! That worked. Not sure why I couldn't get it to work earlier. Btw the right position is 9.525, not 9.75.

@bejant Thank you! Maybe I'm an idiot but I cannot get your method to do anything. I may have a problem understanding how the placement dialog works or something:

1. After I check Apply Incremental Changes, do I hit Apply or Ok?
2. After I have enabled Apply Incremental Changes (without hitting Apply or OK) I change the Y of the center to -9.525.
3. Then I change the rotation angle but nothing seems to move?! I thought maybe there is no live preview and I need to hit OK, however even after I do, there is still nothing changed?! I thought maybe I then need to rotate via the Attachment Angle in the Data Tab but it rotates as if I haven't do anything in the Placement Widget.

What am I failing to understand or do?

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 6:48 pm
by Vincent B
A easy way is to use a datumplane.
choose an edge and make a datumline, make a datumplane with it.
rotate it on the right axle as needed.
Then map a sketch on the datumplane and draw the next sketch.

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 8:45 pm
by papyblaise
A easy way is to use a datumplane.
yes but the question is not to draw a sketch as an angle , but I have two sketch on the same plan : how to rotate one around a line of the second

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 9:09 pm
by Vincent B
La fin justifie les moyens. :D

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 9:30 pm
by ifohancroft
@GlouGlou Thank you! That's a good idea too. I keep forgetting about datum planes.

@papyblaise What GlouGlou said also works for me. I should have probably posted what I want to do that I need this step for.

I have found an easier way that works for me. Sketching the side profile, then padding towards the back and then creating the holes.

Now I need to figure out an easy way to also create such "strips" to the sides, with also 5 degree angle between the "strips". I have figured out how to do it but after I finish it, I need to check if there is a better way.

Re: How to rotate a sketch, using its side as axis?

Posted: Thu Jan 16, 2020 11:04 pm
by bejant
ifohancroft wrote: Thu Jan 16, 2020 5:40 pm 1. After I check Apply Incremental Changes, do I hit Apply or Ok?
No, just tick the Apply Incremental Changes..." tick box to True (do this first).

ifohancroft wrote: Thu Jan 16, 2020 5:40 pm 2. After I have enabled Apply Incremental Changes (without hitting Apply or OK) I change the Y of the center to -9.525.
I think you want to make Y = 9.525 (no negative sign).

ifohancroft wrote: Thu Jan 16, 2020 5:40 pm 3. Then I change the rotation angle but nothing seems to move?! I thought maybe there is no live preview and I need to hit OK,
You should be changing the Attachment Offset using the Placement widget, don;t think I was clear before. In the Placement widget, above the "Apply Incremental Changes..." tickbox, change the Axis to Y and then change the Angle field to whatever angle you need. There is a live preview so you should see the Sketch rotate as you change the Y angle value.

I trued to use your file but got a message: "Cannot compute Inventor representation for the shape of ((the file name)" so I just tried using my own new file.

OS: Ubuntu 18.04.3 LTS (ubuntu:GNOME/ubuntu)
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.19. (dated 2020-01-05)
Build type: Release
Python version: 3.6.9
Qt version: 5.9.5
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)