private synchronized void  checkAndSetSeq() {
         
         // check if a new sequence is ready in controller obj and load it            
         
         if (checkMe ()) {
            
            float oldT;
             // get the "time position" of running current sequence  
            if ( timeline != null ) {
              
              oldT = timeline.getTimeAtStep(index);
                   
           } else {
              
                 oldT = 0;
             
             }
             
             // ? grughf ?
            
            timeline = null;
            timeline =(InternalSequence) o1.getData().clone();
            limit=timeline.getClusterNumber()-1;
            
            
             if (index!=0) {
            
               // if new sequence time length is minor of old time position
               if (oldT > timeline.getTotalTime()) {
                 
                      rewind();
                     
                 
                 } else {
                     
                   for ( int ct = 0; ct < timeline.getClusterNumber(); ct ++ )  {
                        
                        float newTimeAt = timeline.getTimeAtStep(ct);
                        
                        if ( newTimeAt == oldT ) {
                             
                             // define new timeline index
                          
                             index = ct;
                             break;
                          
                          } else if ( newTimeAt > oldT ) {
                            
                             index = ct;
                             
                                   // make a rest to fit to new rythimc pattern
                                     
                                     try{
                                       Float restF  = new Float ( newTimeAt-oldT);
                                       long newRest = (long) restF.longValue();
                                       sleep(newRest);
                                       } catch (InterruptedException e) {
                                         System.out.println("errore");
                                         throw new RuntimeException (e);
               
                                       }
                             
                                 break;
                            
                            
                           }
                          
                     
                     
                     }
                   
                   
                   
                  }
                           
              
              
              }
          
          
          
          }
          
      
      
      
      }