Tags: button, idesign, interrupt, matlab, process, programming, push, recording, sound, stopping, thestop, user

how to stop a process (interrupt)

On Programmer » Matlab

1,593 words with 2 Comments; publish: Wed, 07 May 2008 13:42:00 GMT; (20046.88, « »)

hello...i am recording a sound...i have problem..stopping it..i

design a push button to stop the recording so..when user push the

stop button...the recording will stop...but i cant find anyway to

stop the rcording process...helpp please..

All Comments

Leave a comment...

  • 2 Comments
    • aisar wrote:

      >

      > hello...i am recording a sound...i have problem..stopping it..i

      > design a push button to stop the recording so..when user push the

      > stop button...the recording will stop...but i cant find anyway to

      > stop the rcording process...helpp please..

      im still figuring the problem...if anyone can help me..it will be

      very good...

      i have an idea of putting 'if' so it can check for the button

      condition..but i really dont know how to apply it...thanks in

      advance...

      #1; Wed, 07 May 2008 13:43:00 GMT
    • %-- Executes on button press in record.

      function record_Callback(hObject, eventdata, handles)

      k=handles.stop;

      if get(k,'value')~=1

      fs=11025;

      y=wavrecord(5*fs,fs,'int16');

      wavplay(y,fs);

      handles.y=y;

      handles.fss=fs;

      guidata(hObject,handles);

      elseif get(k,'value')==1

      pause(y);

      end

      % -- Executes on button press in stop.

      function stop_Callback(hObject, eventdata, handles)

      g=1;

      set(handles.stop,'value',g);

      disp('gadas');

      ---

      above is my coding...its not working..to stop the process..what

      actually happen is...the stop button function only execute when

      record button process is finish...plzzz somebody help me...really

      appreciate it....

      #2; Wed, 07 May 2008 13:44:00 GMT