Thanks Christof & Scott for the great suggestions, There's definitely quite some overhead in creating/destroying connections.. usually there are dropped audio blocks. For now it would be just a single connection for the lifetime of the plugin, so ownership/management of the connection needs to shift from one UGen instance to the other when the new UGen is instantiated by JITlib. Are you saying that I would be better off establishing the I2C connection automatically when the server boots? Is there a special function to put plugin initialization code that runs before any and all UGen Ctor calls? Forgive my ignorance, this is my first time diving into UGen development and I'm still quite fuzzy on many of the intricacies! If it helps in any way,
here's the code thusfar of the UGen. All the lower level I2C
stuff is encapsulated in the Trill class, but the UGen is still
responsible for triggering bus reads via a task running in a
lower priority thread. https://github.com/jreus/banjer/blob/master/Bela_UGens/TrillRaw/TrillRaw.cpp thanks a lot for all
your advice! Jonathan
On 25/11/2019 18:17,
scott@xxxxxxxxxxxxx wrote:
|