Skip to content

Conversation

nitin710
Copy link
Collaborator

@nitin710 nitin710 commented Sep 4, 2024

Description

  • Adds a feature where some Oscilloscope functions can be controlled by sending UDP messages to the Oscilloscope at a per-defined port.
  • Currently the following functions are supported:
    • EMOTIBIT_CONNECT
    • EMOTIBIT_DISCONNECT
    • RECORD_BEGIN
    • RECORD_END

Requirements

Issues Referenced

Requested from reviewer

  • Check out the "using this feature" heading to figure out how to use this new feature.
  • Run the tests listed in the "Testing" section
  • A general code review
  • Comments on the high-level block diagram
  • Comments on the messaging API

Documentation update

  • ToDo: Update docs on docs.emotibit.com
  • For now, refer to the Documentation feat-OscilloscopeControlAutomation in internal notes

Notes for Reviewer

  • High-level diagram
    • image

Additional Documents

  • EmotiBit Oscilloscope aux automated control API documentation (search in our internal documents)
  • EmotiBit Oscilloscope automated control (search in our internal documents)
  • Documentation feat-OscilloscopeControlAutomation (search in our internal documents)

Using this feature

  • Get the additional tools listed in the Requirements section
  • pull and checkout feat-OscilloscopeControlAutomation.
  • Build and run the EmotiBitOscilloscope application.
  • Have an EmotiBit running and connected to the same network.
  • Disconnect from the EmotiBit if it is already connected on the Oscilloscope
  • open git-bash in ofxEmotiBit/tests/EmotiBitOscilloscopeAutomation.
    • run the command ./testing_seq.sh --emotibit-id <YOUR_EMOTIBIT_ID>
    • Example: ./testing_seq.sh --emotibit-id MD-V5-0000005
  • Observe
    • The Oscilloscope will connect, disconnect, connect, record, and end recording with the specified emotibit id.
  • You can also run individual commands by the following bash commands
    • ./EC.sh --emotibit-id <YOUR_EMOTIBIT_ID>
    • ./ED.sh
    • ./RB.sh (Oscilloscope needs to be connected to an emotibit)
    • ./RE.sh (Oscilloscope needs to be connected to an emotibit)

Testing

  • run the script testing_sq.sh
    • Observe: Oscilloscope connect, disconnect, start and stop recording on an EmotiBit
  • run the script EC.sh
  • run the script ED.sh
  • run the script RB.sh
  • run the script RE.sh

Results

  • ✔️ run script testing_sq.sh
  • ✔️ [Connect to emotibit] - run EC.sh
  • ✔️ [Disconnect from emotibit] - run ED.sh
  • ✔️ [Begin a recording] - run RB.sh
  • ✔️ [end a recording] - run RE.sh
  • ✔️ Send a user note - run UN.sh

Feature Tests

  • Connect to EmotiBit using EmotiBit Oscilloscope auxiliary port
  • Disconnect from EmotiBit using EmotiBit Oscilloscope auxiliary port
  • Begin recording using EmotiBit Oscilloscope auxiliary port
  • Stop recording using EmotiBit Oscilloscope auxiliary port
  • Send user note using EmotiBit Oscilloscope auxiliary port

Known issues

  • Currently the function clearOscilloscope() is not called when connecting/disconnecting from EmotiBit(s). In my testing this does not cause any issues if all EmotiBits are MDs. But might cause GUI errors if switching between EMO and MD. We need more testing. Additionally, clearOscilloscope() is an ofApp function, that should be called using ofEvent or other mechanism when a WiFi_host command is being executed.

Checklist to allow merge

  • All dependent repositories used were on branch master
  • Software
    • Get approval from the reviewer
    • Passed testing on Windows
    • Passed testing on macOS (for major changes/GUI changes/ PRs adding files distributed with the EmotiBit software)
    • Passed testing on linux (ubuntu) (for major changes/GUI changes/ PRs adding files distributed with the EmotiBit software)
    • Update software bundle version in ofxEmotiBitVersion.h

@Joseph-Jacobson
Copy link
Contributor

Joseph-Jacobson commented Jul 29, 2025

All tests worked! I think you need to update this documentation here. As the naming is different for the file path/tests command.

So instead of:
ofxEmotiBit/tests/EmotiBitOscilloscopeAutomation.
./testing_seq.sh --emotibit-id <YOUR_EMOTIBIT_ID>

it should be
ofxEmotiBit/tests/EmotiBitOscilloscope/control-automation/.
./run_test.sh --emotibit-id <YOUR_EMOTIBIT_ID>

@jaketheduque
Copy link

All tests worked! I think you need to update this documentation here. As the naming is different for the file path/tests command.

So instead of: ofxEmotiBit/tests/EmotiBitOscilloscopeAutomation. ./testing_seq.sh --emotibit-id <YOUR_EMOTIBIT_ID>

it should be ofxEmotiBit/tests/EmotiBitOscilloscope/control-automation/. ./run_test.sh --emotibit-id <YOUR_EMOTIBIT_ID>

Tests worked great for me too. Just have the same documentation changes as Joe.

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.

Ability to control EmotiBit Oscilloscope without GUI interaction

3 participants