ISR priority levels can be set. If ISR priority is given to I2C, the servo may jitter. I will try to make the servo lib have many less interupts, therefore less to disturb. If the servo (timer0 ISR) is given priority, I am guessing that you may loose I2C data??
The user could choose. In seb's case with jaluino, he could give priority to the servo's, and less priority to I2c. Then maybe he can send the same I2C data 5 times, hoping that he gets one. So, no matter what, it seems there is a comprimise when using 2 ISR's. The only way around this that I can think of is if servo lib ISR has some I2C code in it, or if I2C ISR has servo code in it. I have not tested this, but this how I think it works. Matt. On Feb 3, 3:10 pm, Joep Suijs <[email protected]> wrote: > yes. *if* other ISR sources occure, there will be. The chance of > jitter (how often a pulse is lengthed by an other isr) depends on the > rate and processing time of each isr. > > If you use serial comms without isr (or adapt i2c slave to work > without interrupts) the signal can be perfect. > I have a pob-servo, which has a parallel comms bus and supports 20 > servos perfectly stable with one pic. So it can be done... > > IMHO the design of the library should minimise the jitter on it's own > (preferable none if there are no other interrupts) and impose as > little as possible restrictions on your application to maintain tlis > minimal level in more complex configurations. > As said before, it can be done. But if this was easy, I'd made such a > library years ago ;) > > Joep > > 2010/2/3 vasile surducan <[email protected]>: > > > > > > > On 1/31/10, Joep Suijs <[email protected]> wrote: > > >> 2010/1/31 Joep Suijs <[email protected]>: > > >> > IMO it would be better to reporgram a (16 bit) timer and only generate > >> > an interrupt when there is an action, > > >> Or maybe use timer2 (8 bit), so timer1 remains available for ccp. > > > One question: if other random events will be treated in the ISR (asuming > > the microcontroler is not only a servo driver connected as an I2C slave) > > will not allways occure a variable jitter, no mater of timer resolution? > > > Vasile > > > -- > > 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.- Hide quoted text - > > - Show quoted text - -- 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.
