 }
 
 void loop(){
-  char c;
+  char c, buffer[10], pos[] = {0,1,2,3,4,5,6,7,8};
+  int iAmp, iF_offset, iB_offset, iFk_offset, iBk_offset;
+  float fKnee_amp, fAfreq, fPhase, fGait;
+  String readString, amp, knee_amp, afreq, gait, phase, f_offset, b_offset, fk_offset, bk_offset;
+  unsigned long previousMillis = 0;
+  unsigned int sine_time = 0.05, t = 0;
     
   while (Serial.available() && readString.length() < 38){
     //delay to allow buffer to fill

    Serial.print(fk_offset);
    Serial.println(bk_offset);
    */
    //clear strings
    readString="";
    amp="";

    fk_offset="";
    bk_offset="";
  }
  
  //determine joint positions
  pos[0] = iAmp * sin(fAfreq*t) + 1500 + iF_offset;
