Older blog entries for svo (starting at number 1)

Assembled Akipaki again last night. The new construction is much sturdier and easier to disassemble/assemble than previous duct-tape-and-wire one. Pics are on the project page.

Decided to think about batteries later and focus on the PID control loop instead, while using external power. The RC servos seem to brilliantly withstand +12V without much trouble. The current was limited during the test though, so I'm still not sure yet. But anyway it's very nice to see that L6204 bridge is not heating, fully lobotomized servos spin and the controller is getting its +5V well refined and without spikes.

I wonder why it's next to impossible to buy raw gearhead motors, at least here? I have to buy a servo and rip it apart. Weird. Don't RC models of some kind need motors too?

Now I can get back to the firmware. That's the part I've been avoiding for quite a while.


The reason is the crippled PIC16 architecture. Strange use of flags coupled with anti-intuitive skip-instead-of-branch conditionals make arithmetics a little complicated. And those banks.. did they really have to spread all registers across all 4 available banks? Could not they just stay in one bank? The code on a multipage PIC (like the 16F873A i'm using) consists mostly of BANKSEL instructions, each of which is translating into 2 bit set instructions.. And since it's barely possible to know which bank was selected beforehand, it makes it 3 cycles per instruction (user register file is banked too), so where's the advantage of RISC??? Microchip, tell me? It's great that I haven't yet crossed the first program page boundary - the day when my code spans across 2 pages is the day of doom - all calls would have to become long-calls. And it's not really surprising that there's not a single decent C compiler for this abomination of computing, let alone freeware one.

The only thing that's great about PIC's is documentation though. I guess that's how they get people hooked. At least that's how it happened to me - first one's free.



Currently my 2-wheeler is a disassembled set of parts and boards (which used to be assembled once but had too much problems that screamed for hardware solution).

Originally I wanted to control RC servos modified for continuous rotation, but this proved to be a very bad idea. Balancing works, but overshooting in control is inevitable and it's nearly impossible to implement fine control. Basically I have "full throttle back" and "full throttle forth", without anything in between. Thus i decided to build another board with H-bridges that would replace RC servo electronics. With it I can implement PID control of the motors.

The real problem #1 now is the power though. The logic board needs good and stable +5V (well, more than +4V anyway, the stability is more important that absolute value). The motors can run at +5, but the H-bridge chip I'm using needs about +7..+8V or more to boot.

It looks like having 2x 4-piece AA battery holders onboard is inevitable. Thus I could get 9.6V when using rechargeables. Any ideas regarding power/batteries are welcome! And just out of couriousity, for how long a typical "standard RC servo" would stand 10V DC? 10V with 50% duty cycle?

Share this page