Work continues

No pictures, just code, code, code.

Lat weekend, I put in about 48 hours of C coding in for work, and found some lucidity. Continuing on this tradition, I pushed forward on Wheatley.

1) I reconfigured my notions of how to do some of the tasks.

2) I found a library called easy transfer that makes things a little easier. Though I am using it inefficiently, I still have enough resource to get the job done.

3) implemented an exponential rolling average on the A/D converters.

So presently, I am grabbing 4 channels of A/D conversion, smoothing it, pumping it into a bunch of INTs and Easy Transfer sends them across with a checksum.  I transfer across on a timer interrupt, and run the receiver as fast as it will go. I then I take the values and jam them into servo settings.

The inefficiency is in the fact that I have a heartbeat which is 4 bytes, 9 servo values which only need 10 bits, but use 16 each. This is a waste of  6-3/4 bytes, but I can afford the bandwidth.

I am also relying on floats for my rolling average, and will continue to do so for my inverse trig functions.

I also have an Arduino Nano, and a small 5V 3.A amp switcher I plan to use for the power for the servos. I will be building a small power distribution board, and should have servos running soon in a system that more directly resembles the final form.
woot

UGH ^ UGH

Well,

Time to step back.
Errors were made.
I “pinned” the axis in a place that caused no hindrance and designed a few parts. Today I started in on a new assembly, one to verify motion, and found a lot of interference.

To move the interferences, I need to move hardware.
To move the hardware, I may have to remove the raspberry pi.
If I move the raspberry pi, I likely have to remove it.
If I remove it, I will have to change the software…

As I said, UGH.

Update:
Moving serovs around, being more diligent. May work out ok.

Update 8/1/2012
Being more diligent, things looking better, things still awkward. Moving towards shared axis. I.E. I am looking at having two servos push and pull on opposite sides of a gimbal. If they push and pull in equal but opposite directions, one axis stays stable while the other remains stable. add an equal and identical offset to both, and the second axis moves.

Primarily, I am thinking of doing this for the face’s tilt and rotate. If I were to support the face from the back, and not the bottom of the sphere, I would lose a lot of contigulus space, but the axis with then be a little simpler.