Myo-Kinematic Prosthetic Simulator

MANUAL CONTROL
Calibration & Demo System
Myoelectric EMG Inputs
Q Bicep
Flex Elbow (-)
0.00 mV
W Tricep
Extend Elbow (+)
0.00 mV
E Flexors
Close Gripper
0.00 mV
R Extensors
Open Gripper
0.00 mV

Overview

This application serves as an interactive demonstration of a non-invasive myoelectric control scheme integrated with a forward and inverse kinematics simulation of a prosthetic upper arm. By modeling microvolt signals generated during skeletal muscle contractions (electromyography, or EMG), users can control elbow rotation and mechanical end-effector grasping patterns.

Alternatively, an active Reverse Kinematic Tracking mode allows the user to click and drag across the canvas, overriding the muscle system to force the robotic arm to mathematically calculate multi-joint angles instantly to reach the target coordinate.

How to Use

The simulator supports three modes of interaction: manual operator EMG control, live inverse-kinematic canvas tracking, and automatic calibration demonstration (Demo Mode).

1. Interactive Manual Control (EMG)

To control individual muscle groups, you can interact directly via your mouse/touchscreen or use keyboard binds:

Muscle Group Keyboard Key On-screen Interface Action Prosthetic Response
Bicep Contraction Q Click & hold "Hold Contract" on Ch. 1 Decreases Elbow Joint Angle (Flexion)
Tricep Contraction W Click & hold "Hold Contract" on Ch. 2 Increases Elbow Joint Angle (Extension)
Forearm Flexors E Click & hold "Hold Contract" on Ch. 3 Closes the Terminal Gripper (Grip)
Forearm Extensors R Click & hold "Hold Contract" on Ch. 4 Opens the Terminal Gripper (Release)

2. Inverse Kinematics Mode (Canvas Drag)

Click and drag directly on the dark canvas area to engage the Inverse Kinematics (IK) override. The primary shoulder base and elbow angle will override the standard biological simulation to dynamically calculate and reach toward your cursor or finger location. Releasing the canvas returns control to the EMG system.

3. Preset Demo Mode

Demo mode can be triggered immediately by clicking the "Start Demo Mode" button or will automatically trigger after 10.0 consecutive seconds of inactivity.

Select from several dedicated kinematics focus exercises inside the dropdown:

Technical Details

Forward Kinematics System

The standard resting configuration is modeled as a 2D open chain with two rigid segments (upper arm link $L_1$ and forearm link $L_2$) connected to a fixed shoulder origin joint $P_0 = (x_0, y_0)$.

Given a base shoulder rotation angle $\theta_1$, the position of the rotational elbow joint $P_1 = (x_1, y_1)$ is computed as: $$x_1 = x_0 + L_1 \cos(\theta_1)$$ $$y_1 = y_0 + L_1 \sin(\theta_1)$$

Inverse Kinematics (IK) Engine

When active cursor tracking is engaged, the system dynamically solves for $\theta_1$ and $\theta_2$ to reach target $P_t = (X, Y)$. Using the Law of Cosines against the bounded distance constraint $D = \min(L_1+L_2, \sqrt{(X-x_0)^2 + (Y-y_0)^2})$, the interior triangle angles calculate the necessary positional rotations.

Biological Signal Interpolation & Noise

To simulate human physical motor constraints, the activation levels do not update instantaneously. The internal raw target $T_i \in \{0, 1\}$ updates instantly on user input, while the visual muscle signal $V_i$ utilizes exponential smoothing to replicate motor unit recruitment latency. High-frequency noise is mathematically introduced into active signals to mirror real myoelectric artifacts using the Box-Muller transform for Gaussian distribution.