Project Updates for 9/9/2010
I got my timer code working nicely. I originally kept losing the the high byte of the timer because even though I bitshifted, my timer variable was only 8 bits, so when I shifted the bits over, they would just fall off the undersized variable. As soon as I started reading into 16-bit variables, the problem went away. When I generated my algorithm, I had assumed that the signals for all 6 channels occurred simultaneously. However, upon hooking up 2 channels of my oscilloscope together I discovered they actually occur sequentially, so as soon as one channel ends, the next one starts. An easy way to fix this is to use one channel's end time as the next one's start time. Now, if I have all 6 channels connected at once, this isn't a problem, but I want to be able to have channels missing and still have this work correctly. One way around it might be to have it detect active channels and check only those. It just gets a bit tough when dealing with microseconds and efficient code is extremely important. So the goal for today is to figure out an algorithm that addresses the new information and possibly to code it in.
I reattached the strut I had repaired yesterday and it seems to be holding up nicely. If it bends enough to need another repair, my next step will be to temper the pin so that it's much less bendable (more like a drillbit).
As far as figuring out the other boards and MMC, I've decided to put that on hold until after I get the timer code working. Also, since I've decided to store the values as 16-bit numbers, I will need to figure out a way to transfer that via SPI, since I've only tried sending 8-bit numbers. In the worst cast I could always send it as a high byte and low byte, but I'm pretty sure that's unnecessary.