here's a quick and dirty parametric pulley that would probably work fine:




// quick and dirty pulley

$fn=75;

h=5; // height of pulley
d=10; // diameter of pulley
ch=2; // diameter of central hole

difference() {
union (){
cylinder(d1=d/3, d2=d, h=h/2);
mirror([0,0,1]) cylinder(d1=d/3, d2=d, h=h/2);
translate([0,0,-h/2]) cylinder(d=d/2,h=h);
} // end union
translate([0,0,-h/2])cylinder(d=ch, h=h);
} // end difference
All dimensions are in millimetres.

If I could be bothered to look up how you generate and size a torus, it would be fewer lines still and a lot more like the original. :-)

with a torus, you simply create a cylinder and remove the torus from the middle and put the spindle hole through the centre.
That's just 3 lines and a difference.