Skip to content

Commit 9545d89

Browse files
committed
SensorGraph now show independent MAT for left and right settings.
1 parent 4815b9f commit 9545d89

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

SensorGraph.pde

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,12 +121,20 @@ void lineChart( PApplet graph,
121121
ymax = maxVal;//Collections.max(leftData);
122122
}
123123

124-
// draw minimum activation threshold line (TODO: fixup when independent MAT)
125-
int mat_y = y - round(emgManager.getMinimumActivationThreshold(LEFT_DIRECTION_LABEL)*h);
124+
// draw minimum activation threshold lines
125+
int leftMatY = y - round(emgManager.getMinimumActivationThreshold(LEFT_DIRECTION_LABEL)*h);
126+
int rightMatY = y - round(emgManager.getMinimumActivationThreshold(RIGHT_DIRECTION_LABEL)*h);
127+
128+
graph.strokeWeight(4);
129+
130+
graph.fill(0,0,255,128);
131+
graph.stroke(0,0,255,128);
132+
graph.line(x-3, leftMatY, x+w-10, leftMatY);
133+
126134
graph.fill(255,0,0,128);
127135
graph.stroke(255,0,0,128);
128-
graph.strokeWeight(4);
129-
graph.line(x-3, mat_y, x+w-10, mat_y);
136+
graph.line(x-3, rightMatY, x+w-10, rightMatY);
137+
130138
graph.strokeWeight(1);
131139

132140

0 commit comments

Comments
 (0)