So here's that update I promised...
Its been a while and the robot has been somewhat dormant. Mainly because I just couldn't figure out a way to know where the lifter arm was so I could then control it without jamming it up or down. I had thought about using shaft encoders but they're a relative measurement and need an indexing signal so the ESC wouldn't know where the arm was if had just been turned on, say as a result of a momentary power loss.
However an off-hand comment from a friend at Cambridge Makespace got me thinking, could I attach a linkage which would then turn a variable resistor. After a bit of maths, a bit of head scratching at SketchUp and a laser cut tester I found a set up that would work!
After some careful machining and some painful filing (D shafts are really cool but an arse to make) I'd got my linkage attached and now had a variable resistance based on the position of the arm. YES!
The next big step is to get the Tz-85A working. Looking at the modified Tz-85A code here. It seemed really messy and completely ignored the 16bit timer1 in favour of an 8bit timer0 with an 8bit variable to extend it. So I rewrote it. This was a painful choice but I got it working pretty well last night. I just have to sort out the servo code to process the variable resistance and run a very basic control loop. Oh and write the calibration procedure.
This is my current set up:
Once I've got the calibration code somewhat sorted I'll post the GitHub repository. Unless you guys want to trial the current firmware?
Oh and I've entered it into the Burgess Hill competition in April, eep!
Bookmarks