First plots! Well, first computer-controlled plots!
Shown here: HP 7045A analogue X-Y recorder with signals generated by an STM32F103. X and Y are generated with PWM and an extremely basic 2nd order low pass filter.
The STM32 acts as an USB-CDC serial interface and runs a very basic HPGL interpreter (barely enough for the HPGL subset Inkscape uses). This means I can just `cat drawing.hpgl > /dev/ttyACMx` to plot. Well, I could, if I’d find out how I can set the write timeout, because at some point the MCU’s HPGL buffer will be full and it will its receive endpoint until it has drawn some stuff, naturally leading to a serial timeout and a half-done plot.
I wanted to add a video, but
- I can’t figure out how to disable the auto focus on my phone (I probably can’t) and it gets extremely confused by the plotter all the time;
- DSLR can do video, but without sound and the pen lift mechanisms punching the pen into paper with a BRRNG is too impressive to not share.
TODOs/musings for now:
- Recorder is seriously filthy, needs quite a clean-up. Probably including the encoders. Basically all pots and range switches have contact issues.
- The big gap at the top, where the gantry comes out is great for dropping tools and parts into and subsequent cursing.
- The electrostatic paper ‘autogrip’ seems to be broken, even though I remembered it as working from the last time I used this recorder.
- This thing can go seriously fast. For now I can only plot as fast as I want, but only when disregarding any corners the image is supposed to have. I’m curious how fast I can get it with a better filter design than slamming random parts into a breadboard or maybe with some signal pre-processing.
- Previously mentioned Z-axis clonking will be a problem for various pens I’ll end up using. Dampening the pen holder will have to be a mechanical solution and I don’t really want to modify this beauty.
By the way, if you’re interested in the HP 7045A itself, here’s a picture with the bottom taken off from when I last had it open 5 years ago. Beautiful old-school HP hand-routed gold-plated PCBs! In my experiments here, I’m attaching to the DC-37 connector at the top, which carries X, Y, pen and time control signals. Not more though, because it’s missing the TTL control board, which would be in the lower left hand side corner, which might be my Option 007 (like Tek’s option 01 = no read-out).
I’m still not too sure how I’ll dampen the Z axis. I don’t want to make any irreversible changes to the plotter but something needs to be done: the plotter slams the pen into the paper so hard that it actually bounces off at first.
The record/lift signal is purely digital, so I can’t feed it a slow ramp to set the pen down slowly. I could check if using PWM helps (rather than just making a bunch of noise).
Added PWM for the pen output. The pen no longer jumps on activation, but there’s still strong positive feedback and a ‘tipping point’, after which it accelerates towards the paper, so the small dot at each line start isn’t avoidable yet.
I used 120 Hz because the behaviour seemed less consistent at higher PWM frequencies. Maybe the lower frequency vibrates the solenoid loose? Also, there’s now a nice honking sound when plotting.