Modified gear gadget

This forum is for users to submit their own gadgets to the community
tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Modified gear gadget

Post by tkern »

I am modifying the gear maker gadget like in the pdf 'Constructing a gear in Aspire or VCarve Pro'
by Mike Turner. Almost done but can not find how to group all the teeth in the Tooth layer, so the
user will have to enable only the Tooth layer and then select and group.
Attachments
Gear_Maker_Mod.zip
(7.13 KiB) Downloaded 110 times

User avatar
jimandi5000
Vectric Wizard
Posts: 1050
Joined: Wed Mar 11, 2015 6:50 pm
Model of CNC Machine: Home Made 60 x 120
Location: North Houston Tx.
Contact:

Re: Modified gear gadget

Post by jimandi5000 »

tkern wrote:
Mon Apr 11, 2022 6:37 pm
I am modifying the gear maker gadget like in the pdf 'Constructing a gear in Aspire or VCarve Pro'
by Mike Turner. Almost done but can not find how to group all the teeth in the Tooth layer, so the
user will have to enable only the Tooth layer and then select and group.
Hi tkern,

Great job on the gadget. Let me know if I can help.
Thanks,
Jim

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

Thanks.
In the gear gadget code like :
local ctr_pos = MyMirrorContour:GetTailPosition()
local span
span, ctr_pos = MyMirrorContour:GetNext(ctr_pos)
ArcSpan = DrawArC(job, span.EndPoint2D, span2.EndPoint2D, Point2D(origin_off.x,origin_off.y), "Gear")
local test
test = MyMirrorContour:AppendContour(ArcSpan)
test = MyContour:Reverse ()
test = MyMirrorContour:AppendContour(MyContour)

was used to group the objects.
I could not get this code to work or find an example in the SDK i could understand.

User avatar
jimandi5000
Vectric Wizard
Posts: 1050
Joined: Wed Mar 11, 2015 6:50 pm
Model of CNC Machine: Home Made 60 x 120
Location: North Houston Tx.
Contact:

Re: Modified gear gadget

Post by jimandi5000 »

tkern wrote:
Mon Apr 11, 2022 7:29 pm
Thanks.
In the gear gadget code like :
local ctr_pos = MyMirrorContour:GetTailPosition()
local span
span, ctr_pos = MyMirrorContour:GetNext(ctr_pos)
ArcSpan = DrawArC(job, span.EndPoint2D, span2.EndPoint2D, Point2D(origin_off.x,origin_off.y), "Gear")
local test
test = MyMirrorContour:AppendContour(ArcSpan)
test = MyContour:Reverse ()
test = MyMirrorContour:AppendContour(MyContour)

was used to group the objects.
I could not get this code to work or find an example in the SDK i could understand.
Hi tkern,
I too am having issues with these functions. I have a email asking the support team about these functions.
Thanks,
Jim

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

The Vectric gadgets is the most fun programming environment I have tried.
I use Notepad++ ( which has syntax highlighting and auto completion for the lua
language) and then select all, copy and paste in Vectric. The results of calculations
can be displayed by MessageBox function and checked by Vectric measure or
Draw Arc tools.
I am working on Mike's internal gear design. After that is completed I will give
grouping objects another try.

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

I am modifying the gear maker gadget like in the pdf 'Constructing an internal gear in Aspire or VCarve Pro'
by Mike Turner for internal gears. Almost done but can not find how to group all the teeth in the Toothint layer, so the user will have to enable only the Toothint layer and then select and group.
Attachments
Gear_Maker_Int.zip
(7.25 KiB) Downloaded 89 times

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

Can not generate good tool path with Gear_Maker_Int, needs more work.

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

Gear_Maker_Int OK now. Still have to use join open vectors tool in Edit Objects.
Attachments
Gear_Maker_Int.zip
(7.26 KiB) Downloaded 84 times

User avatar
adze_cnc
Vectric Wizard
Posts: 4327
Joined: Sat Jul 27, 2013 10:08 pm
Model of CNC Machine: AXYZ 4008
Location: Vancouver, BC, Canada

