Hello.
Years ago a benchtop CNC coil winder was purchased. It has specific software for guitar/bass. Recently the turn count has been off. This started a journey into finding replacement parts and understanding what is in the machine. Discovered something called a Rotary Encoder. Currently have replacement on order. The machine is not supported by the builder , can not buy a new machine. The machine from what I can tell runs on a unmarked Arduino UNO with a pic18f2550(can't find a new board that looks like a exact match ) and a Pololu simple motor controller (STM32) that is obsolete. I did find one of the last boards from Pololu for a backup. My goal is to keep this machine running and to harness this info on the chips needed to put the information on new boards to build new machines. I do not know if the chip information is protected , how to check for protection or how to harness the information on the chips. I have tried to prepare for all the buying parts and the interface tools for each chip. I really just do not know how to do this. The STM looks like it might be easier than the pic chip. Due to these chips being non replaceable I am a bit nervous as a noob / non coder poking around these chips and worry about doing something wrong and bricking my machine. My guess is the machine code PC program is written in G code and would be difficult to find someone to recreate the software from scratch and get a package of software/controllers designed. It's very nice to have a program on a PC and view the program on a 32inch screen rather than a small touch screen or a fancy calculator type input. I'm really trying to avoid getting knocked back to the 1950's building a hand winder with a motor/speed control and hand guiding the wire. I can build the machine , no problem. Laser cut the parts I need from acrylic and get metal parts from Amazon. Would like to build a few more machines for the shop so I do not have to keep switching wire sizes on one machine.
Some pictures of the parts and also of the whole machine would be helpful.
I don't think Arduino UNO ever used a pic18f2550 as its processor, so the board might be a custom one. If that is the case specifications for the coil winder in general would be useful.
I am not very musically inclined, what do you need a coil winder for on a guitar?
Dave P
Hi @night-winder,
Thank you for providing a good introduction to your project. I offer a few comments for discussion.
PIC18f2550 microcontroller is made by Microchip, who make hundreds (maybe thousands) of different microcontroller devices. The data sheet of the chip is dated 2009, so although it is still available, current technology has moved on.
I think it is very unlikely that it was ever used on an Arduino board, and I would guess the board you have, was custom made by the coil winder manufacturer, or by a subcontractor for the coil winder manufacturer. In which case, it would only be available as a 'spare', which is clearly unlikely if the machines have not been manufactured for a considerable time.
Microchip have had their own software development 'tools environment' since the company first started in the 1980s, so any attempt to access its programme, etc., would probably mean investing in their support tools, etc. I would generally advise against trying that route. Instead, I would suggest carefully watching and recording what the machine is doing, and use that as a 'draft recipe' for your new machine.
I don't know which motor controller board you are referring to, but my first guess is that it drives one or more brushed DC motors, possibly in conjuction with the rotary encoder you mention. By chance, this arrangement is reminiscent of some recent discussions on the forum, regarding the merits and issues of this approach for robots. Personally, I would look to employing stepper motors for an application that required a specific number of revolutions, but obviously this is a design choice, worthy of its own discussion, not an imperative.
I note you mention G code, which appears to be the de facto 'standard' for 'consumer' 3D printers, and probably elsewhere. I am not sure how well suited it is to the coil winding requirement, but I can see how it could be used to send a stream of commands to one or more motors. I also note that the 'consumer' 3D printers that I am aware of use stepper motors. Of course, it is necessary to generate a G code file for each different design. For a 3D print, this is usually performed by a 'slicer' programme, that converts a 3D CAD design into a series of 3D printer actions, but perhaps the coil winding requirement would be simple enough for the G code to be generated manually or by a simple prorgramme.
So, on the basis of the aims you state, I agree that it would be wise for you to start by designing a new independent machine, whilst keeping your present machine in working order.
Perhaps it would be useful for you to present a sketch of your intended machine, clearly showing how the mechanism is intended to work. It might also be helpful to show a short video clip of the existing machine in action, if it helps to explain what needs to be achieved. (There is a short "How to show video" note on the righthand column of this page.) I am hopeful it would prompt a discussion with other forum contributors that you would find helpful.
I hope these comments are helpful. Good luck with your project, Dave
I'd start by diagnosing the turn-count problem before reverse-engineering anything.
Check the rotary encoder's output signals first. A logic analyzer can help verify the pulses. Compare the counted pulses with the actual turns. Also check the encoder coupling for slippage.
Identify the exact Pololu controller model. Document the board connections and take clear photos. Back up accessible configuration files before experimenting.
Be careful with firmware extraction. Some protection settings can trigger a chip erase. Don't experiment on your only working controller.
For replacement boards, identify every IC by its manufacturer part number. Check the datasheets, package types, and pin compatibility before choosing substitutes. For IC sourcing, Unikeyic helps buyers verify MPNs, package options, datasheets, stock status, and RFQ details.
You may not need to recover every chip's firmware. First, establish which board handles encoder counting, motor control, and PC communication.
Does the PC software still communicate with the machine? If it does, preserving that interface could simplify a replacement controller. Understanding the signals and communication protocol may be enough to recreate the system.
Everything is working fine minus the turn count. The machine is over winding coils. I have a cheap $17 counter doing the work as of now. The new rotary encoders just arrived today.
Here is the back up board with the STM32. I also bought 5 back up chips since mouser has them and they are not expensive. Also bought a STM32 development tool
@thespamcatcher The coil winder is used for winding guitar/ bass pickups. The machine makes it quick and easy to design custom designs , not just the standard copys most pickup assemblers sell , fender/Gibson knock offs built using existing parts. We laser cut a lot of our own parts , machine and manufacturer alot of our own metal parts.
Top pic - MFD style split coil bass. Lots of calls asking if we could keep the MFD style alive. Now offer MFD in many more options than G&L ever did
Second pic - No one was making real P90 in Telecaster Neck size with Alnico magnets. We worked with our foundry and had custom bar mags in A2-5 along with UNO A5 made
Third Pic , MFD 51 in Neodymium for original fender p basses
Fourth pic - custom order 7 string Tony Iommi Monkey pickups in Thunderbird covers to be used as neck and middle in a ssh 7 string guitar
Fifth pic - No one was recreating Gibson Bicentennial pickups so the Thunderbird group on Talkbass forum requested these pickups to be offered. A lot of our business is making new pickups of designs not available elsewhere
@davee The 10mb limit does not allow for a quick 30 second vid in mp4 from my phone.
The machine itself is a basic coil winder. It's the software I'm worried about most I would like to control the machine with this software. I have seen free downloads for a extremely simplified version of this that runs on touch screen.
The software can be downloaded for free
https://www.ukcnc.net/downloads/s-cw-1-1-2/
Thank you to all that replied to my post. Very appreciated. Thank you for your input and assistance. All this electronics stuff is not my strong point at all.
Hi @night-winder,
I confess, I have never posted a video, but others have, usually using YouTube to host the video, and then copy the link into your forum message. My understanding is that you can make the video 'private', so that is not directly listed on YouTube, but is available to anyone who is given the link associated with it.
However, you have now posted some photos, which I found informative, as a useful starting point.
---------------
I noted your link to a programme, but unfortunately that programme is a Windows programme, that itself 'talks' to a programme running on the coil winder. I cannot see the source of either the Windows or coil winder machine, so I think you will find it difficult to use either in your own coil winder. Perhaps you could make an exact clone, but it would mean working 'blind', which would make debugging very difficult, and any modifications to the software, very tricky.
---------------
I should admit, I am ignoring a 'possible' approach, which seems to have hit the headlines in the last few days, of people using AI to reverse engineer and 'clone' entire programmes ... I do not have any experience to offer on this possibility, but I would suggest it is not yet 'mainstream'.
Summary, so far: If I wanted to build a coil winding machine, I would not personally contemplate either of the above routes at the moment.
------------------
At a guess, the front page of the Windows programme contains a handy calculator, based on simple arithmetic and wire geometry, which I suspect could replicated in a spreadsheet, and if necessary converted to a standalone programme.
At a further guess, I would imagine the Windows progamme would pass a few parameters, such as the number of turns of wire, to the PIC microcontroller in the machine itself. Then the PIC is responsible for all of the hard work, sending commands to power the motors.
--------------
I found the details on the Pololu card you show at https://www.pololu.com/category/94/pololu-simple-motor-controllers
This page starts with "The Simple Motor Controllers are versatile, general-purpose single-channel motor controllers for brushed, DC motors. ", which is what I expected.
I know it is possible to control brushed DC motors, but for tasks requiring a specific amount of rotation, I do not recommend it, especially as the rotation must be synchronised to a second motor for neat winding.
Brushless motors, which includes stepper motors, require more sophisticated electronics than brushed motors, which have been the 'traditional' norm for decades, but several major semiconductor companies have developed chips to drive brushless motors, which means that most of the sophistication is pre-packaged in a relatively cheap device.
----------------
I have also had a look at a couple of YouTube videos from 'amateur' attempts to wind pick up coils, which although very crude compared to your professional devices, offer some insight into the basic procedure.
So please correct any mistakes I am making, but oversimplfying, it seems, for each winding job, you are winding a single coil onto rectangular former, with typically several thousand turns of thin enamelled wire, say around 40AWG.
Looking at your photos, I think the former is being rotated by the larger DC motor, whilst the path of the wire is being controlled by stepper motor rotating a threaded rod, which in turn drives the wire position guide on a lever.
The speed of the DC motor can only be 'controlled' by applying/removing power, using a rotary encoder to monitor the rotation of the motor, and the microcontroller programme in the coil winder will be responsible for commanding the power on/off and analysing the rotary encoder. It will also need to command the steps to the stepper motor, to maintain a synchronisation between the winding action and the wire guide, if neat winding is required.
------------
Of course, I have absolutely no relevant experience, but my 'gut feeling' is that it is likely to be easier to construct your own machine, with similar mechanics, using stepper motors for both drives, since a stepper motor is directly commanded to perform each roatation of a small angle of its shaft. e.g. commonly, stepper motors are built to advance by 1.8 degrees per step, and hence will make 1 complete rotation after 200 full steps.
The time taken, and hence the rotation speed, and the number of rotations, is simply determined by the driving computer programme, assuming it is within the electro-mechanical limits of the motor and its driving electronics.
Thus, stepper motor systems are normally driven comfortably below their electro-mechanical limits, and for many purposes, the user 'assumes' the motor will do exactly what it is commanded to do.
In your case, this means you do not need a rotary encoder, with associated control loop software. However, a simple turn counter, perhaps the same as you have patched onto your present machine, might be a useful independent 'quality control', to detect any unexpected problems like driving the motor too fast or a bearing seizing. Hopefully, it will always report the number of turns is exactly the same as those requested.
--------
From the photo, it looks as if the winding guide motor is a 'smallish' NEMA17, which seems likely, as the rotation speed of the threaded rod will be much slower than that of the winding motor, and the mechanical load should be small.
I am less clear about the power required for the winding motor. I assume the wire will be very thin, so the force exerted upon it must be quite low, to avoid it snapping. I note that the winding motor appears to be relatively larger than the stepper motor, suggesting it might be higher power, I may be being misled by the photo.
If I guess, a single coil has 10,000 turns, then clearly you will want the winding speed to be as high as possible, to minimise the time taken. Here, using a stepper motor requires some care, in terms of choice of motor, power source, controller and software. On the positive side, it should be straightforward to synchronise the two motors, at any winding speed, since both are directly commanded. However, because the electrical power sent to the motor is a complex waveform, there are practical limits, so be prepared for some experimental work, and hopefully some useful advice from others.
---------------
As you can see, I have tried to guess some simple requirements ... any corrections or additions you can provide would be useful. e.g. what rotation winding speed do you require?
---------------
If you would like to investigate further, and are not familiar with stepper motors, I suggest you start by looking at Bill (@dronebot-workshop)'s excellent videos on the subject, which are listed on the following summary page:
https://dronebotworkshop.com/?s=stepper+motor
---------------
I hope that this waffle makes sense. There are many details associated with stepper motors that could be discussed, if you wish to take this further.
Best wishes and I hope you will succeed, Dave
@night-winder,
Welcome to the forum and you've brought a wonderfully mechanical robotic project to explore. I'd like to give my 2 cents worth hitting various things along the way.
The 10mb limit does not allow...
@davee is right. The most common and easiest way is to upload your MP4 to YouTube. If you have a gmail account, you already have a YouTube account. Here is a screenshot of mine.
If you're logged in to your account, you'll have the round circle (teal in my case) in the upper corner. Simply hit the "+ Create" button and upload a video. Answer a few questions. For the child question, DO say make it for children. Otherwise, YT will assume it has graphic material. 🤣 Save it as "Unlisted". This allows you to share a link which YT supplies. Simply paste it in your post here and it'll display as a YT window of your post. The link will look something like this, but don't include the quotes when you paste it:
"https://www.youtube.com/watch?v=vSQEHPcZX6Y"
This is sample of one of my videos showing a Windows program controlling a robot.
Back to your project...
I think @davee has hit on many aspects, that I'd like to echo... questions to you are bolded.
- It is unlikely that either the Windows program or the code on the machine is realistically decodable. They're both likely compiled programs, meaning they're in machine language with all useful comments and any descriptive variable and function names being replaced with binary gibberish. I too have not explored the AI "copying" of software and have no input on it, but if you really want to understand what is going on with the intent to modify going forward, that is of no use to you anyway.
- I see that the machine seems to have both motor types: stepper and what looks like a relatively large AC motor that had the encoder attached by the winder company (not the motor company).
- Seeing that they have both types and if we assume there was good engineering reason behind having all the complexity of both types, I logically assume:
- The winding motor is to getting high enough tension and speed where steppers might not be able to handle either well. What is the max speed of winding is AND is there a tension setting in the software?
- I would further guess that the encoder isn't so much to regulate the winding speed as much as it is to calculate where the feed stepper need to be lay the current wire path next to the last wire path. I'd guess its a one-way street. Is the speed of winding a software setting or is it a dial you can adjust in real time?
- I have no direct experience with these winders, but I have in the past watched YT of factories winding AND hobbyist that re-wind their RC plane electric motors and YT of Tesla winding their car motors. The automated ones are very fast!
- For settings on the software, I can see where you need.
- Speed
- Wire diameter
- Core dimensions - Things like root circumference, width, depth, etc.
- Number of turns
- (maybe) Tension
- I'm obviously missing something because your Windows program looks far more complex than just entering these values. Can you elaborate on what other things are needed? Or needed in your specific case?
- Was your machine made only for winding your pickups or is it a general purpose winder that could (for instance) handle larger diameter wire on say larger motors?
- If general purpose, what speeds, tensions, wire sizes do you need relative to what it is capable? This might allow you to go with simpler designs that only have stepper motors for both winding and placement.
- GCode - I doubt it runs on gcode as its far harder to convert the needed inputs into gcode versus just dynamically moving the head in relation to where the winder is. Besides if the winding motor is as I suspect not "encoded" to be at a position, but simply monitored as to its position, then gcode can't control it.
- Oh, you might also summarize your experience with:
- Windows programming using any software language.
- Arduino type programming.
- Working with electronic circuits, breadboards, soldering, etc.
- Designing mechanical hardware like CAD drawings if you have others machine your parts.
- 3D Printing experience if you intent to make parts yourself.
As a note - My experience with this forum, members are very friendly and helpful if you want to learn how to do things. If someone comes here to have members designing mechanical and electronic hardware, and software development FOR them, members will bail out. If it is for a product to be used commercially, members can be abusive or expect compensation for their efforts.
Good luck,
Inq
Hi @inq and @night-winder,
@inq has kindly provided a good deal of useful guidance. I have only one thought to add to his valuable contribution.
I, and probably @inq, are stabbing in the dark, with respect to the winder motor, as all we can see is an unlabelled cylinder, without even an easy way of establishing its physical size ... I suspect the photo is making it appear larger than reality, but this is a guess.
Re: @inq's suggestion ... what looks like a relatively large AC motor that had the encoder attached
I have a 'feeling' that it is a DC motor, possibly something like 12-18V. Main 'reason' for my feeling is that you are showing a Pololu simple motor controller, which the advert I referred to previously, states is a DC controller for all of its variants. Since it is not directly suitable for driving a stepper motor, the winding motor becomes the first suspect for its usage.
In addition, at a first glance, it has a similarity to the motor in my small Bosch battery drill, that I had to replace, after the original spat its brushes out of the cooling vent. These and similar looking motors, are widely advertised on AliExpress, usually without any identification markings.
But both of these thoughts are purely speculation on my part, and could easily be totally wrong. Some careful tracking with your eyes and a multimeter with a buzzer to indicate continuity, to draw out a circuit of the wiring between the boards would help to identify some of the basic approach.
-------
@inq has posed some essential questions for you to answer. As is often the case, a fully general purpose, or 'top spec' machine could easily become much more complex than is required for your purpose, so I recommend you take care to make a 'realistic' spec. For example, as @inq has mentioned, some 'professional' machines may wind at very high speed. Do you need a very high speed, or will a slower speed be adequate for your needs?
Best wishes, Dave
@night-winder,
I have a 'feeling' that it is a DC motor, possibly something like 12-18V. Main 'reason' for my feeling is that you are showing a Pololu simple motor controller...
For future reference, if I ever purport anything to do with electrical/electronics it is merely to goad my buddy @davee to action. He will always give you the best/strait scoop! He saves my bacon like clock-work.
... and he is also correct, I did seriously over estimate the size of the motor from images. To me, that felt like 100mm in diameter or better. Based on the part number of the encoder, I calculated the diameter of the motor to be 44mm.
It is scary what AI does for searches these days,
Popular 44 mm DC Motor Options & Specifications
• Brushed 775-Series Motor (e.g., Model NFP-RC-775SHP)
• Diameter / Length: 44 mm diameter, 66 mm body length
• Voltage / Speed: 12V to 24V DC; no-load speeds range from 3,800 RPM (at 24V) up to 20,000 RPM (at 18V)
• Torque: Stall torque ranges from 3,166 g·cm to 5,000 g·cm depending on the voltage variant.
Considering the reduction drive on that winder appears to be no higher than 2:1, the torque would be approximately the same as a common Nema 17 stepper motor. BUT, a stepper might do 1000 rpm reliably, your winder must run far faster.
What kind of speed are you needing (wanting)? If you are willing to settle for 1000 rpm the electrical/electronic portion of the project can be made quite simply. It would not need any detailed circuit board design or custom parts. It would only need:
- Stepper Motors ~$15 (2) 17HS19-2004S1
- Stepper Motor Drivers ~$3 (2) DRV-8825
- ESP32-S3 ~$7 (1) Microcontroller - Just about any microcontroller will do. I'm partial to the Espressif line of micros. This is the best one of those that would be able to handle anything you'd care to throw at it and has both WiFi and Bluetooth to connect to your Windows machine.
- Laptop Power Supply ~$16
- Miscellaneous bread board, DC-to-DC power converters, capacitors and small electronics parts <$10 total - That I might be able to specify purely from past experience (and @davee's help), but he'd be the last word on exactly what you'd need.
- Total: ~$80 in electrical/electronic parts
The software side will take you the longest even if you are an expert in all the phases I listed above and depending on all the other widgets and settings your images show besides the simple list I provided above, would be that much more complex (software wise).
Because of that, I suggest a cheap prototype. I wouldn't think the loads on such a system would be that high even in production. The fact that they used lots of aluminum extrusions, machine cap-head screws and lead-screws, I think is way overkill. Probably just to take the rigors of day laborers that would abuse the company's equipment. I'd think substantial 3D printed parts could be used in at least a working prototype. Instead of the lead-screw, a threaded rod could be used. Once you work all the kinks out of the software, using the prototype, you could then design parts in aluminum you felt were marginal in plastic.
Inq
A U tube video that might be of interest
Outstanding!!!
If you're wire windings are on this video's order of diameter, then a smaller stepper motor could easily be used. It would be significantly faster and likely able to reach at least 2000 rpm. Otherwise the video is exactly what I imagined. The only difference being I specified new components, and being able to digitally (software) control number of winds, core dimensions and being able to control and monitor via WiFi from the Windows machine.
Considering how simple his control mechanisms were (near none with mechanical limit switches), and the KISS principle is usually better, it begs the question what all the settings in your software actually do.
Inq
















