In reply to dave_59:
Hi Dave,
Thanks for the response.
Let us consider two difference scenarios
Scenario 1: In a TB say, sequence's S0's sequence item is accessing the drive and we have three sequences S1, S2 and S3 ( none of them are using lock or grab ) and they are in corresponding sequencer waiting ( say some other sequence's S0's sequence item is accessing the drive ) in the order ( S1 ->S2-> S3 ) with arbitration being FIFO
So the order in which the sequences' S* sequence item will access the driver is S1->S2->S3.
Scenario 2: In a TB say, sequence's S0's sequence item is accessing the drive and we have three sequences S1, S2 and S3 ( out of these say S2 uses lock()and unlock() calls ) and they are in corresponding sequencer in the order ( S1 ->S2-> S3 ) with arbitration being FIFO
Based on the statement in the cookbook which says: The sequencer lock method is called from a sequence and its effect is that the calling sequence will be granted
exclusive access to the driver when it gets its next slot via the sequencer arbitration mechanism.
my understanding is that even in the scenario 2, the sequences S* sequence item will access the driver is S1->S2->S3.
So, Can you help me understand the significance of lock() in scenario 2 ? The order of completion seems to be the same in both the cases.
I can see the difference if we had used grab() , ungrab() in scenarion 2 instead of lock and unlock, the order of access to the driver would be S2, S1 and S3.
Or am i missing anything here ?
Thanks,
V