Re: Modified gear gadget

Post by adze_cnc »

Some observations:

I'd expect (since no dimensions for anything are asked for) that when running the gadget on an inch job or a metric job (with the same input parameters) that the resulting gear would be the same size, etc. Especially as there is a line that sets "MetriC" to 25.4 if the job in in mm. That does not appear to be the case.

Dialog reporting maximum bit size:
 
Job in inches: max bit 0.1462... inches
Job in inches: max bit 0.1462... inches
 
Job in mm: max bit 2.5588... inches (if you divide by 25.4 you do not get 0.1462... inches)
Job in mm: max bit 2.5588... inches (if you divide by 25.4 you do not get 0.1462... inches)
 
Toothed portion different sizes if inches or mm:
 
Job in inches: size of inner toothed object
Job in inches: size of inner toothed object
 
Job in mm: size of inner toothed object. Again, dividing by 25.4 does not give the same result as the inch version.
Job in mm: size of inner toothed object. Again, dividing by 25.4 does not give the same result as the inch version.
 
Trying to cut resultant teeth with 1/8" cutter:
 
Job in inches: toolpath using 1/8" cutter
Job in inches: toolpath using 1/8" cutter
 
Job in mm: toolpath using 1/8" cutter
Job in mm: toolpath using 1/8" cutter
 
As for the gear teeth needing to be joined. I haven't looked too closely but are you continually adding things to the same contour so that when the last thing added all joins itself together?

EDIT: for the maximum bit size for the inch job I didn't included the parameters in the screen but trust me they were the same and the metric job.

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

HI, I just tried to modify the gear gadget to work with inches so i may have coded so that
would not work with metric.

Here is code for one of the four arcs in the first line.:

local MyContour = DrawArC(job,p8,p9,p,"Tooth")
local MyMirrorContour = MyContour:Clone()
local Rotation = 360/g_NoTeeth
local Teeth = {}
local TeethA = {}
Teeth[1] = MyMirrorContour
Refresh (job,Teeth[1],"Tooth")
for i=2,g_NoTeeth do
Teeth = MyMirrorContour:Clone()
Rotate (job, Teeth, Point2D(origin_off.x,origin_off.y), Rotation)
Rotation = (360/g_NoTeeth) * i
Refresh (job,Teeth,"Tooth")
end
Same code for each arc.

I am new to lua and vectric sdk and though that modifying the gear gadget
by following Mike's excellent pdfs would be a good first project.

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

Here is a gear rack gadget and the external gear gadget with lines
and circles removed.
Attachments
Gear_Maker_Rack.zip
(6.79 KiB) Downloaded 85 times
Gear_Maker_Mod.zip
(7.13 KiB) Downloaded 97 times

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

To round the the sharp corners in internal and rack gears the Radius All Corners gadget
can be used from https://redirect.viglink.com/?format=go ... rs.vgadget

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

Here is the link to constructing gears pdfs by Mike Turner
viewtopic.php?t=29084

tkern
Posts: 24
Joined: Fri Mar 25, 2022 3:35 pm
Model of CNC Machine: cncest

Re: Modified gear gadget

Post by tkern »

All files now make continuous contours so no need to join.

Largest diameter of bit is displayed in Layer 1 instead of message box.

If using metric job need to enter Backlash allowance in metric so .01 in
inches would be .254 in metric job to get equivalent results.
Attachments
Gear_Maker_Rack.zip
(7.68 KiB) Downloaded 124 times
Gear_Maker_Mod.zip
(7.94 KiB) Downloaded 116 times
Gear_Maker_Int.zip
(8.1 KiB) Downloaded 111 times

User avatar
FixitMike
Vectric Wizard
Posts: 2173
Joined: Sun Apr 17, 2011 5:21 am
Model of CNC Machine: Shark Pro Plus (retired)
Location: Burien, WA USA

Re: Modified gear gadget

Post by FixitMike »

Thank you for turning my instructions into usable gadgets.
Mike
Good judgement comes from experience.
Experience comes from bad judgement.

Post Reply