-
Polarity Problem?
06/22/2020 at 21:55 • 0 commentsIn the log entry titled "Does it have to be pretty?", I mention the Polarity0/1 signals. The present ring modulator based system does not provide them. They are not used by the parallel interface, but would likely be handy to have available for other interfacing schemes.
I may restore the signals, I'm just not feeling motivated enough to make changes the breadboard right now.
-
Phase Matters
06/22/2020 at 15:02 • 0 commentsIt took a while, but I eventually noticed that the modulator's output signal zero-crosses had little in common with the sine-cosine zero-crosses. If only there was a way to shift them a little bit...
Oh, right. Analog, sine waves, phase shift! Only 45 degrees is needed, this shouldn't be too difficult. Many simulations later, I changed a few resistor values and added two capacitors and now the zero-crosses are all lined up.
The updated schematic/KiCAD project has been uploaded.
-
Analog Amusement
06/15/2020 at 17:52 • 0 commentsIn a very early incarnation of this circuit, the motors would take two steps in response to a single cycle control pulse. That happened because, even though the sine signal was only switched on for a half cycle, the cosine made a polarity change during that half cycle. Eventually, I realized that I needed to trigger the switches whenever either the sine OR the cosine made a zero-crossing. Another pair of comparators and some diode-transistor logic was added to the circuit, and single stepping became the norm.
A few weeks ago, a thread on .Stack reminded me of a fun bit of analog hardware called the ring modulator. It multiplies ine input signal by the other input signal, for a loose definition of multiply. Mostly, it is just interpreting the signs (not sines) of the inputs (sines). Whatever it does, the resulting output signal resembles a sine wave at twice the input frequency. With twice as many zero crossings, I need half the comparators. Out with the 339 quad, in with the 393 dual!
I'll modify my build the next rainy day, then post an update. Stay tuned!
-
And... Done?
03/12/2020 at 19:37 • 0 commentsSchematics and code are posted in the Files section. Had a dial indicator attached to an X axis cobbled together with regular threaded rod, with my PC moving it to and fro. The GCode had it moving +/-0.1 inches, and that is what it did.
I'll check back from time to time while hacking, sawing and sometimes hacksawing things. I'm certain that there will be some updates, improvements, and comments to add to this project.
Onward to the mechanical work! (First will be to replace the pictured threaded rod with Acme thread.)
-
Almost there
02/28/2020 at 01:45 • 0 commentsNow this becomes a coding project. Converting G-Code to a stream of symbols, seems simple enough. There's also keeping phases synchronized for smooth stepping, and adjusting the output for direction changes. Much to be done, I'll be back.
-
Does it have to be pretty?
02/17/2020 at 19:52 • 0 commentsJust posted the KiCAD schematic set. Oops, forgot to annotate a whole bunch of parts. I'll fix that. But, that is the circuit that is on my desk, spinning motors right now. The exception being R_Start1, it wasn't necessary for my oscillator to reliably start.
If the parallel port isn't for you, the interface signals are fairly simple.
Name In/Out Usage Direction In Selects either cosine or inverted cosine to control stepper direction. Run/Stop
X/Y/ZIn Switches the sine and the selected cosine signal on or off. WIN Out This signal goes high each time the sine or cosine does a zero-crossing. It also clocks the flip-flops, so that signals switch at the end of a full step. Switch a motor on, count WIN pulses to track the number of steps a motor takes. Polarity
Pol0/Pol1Out These two signals indicate the state of the oscillator, and state of a motor's rotor when it is running. Coordinating the motor's state with these signals will allow for smooth starting and direction changes. -
Completed, work in progress?
02/11/2020 at 22:43 • 0 commentsThe controller is completed, controlling motors from a PC's parallel port. I'm using a text editor to create the control strings that are then printed via CUPS. Yep, <File - Print>.
The work in progress is that I'm cleaning up some aspects of the circuit, creating documentation and incorporating some improvements.
The first improvement is the oscillator, Andrej Levstek] published research on Amplitude Stabilization of Quadrature Oscillators. The output of the current QO is 2.5Vp-p at 15Hz from an LM324 operating from a single 5V supply. Looking at the outputs with the scope's X-Y mode, I see a circle.
I've posted a schematic, adapted for a stand-alone motor driver, in the files section.
-
Eww, distortion
02/11/2020 at 00:04 • 0 commentsI hitched the scope up to the power op-amp version of the circuit, and found clipping! That had to end. Soon I built the diode regulated version found in a TI datasheet and added a power output stage to it. A schematic is in the project files area.
-
Turn, turn, turn
02/10/2020 at 00:59 • 0 commentsOne day, I just wanted to make a stepper motor rotate. A few TTL chips and a bunch of transistors later, it did.
A few days later, Hack-A-Day published an article about sine-cosine drivers. I had to try it.
What's the shortest path to sine-cosine? A quadrature oscillator made from a high-power dual op-amp. One chip, three resistors and three capacitors. No code, no drivers, no mail-order parts. Best of all, the chip was scavenged from a junked VCR.
I was stunned at how smoothly the motor turned. This project begins...