Keyestudio 4DOF Manual page 155

Robot arm kit
Hide thumbs Also See for 4DOF:
Table of Contents

Advertisement

www.keyestudio.com
}
//************************************************************
// for exiting the loop
z1 = digitalRead(right_key); // read the right Z value
if(z1==1) // if the right key is pressed
{
delay(10); //eliminate the shake
if(z1==1) // if the key z1 is pressed
{
pos1=jiyi1[( j-1)]; // assign the last angle value saved in array to pos
pos2=jiyi2[( j-1)]; // for exiting the loop, still access to joystick control.
pos3=jiyi3[( j-1)];
pos4=jiyi4[( j-1)];
i=0; // assign i as 0,prepare for saving the angle value using array
z2=0; // assign z2 as 0,for exiting the while loop
break; //exit the current loop
}
}
//********************************************************
}
}
}
//claw
zhuazi();
//turn
zhuandong();
//upper arm
xiaobi();
152

Advertisement

Table of Contents
loading

Table of Contents