Previously, the playback data stream was created as an observable that could be subscribed to by different parts of the workflow (PhaseProcession, MotorProcession, running threshold calculation etc.). This caused 2 issues:
Potential for different branches subscribing to the playback stream to subscribe to the observable at different times, meaning playback would not be in sync between different branches.
Errors being thrown where parts of the workflow attempted to access the disposed observable on the start of a new block.
This is fixed in this PR by subscribing to the observable and sending the data to a PublishSubject at the start of each block. This means all subscribers to the playback data stream are receiving the same playback values, and fixes the error caused by trying to access a disposed observable.
I've tested this a few times remotely, but would benefit from someone trying this branch out on the rig to ensure the playback is running smoothly.
This PR addresses #54.
Previously, the playback data stream was created as an observable that could be subscribed to by different parts of the workflow (PhaseProcession, MotorProcession, running threshold calculation etc.). This caused 2 issues:
This is fixed in this PR by subscribing to the observable and sending the data to a PublishSubject at the start of each block. This means all subscribers to the playback data stream are receiving the same playback values, and fixes the error caused by trying to access a disposed observable.
I've tested this a few times remotely, but would benefit from someone trying this branch out on the rig to ensure the playback is running smoothly.