Skip to content

set bpm from encoder via ws - #216

Open
jpremill wants to merge 4 commits into
TreeFallSound:feat/transport-bindingsfrom
jpremill:feat/set-bpm-from-encoder-via-ws
Open

set bpm from encoder via ws#216
jpremill wants to merge 4 commits into
TreeFallSound:feat/transport-bindingsfrom
jpremill:feat/set-bpm-from-encoder-via-ws

Conversation

@jpremill

Copy link
Copy Markdown

based on feedback to address #215 based on #213 conversation. I tried to keep it more atomic than I am used to;
I have only verified via the the tests on these and have not tested on. physical the device yet.

…pass MIDI CC emission for bound transport parameters
@jpremill
jpremill marked this pull request as draft July 22, 2026 03:09
@jpremill
jpremill marked this pull request as ready for review July 22, 2026 03:11
Comment thread modalapi/modhandler.py Outdated
Comment thread modalapi/modhandler.py Outdated
Comment thread modalapi/pedalboard.py Outdated

@rreichenbach rreichenbach left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is more his domain, I'll defer to Cam on the code, but I did test this on hardware and it works just as I would expect. The control maps fine, and changing the setting tracks whether from Encoder, Footswitch or MOD-UI.

@sastraxi
sastraxi changed the base branch from prerelease to feat/transport-bindings July 24, 2026 03:36
Comment thread modalapi/modhandler.py Outdated
Comment thread modalapi/modhandler.py Outdated
Comment thread modalapi/modhandler.py
# Audio parameter (volume, EQ, etc.) - handled locally, no remote update needed
if param.instance_id is None:
self.audio_parameter_commit(param.symbol, value)
return

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need this early return otherwise the audio parameters will emit CCs below.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jpremill thoughts?

Comment thread modalapi/modhandler.py Outdated
Comment thread modalapi/modhandler.py Outdated
Comment on lines +477 to +479
def test_encoder_bpm_turn_without_websocket_bridge_falls_back_to_rest_post(
v3_system: SystemFixture, make_plugin
):

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test could be deleted once we decide REST vs WS

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jpremill would still suggest removing this. The service is no longer considered to be healthy if the WS bridge is not up.

@sastraxi sastraxi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is close! A couple real bugs here worth taking a look at.

It would be helpful if you could test on device. Personally, I like to use ./deploy.sh to just copy local files over to test, but you might prefer @rreichenbach 's approach which is to edit files directly on the device. There's a helper you can use to turn the deployed source code back into a git repository if it helps:

https://sastraxi.github.io/pistomp-manual/developers/getting-started/#dev-mode-git-managed-source-on-the-device

…MIDI CC bypass, audio param early return, and test enhancements)

@sastraxi sastraxi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good to merge after the final comments are addressed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants