First, I'll answer your posting, Paul, and then I'll show in detail how I once built a very good and safe coil winding machine from a scrapped dot-matrix printer stepper motor, that could be revived as a PIC project imho. On Sun, 26 Jul 1998, Paul B. Webster wrote: > Peter L. Peres wrote: > > > I deduce from the use of the word 'motor' in the original posting that > > the speed of the unit might slightly exceed the capability of micro- > > switches. > > I wouldn4t have thought the winding bobbin was directly driven by the > motor, so it shouldn4t be *that* fast. My presumption was that the > lifetime of a *reed* switch would cover the number of turns on a > reasonable number of custom-made transformers or whatever is being > considered. Hmm. Assuming 1E6 life, and 1000 turns total per unit to be done, the switches (being two of them) would be about dying after 700 units done. Ok, that's a lot for amateur use, but then if one has very few to do, then one can wind by hand and count ;) Also, I suppose that the user would go on hearing click-click click-click in his head for a long time after stopping the unit. > Actually, I made further assumptions. The reference to the need to > count back suggested that the number of turns was critical. This > further implies the number is relatively low and not particularly fast. > The tone of the posting suggested a non-commercial application (i.e., > you don4t cut costs on sensors on factory equipment ;-). The one sound use for counting back on windings is when doing accurate balanced transformers and hybrids for high-end valved audio. Nobody winds 600 ohm bal/unbal transformers by hand anymore. Also, metal detector loops, but those are done by hand on a jig due to size ;) - snip - > I think of coil-winding machines in the same fashion as lathes (comes > from using one for the other) in which environment optical sensors are > a no-no! imho, 2 big mistakes here: 1. Lathes are NOT coil-winding machines, unless the shaft can be equipped with a torque limiter. This is not a matter for joking or experimenting, take it very seriously. This includes small table lathes, unless hand-driven. Foot-driven ones are dangerous for coil winding. Also, no lathe should EVER be operated with an improvised jig to hold ANYTHING in it, unless the jig is correctly machined and tested for strength. Human-operated lathes are among the most dangerous work machines in use. They have all the work piece and the tool exposed to touch and in case of accidental fragmentation the probability that the operator is hurt is in the 30-40% range. If, additionally, the operator can be pulled by a tether (such as, winding wire) to the moving parts, things can get even worse. Very, very, very bad. 2. Optical sensors are used a lot in lathes, both reflective and transmissive, but only in locations where they are capsulated and protected from debris. Hall sensors are 'out' near the parts and work head in most fine mechanics part processing machines because many times pieces and materials get to be processed that cannot be exposed to magnetic fields of any kind, or are themselves strongly magnetic, and the sensing tolerance of hall sensors is not good enough. Instead differential HF proximity (Q) sensors are used, and more recently, low power laser-based sensors that can be placed pretty far from the work piece and head (in CNC only). Precision position sensors with great travel are almost always optical (quadrature or Gray using Moire effect, precision-geared to the moving part), and there is no replacement in sight. Most optical sensors use infrared, except high precision, which use visible but are totally capsulated. Last, I'd like to say that I once made a coil winding machine using a large stepper motor from an old printer. It worked out to be very good, durable, simple to build, and could be a PIC project. The motor was driven by a 555 timer, a CD4017 decoded decade counter used to count to 8 (obtained by connecting the 9th output to the reset pin of the 4017), and 4 Darlington transistors. 8 1N4148 diodes turned the 8-phase output from the 4017 into 4-phase half-stepping drive (chosen for smoother torque) for the motor. Power was 12 Vdc / 0.8 A or so, and the machine was very simple mechanically, yet powerful enough to wind 1 mm wire on a 25 mm core. The speed range was small but the stepper motor gave constant speed (unlike the runaway of an uncontrolled DC motor), solid torque, including holding torque, and is an inherent torque limiter, all this without using any kind of gears. The speed control was a potentiometer in the 555 circuit. Its switch would cut out the output of the 555 completely by opening the charge cap. resistor circuit completely. This gave stopped motor+holding torque, without glitches at switching. To reduce the torque, I simply turned the bench PSU voltage that powered this unit down to 9 or 6 V. The circuit continued to work well, with some speed change from the 555, and lower max. speed. The motor was biphase (6 wires, 2 center-tapped coils), and I used BDX53 Darlingtons and 1N4007 kickback damper diodes for each phase coil. Mechanically, I used a piece of 1mm mild steel sheet to hold the motor in a small desk vise. The sheet was cut in a rectangular piece as wide as the motor and three times longer. The sheet was screwed to the motor using its mount holes at one end of the sheet and the protruding 'tail' of the sheet was twisted 90 degrees to have the axle parallel with the desk edge when the lower end was held in the vise. The motor would rest on the tail end of the vise by bending the sheet towards the desk. The electronics were on a bread-board and connected to the bench PSU and to the motor, the latter using the original connector from the printer. Jigs to hold coils were affixed with 2 or 4 machine screws to the cylindrical aluminium hub that was originally on the motor shaft. I just bored and threaded the 4 holes symmetrically placed on a circle at the front end of the hub, for 3 mm machine screws. I used to make jigs out of rigid PVC tubing, cardboard and Balsa wood. I did not use a counter, there was a paint dot on the hub ;) The shaft attained 4-5 rot/sec (300 rpm) which is easy to count ;). This could be a PIC project too. A PIC and a ULN 2803 would be all that's needed. And it's MUCH safer than a misused electric drill or lathe. hope this helps, and sorry for the long posting, Peter