Hi Seb, 2009/10/11 Sebastien Lelong [email protected]
> > I was thinking to use a PIC as controller of the whole board: commands would be sent to it, then it > > would throw them to dedicated PWM chip. It could add i2c interface, could store parameters for each > > servos, store sequence of commands, maybe with an extra EEPROM. > > adding hardware feels like a surrender ;) > But sometime the right tool can save you lots of headache... Great specs! And maybe 'surrrender' is a too big word and definitely not intended personally, but adding hardware for things that could be handled in software is not the best way to go for non-prototypes. But you are right: it saves headache (fun, challenges, time).. This product http://www.robotshop.us/pob-technology-pob-servo.html seems to be discontinued, but has an 16f877a that runs 20 servos. So it can be done... For interrupts at regular intervals, I normally use timer1 and reload it in the isr. But experiments with fast interrupts learned me that it is better to use timer2, since a delay in handling the isr does not influence the time the next interrupt occurs. And running a small interrupt routine (checking some counters, setting some io pins) at 80 kHz takes about 50% of the pic processing power, leaving 50% for housekeeping and comms. So maybe a 'base architecture' of 100 kHz to actually create the pulse (from 0 tot 255 * 10us = 2,55 ms) and all other code without interrupt could do the job. But having said this... I thought the single pin display interface would be a usefull project too and afaik, it is not used by anyone else (and I could not use it in my latest project due to a 'name space conflict' for serial_software). Joep 2009/10/11 Sebastien Lelong <[email protected]> > Hi again, > > >> adding hardware feels like a surrender ;) >> > > But sometime the right tool can save you lots of headache... > > >> >> I think it should be feasable to create accurate timing with an isr by >> reprogramming the timer for each servo if there are no other interrupts. >> And since i2c slave is the most usefull interface, we should adapt the i2c >> slave lib to work without interrupts. >> >> > > TLC5940 can also be chained, we could provide a "simple" 16 PWM controller, > and a "fat" 32 PWM controller, etc... It requires minimal external part (1 > resistor if I'm reading ok). And as I said, i2c + programmable sequence + > per-servo configuration doesn't look like a surrender :) > > There are also things using 74HC595 shift register. One hardware PWM > channel could sequentially drive 8 PWM output from this chip. > > > Cheers, > Seb > > http://www.instructables.com/id/The_Dawm/ > > >> Joep >> >> >> >> 2009/10/10 Sebastien Lelong <[email protected]> >> >> Hi guys, >>> >>> I'm still thinking about a nice servo controller made in jallib (at least >>> 8 channels I'd say). Goal would be to provide a Jaluino shield too. While we >>> already discussed about implementing PWM in software, this can give problems >>> of accuracy. What about using a dedicated chip, like TLC5940 ? >>> >>> http://focus.ti.com/docs/prod/folders/print/tlc5940.html >>> >>> It's used to control LEDs, but it seems it can be used to control servos >>> too (in some arduino references). >>> >>> Don't you think it would speed up development of such controller ? >>> >>> >>> Cheers, >>> Seb >>> -- >>> Sébastien Lelong >>> http://www.sirloon.net >>> http://sirbot.org >>> >> >> >> >> > > > -- > Sébastien Lelong > http://www.sirloon.net > http://sirbot.org > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "jallib" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/jallib?hl=en -~----------~----~----~----~------~----~------~--~---
