Using the scheduler should be relatively easy, you can simply call sched_gsmtime() and provide it a framenumber and a 'tdma_sched_item'.
the
latter will contain the callback that is to be called once the current framenumber will reach 'fn' as specified.
what if there is already a scheduled item? in this case i must schedule the frequency change item before any other item. also the frame number of frequency change may be more than 255 frames ahead.
my suggestion: because hopping sequence is a function of time, the starting time should also be included in this function (rfch.c).
what if there is already a scheduled item? in this case i must schedule the frequency change item before any other item. also the frame number of frequency change may be more than 255 frames ahead.
Feel free to extend the scheduler to fit your needs.
my suggestion: because hopping sequence is a function of time, the starting time should also be included in this function (rfch.c).
The only function in rfch.c returns the parameter for a given time. It does _NOT_ and should _NOT_ make any change to the parameter itself. That's left up to the caller because we need to call that function several time.
If you want to introduce some call that configure the channel and make changes and stuff, put it into another function and make sure it's called when required.
Sylvain
baseband-devel@lists.osmocom.org