mirror of
https://github.com/interactive-matter/TMC26XStepper.git
synced 2026-03-13 09:01:30 +08:00
making it look a bit more like trinamic (color wise)
This commit is contained in:
@@ -48,7 +48,7 @@ void setupData() {
|
||||
void drawData() {
|
||||
|
||||
if (motor_connected && activeTab!=null && runTab.equals(activeTab)) {
|
||||
fill(graphBackgroundColor);
|
||||
fill(backgroundColor);
|
||||
rectMode(CORNERS);
|
||||
noStroke();
|
||||
//rect(plotLeft, plotBottom, plotRight, plotTop);
|
||||
|
||||
@@ -43,15 +43,15 @@ void setupRunConfig() {
|
||||
//ad a multilist for the microstepping setting
|
||||
microsteppingButtons = controlP5.addRadioButton("microstepping", 150, 40);
|
||||
controlElements.add(microsteppingButtons);
|
||||
microsteppingButtons.addItem("1", 1);
|
||||
microsteppingButtons.addItem("2", 2);
|
||||
microsteppingButtons.addItem("4", 4);
|
||||
microsteppingButtons.addItem("8", 8);
|
||||
microsteppingButtons.addItem("16", 16);
|
||||
microsteppingButtons.addItem("32", 32);
|
||||
microsteppingButtons.addItem("64", 64);
|
||||
microsteppingButtons.addItem("128", 128);
|
||||
microsteppingButtons.addItem("256", 256);
|
||||
microsteppingButtons.addItem("1/1", 1);
|
||||
microsteppingButtons.addItem("1/2", 2);
|
||||
microsteppingButtons.addItem("1/4", 4);
|
||||
microsteppingButtons.addItem("1/8", 8);
|
||||
microsteppingButtons.addItem("1/16", 16);
|
||||
microsteppingButtons.addItem("1/32", 32);
|
||||
microsteppingButtons.addItem("1/64", 64);
|
||||
microsteppingButtons.addItem("1/128", 128);
|
||||
microsteppingButtons.addItem("1/256", 256);
|
||||
microsteppingButtons.showBar();
|
||||
microsteppingButtons.moveTo(runTab);
|
||||
|
||||
|
||||
@@ -12,16 +12,19 @@ ControlP5 controlP5;
|
||||
Serial arduinoPort;
|
||||
|
||||
//TODO comde up with a nice color scheme
|
||||
color activeColor = #22aaee;
|
||||
color foreGroundColor = #1a6699; //Stil to use 1a334c
|
||||
color activeColor = #01ADF1;
|
||||
color foreGroundColor = #01ADF1;
|
||||
color uiTextColor = #4D4D4F;
|
||||
color uiElementColor = #ffffff;
|
||||
color labelColor = #f0f0f0;
|
||||
color valueColor = #f0f0f0;
|
||||
color graphBackgroundColor = #131313;
|
||||
color stallGuardColor = #991a1a;
|
||||
color positionColor = #1a6699; //still to use #8c7f26
|
||||
color backgroundColor = #EDEEEF;
|
||||
color stallGuardColor = #4D4D4F;
|
||||
color positionColor = #01ADF1;
|
||||
color goodStatusColor = labelColor;
|
||||
color badStatusColor = stallGuardColor;
|
||||
color coolStepColor = #8c7f26;
|
||||
color coolStepColor = #969696;
|
||||
CColor uiColor = new CColor( foreGroundColor, uiElementColor, activeColor, uiTextColor, uiTextColor);
|
||||
|
||||
Tab configureTab;
|
||||
Tab runTab;
|
||||
@@ -43,6 +46,7 @@ void setup() {
|
||||
size(1000, 800);
|
||||
//load the font
|
||||
controlP5 = new ControlP5(this);
|
||||
controlP5.setColor(uiColor);
|
||||
runTab = controlP5.getTab("default");
|
||||
configureTab =controlP5.addTab("configure");
|
||||
//customize the tabs a bit
|
||||
@@ -87,7 +91,7 @@ void toggleUi(boolean show_controls) {
|
||||
}
|
||||
|
||||
void draw() {
|
||||
background(graphBackgroundColor);
|
||||
background(backgroundColor);
|
||||
drawChopper();
|
||||
drawData();
|
||||
decodeSerial();
|
||||
|
||||
Reference in New Issue
Block a user