ความคิดเห็น •

  • @raygilbers8274
    @raygilbers8274 8 ปีที่แล้ว +8

    This is a nice tutorial thanks a lot Dejan. But one important comment for people who have ther MAtlab 2016 version please be aware that function codes like set a digital pin or write a digitial pin has been changed:
    digitalWrite will be writeDigitalPin(a, 'D13',1)
    Like this there are more difference check the help funciton in Matlab and the examples to find out!

  • @melissulan5724
    @melissulan5724 4 ปีที่แล้ว +1

    You have used basic languages and basit expression so ı am thankful to you

  • @notaplant2132
    @notaplant2132 4 หลายเดือนก่อน

    Did you use the Arduino support package from Matlab for the example in the video ?

  • @elliegrace9939
    @elliegrace9939 2 ปีที่แล้ว +1

    Do you know how to do a waveform for speech recognition? Like I have an app and it is connected to arduino to control leds. Then, I need to show a waveform.

  • @ppbb7777777pb
    @ppbb7777777pb 8 ปีที่แล้ว +1

    Nice one Dejan! I just have a question!! Would you please tell me what is this value that you were entering in the read box like 500 or 1000!???? And what are the quantities that you are plotting like what is along the Y-axis and what is along X-axis????
    Please answer me.

  • @JavierM6085
    @JavierM6085 7 ปีที่แล้ว

    Awesome explanation! Thanks to you i finished my job of signals and systems and implementation.

  • @syalihin
    @syalihin 7 ปีที่แล้ว +1

    matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)sample1('turn_on_button_Callback',hObject,eventdata,guidata(hObject))
    Error while evaluating UIControl Callback
    i got these error. can you tell me what is the problem?

  • @fernandoluis53
    @fernandoluis53 8 ปีที่แล้ว

    what language are you using? i know its matlab but the for loop function seems differenct from C, C++ and i know matlab doesnt have for loops, right?

  • @patrucaracaleanu3189
    @patrucaracaleanu3189 8 ปีที่แล้ว +1

    I have the same error like #Abdou Abdou, can you help me?
    "Struct contents reference from a non-struct array object.
    Error in example1>example1_OpeningFcn (line 66)
    a.pinMode(13,'output');
    Error in gui_mainfcn (line 220)
    feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
    Error in example1 (line 42)
    gui_mainfcn(gui_State, varargin{:}); "

  • @alvinguevara7872
    @alvinguevara7872 9 ปีที่แล้ว +1

    Good day sir.
    What would be the Arduino code for this? Maybe your code might help me doing my project. I used MATLAB GUI for my microcontroller I always encounter error.
    I have an Arduino program for sensors, servo motor and LED uploaded to my microcontroller and they work well. I see values and status with the Arduino software's serial monitor.
    MATLAB's GUI is what I need to make it user friendly, so that anyone can easily monitor and control the devices to my project. Can you help me with this?
    Or can you make a video where you can see the values printed with Arduino's serial monitor with MATLAB?
    Thanks.

  • @KAFA2020
    @KAFA2020 7 ปีที่แล้ว

    Oh, great work.
    May you live a long life Full of gladness and health . May all God's blessings descend upon you. May peace be within you. May your heart be strong. May you find what you're seeking wherever you roam.

    • @KAFA2020
      @KAFA2020 7 ปีที่แล้ว

      I know know how to make a apps by matlab apps designer which is much better than matlab gui by GUIDE. but I don't know how to add it with hardware. Please could you help me?

  • @bercoviciadrian5981
    @bercoviciadrian5981 8 ปีที่แล้ว +1

    Hello ,firstly thanks alot for the video it really helped me.
    Secondly could you tell me how can i update the plot continously?
    I mean when you press READ and as long as you dont close the port i want the data to refresh itself in time.
    Thanks anticipated.

    • @dattatarayachavan25
      @dattatarayachavan25 7 ปีที่แล้ว

      %%try this
      global a k;
      while(1)
      X=0;
      for k=1:1:handles.xSamples
      b=a.analogRead(0);
      X=[X,b];
      plot(X,'LineWidth',2); grid on;
      axis([0 handles.xSamples 0 1024]);
      pause(0.01);
      end
      end

  • @Ayo04Soul
    @Ayo04Soul 8 ปีที่แล้ว

    As usual another clear and useful tutorial. I'm learning a lot from your videos.

  • @kmmaran
    @kmmaran 8 ปีที่แล้ว

    Thank you Dejan, very useful and helpful. Like to ask and a bit confused. Did you run arduino sketch first and then communicate with matlab for this particular project?, If my understanding correct after seeing you Tutorial 7, you need to run arduino sketch first and the use Matlab to communicate via serial port. Meaning that you control you arduino using arduino IDE and matlab for getting the data out. Please correct me if I am wrong.

  • @RMW_83
    @RMW_83 6 ปีที่แล้ว

    Hello. Greetings from Brazil. Great video, but due to not understanding much English, I was left with a doubt. I can use all libraries available for Arduino. Thank you

  • @jawherferid1604
    @jawherferid1604 6 ปีที่แล้ว

    is it with arduino undo or mega 2560 ? and what should i write in arduino ide code ??

  • @Atazkeitor
    @Atazkeitor 8 ปีที่แล้ว +3

    It's a great lesson, but I'm having a problem with an error in gui_mainfcn (line 220) and
    Error in Example1 (line 42), do you know something about it?
    I would realy apreciate the help, thanks.

    • @jiwenguan4604
      @jiwenguan4604 5 ปีที่แล้ว

      i got same problems. Have you solved it?

  • @niyampatel7451
    @niyampatel7451 8 ปีที่แล้ว

    Thanks sir , great job !
    I faced some difficulties but after all , I executed it with my Ardiono uno board.
    Share some more videos like serial communication of Arduino data to matlab (Bi-directional) using fopen and fclose.
    Thanks a lot.

  • @minhly650
    @minhly650 9 ปีที่แล้ว

    Hi buddy.I didn't get it.Why were there "data1" and "xSamples" at 10:32 ? What do they mean ? Can I use "data" or "data2" or something like those instead ?
    And I have a small question that is not much relevent to your video.Do I have to programme all over again in Matlab environment instead of just uploading my code into Arduino via Arduino IDE (in case I have a new code) and then all I have to do is just the GUI to make it work ? Is there any way to do it ?
    By the way,I did exactly what you did,but only buttons for LED worked,button "READ" and text didn't.When I tried to run button "READ",he command window showed me this stuff:
    "??? Undefined function or method 'grip' for input arguments of type 'char'.
    Error in ==> AandM_GUI>read_button_Callback at 111
    grip on;
    Error in ==> gui_mainfcn at 96
    feval(varargin{:});
    Error in ==> AandM_GUI at 42
    gui_mainfcn(gui_State, varargin{:});
    Error in ==>
    @(hObject,eventdata)AandM_GUI('read_button_Callback',hObject,eventdata,guidata(hObject))
    "
    I am using MATLAB R2010b.Please reply to my question as soon as you can.I really appreciate that.Thanks a lot.

    • @minhly650
      @minhly650 9 ปีที่แล้ว

      ***** Thanks again.Apparently,I didn't notice that you attached the balloon that denotes your typo.After I've rewritten my code,it works now.Oh I think I can answer myself for the second question that whenever we want to run Arduino with Matlab,all we have to do first is upload one of the sketches supported by Matwork for Arduino into Arduino.Of course,the sketch chosen must be appropriate to our project.Do I explain correctly ? Amd counld you make a video about how to use Arduino libraries in Matlab or guide me about this one?.For instance,I want to plot results that I get from a ultrasonic sensor using Newping library.But I didn't know what to do at first.Thanks you very much.

  • @richardbalboa7161
    @richardbalboa7161 7 ปีที่แล้ว +1

    It seems that version of the Matlab and the arduino's new plugins could be the problem.
    I got this 2 errors in my MATLAB 2016:
    Error in gui_mainfcn (line 220)
    feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
    Error in guitest_pr2 (line 42)
    gui_mainfcn(gui_State, varargin{:});
    So this video needs at least an actualization.

  • @MsAlsada90
    @MsAlsada90 8 ปีที่แล้ว

    This is awesome my God reware you, I just have one request and I hope you don't mind to help me ,actually I am going to use four ultrasonic sensors whith arduino by using Matalab GUI so I need your advice please.

  • @nixonsava7052
    @nixonsava7052 8 ปีที่แล้ว

    why guidata(hObject,handles)... i dont know why. does it suposes to be a global variables o something like that?

  • @mimonitoazul
    @mimonitoazul 9 ปีที่แล้ว

    Great video Dejan, but I found some errors in the code you show on the video, I have fixed some of them on mine, but there are some I can not do it, for example I can't show the plot in real time. If you have the fixed code you use in the test, could you upload it?. Thank you, you are doing a great job!

  • @huyhoangnguyen5541
    @huyhoangnguyen5541 4 ปีที่แล้ว

    At the Read button I typed the code like you but when I ran and clicked the read button, it showed the error.

  • @austindowney7473
    @austindowney7473 9 ปีที่แล้ว

    Dejan, Great video.
    I hate to say this but but just so you know the .IDE files dont really work with the newer versions of MATLAB, i.e. 2014a and on.
    Again, thanks for the very clear videos.

  • @tahanprahara
    @tahanprahara 7 ปีที่แล้ว

    Dear Sir,
    how to Pot 2 channel ADC on Axis Plot? Need help please sir

  • @TheMohsell
    @TheMohsell 8 ปีที่แล้ว

    why turn on/off buttons work in the same time as the plot function is executing . I mean the callback functions in gui cannot execute simultaneously. it is the pause command which is doing some magic ?

    • @YIIEdChamboIIY
      @YIIEdChamboIIY 8 ปีที่แล้ว

      +mohamed sellahi The callback functions can actually execute simultaneously however I'm not sure if this is just a time slicing approach.

  • @mohamednabil1709
    @mohamednabil1709 8 ปีที่แล้ว

    dude arduino commands is different in matlab how did u manage to use them , for example the pinMode , or Digital Write or analog write

    • @IAmAmperes
      @IAmAmperes 8 ปีที่แล้ว

      he uses the arduino IO support package for MatLab. Requires License to use it and original arduino boards.

  • @abdobou1589
    @abdobou1589 9 ปีที่แล้ว

    so if I used ""ECG/EKG Arduino shield "" instead a photocell with the some code , can I get the signal perfectly ? ,if no how can I do it ?
    thank's a lot

    • @abdobou1589
      @abdobou1589 9 ปีที่แล้ว

      +Dejan Nedelkovski
      thank's for the reply .and I 'm waiting your project in wireless

    • @shimoammar8657
      @shimoammar8657 9 ปีที่แล้ว

      hi,i use the same ""ECG/EKG Arduino shield "" i cannot have an accurate graph with real time plotting could you help me ?

    • @abdobou1589
      @abdobou1589 9 ปีที่แล้ว

      +Shimo Ammar
      I think the problem is in frequency try this code :
      delete(instrfind({'Port'},{'COM12'}))
      clear a;
      clear n x
      a=arduino('COM12');
      tic
      n=0;
      time=0;
      while 1
      x=readVoltage(a,'A0');
      x=[x,n];
      n=x;
      t=toc
      time=[t,time];

      plot(time,x)
      axis([0 50 0 5])
      drawnow
      screen=[x',time']
      end
      reply me if he works

    • @shimoammar8657
      @shimoammar8657 9 ปีที่แล้ว

      No it does not work successfully
      thank you.

  • @armandocarrion479
    @armandocarrion479 7 ปีที่แล้ว

    Does this work just with Arduino MEGA?

  • @fatih1922
    @fatih1922 6 ปีที่แล้ว

    I love your tutorials. I would like you to ask if you can make a simple desktop application to control a device.

  • @lmbt456
    @lmbt456 9 ปีที่แล้ว

    how can one connect BCILAB ouTput from MATLAB.TO CONTROL SERVOMOTOR from arduino?
    how can we interface bcilab and arduino,plz suggest ?

  • @abdouabdou6516
    @abdouabdou6516 8 ปีที่แล้ว

    Thank you for the video, Is it work with Arduino Uno ?

    • @abdouabdou6516
      @abdouabdou6516 8 ปีที่แล้ว

      +Dejan Nedelkovski OK, I try to use it with Arduino Mega like you but I see this errors (I change the pin 8 by 13):
      No appropriate method, property, or field pinMode for class arduino.
      Error in Example1>Example1_OpeningFcn (line 67)
      a.pinMode(13, 'output');
      Error in gui_mainfcn (line 220)
      feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
      Error in Example1 (line 42)
      gui_mainfcn(gui_State, varargin{:});

    • @rozinurhuda7348
      @rozinurhuda7348 8 ปีที่แล้ว

      +Abdou Abdou perhaps you have to see another video Arduino Tutorial #07

  • @satishkumar-qv1dc
    @satishkumar-qv1dc 7 ปีที่แล้ว

    will it work for ardunio uno...

  • @landaguillermo53
    @landaguillermo53 9 ปีที่แล้ว +1

    Thanks so much!, Its very usefull your information

  • @fadhilmuhammad5379
    @fadhilmuhammad5379 2 ปีที่แล้ว

    Dear sir,
    Can i get the code (coding)?

  • @feli___b
    @feli___b 7 ปีที่แล้ว +1

    It didn't work:
    No appropriate method, property, or field 'pinMode' for class 'arduino'.
    Error in Example1_Example1_OpeningFcn (line 67)
    a.pinMode(8, 'output');

    • @humamramadan1328
      @humamramadan1328 7 ปีที่แล้ว

      i have the same problem i think they have updated the package

    • @manupatel1063
      @manupatel1063 6 ปีที่แล้ว

      @Felipe Boscardin
      'pinMode' replace with 'configurePin'

  • @penguin0123
    @penguin0123 6 ปีที่แล้ว

    Hi. Can I do the same with an Arduino Uno? TY

  • @agatajaworska9036
    @agatajaworska9036 7 ปีที่แล้ว

    Doesnt work on 2015a.
    starting from error :
    Error in Example1 (line 40)
    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
    to error
    Error in gui_mainfcn (line 220)
    feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
    damn it

  • @ramziltt
    @ramziltt 9 ปีที่แล้ว

    i have a problem
    Attempt to reference field of non-structure array.
    Error in bpm2>Signal_Callback (line 91)
    b = a.analogRead(0);
    Error in gui_mainfcn (line 96)
    feval(varargin{:});
    Error in bpm2 (line 42)
    gui_mainfcn(gui_State, varargin{:});
    Error in @(hObject,eventdata)bpm2('Signal_Callback',hObject,eventdata,guidata(hObject))
    Error while evaluating uicontrol Callback

    • @ramziltt
      @ramziltt 9 ปีที่แล้ว

      ***** I only need the graph I have no LED

  • @abdobou1589
    @abdobou1589 9 ปีที่แล้ว

    ( Hi Dejan ,thank you for the TUTORIAL it works perfectly but I need to receive 1000 point per second(frequency
    so please if you know the matlab's code tell me
    Thanks again

  • @fahmialkatiri449
    @fahmialkatiri449 2 ปีที่แล้ว

    how if with using 2 sensor PIR?

  • @blinkfaraway2721
    @blinkfaraway2721 4 ปีที่แล้ว

    how to call data from simulink to Gui ?

  • @babubassi878
    @babubassi878 8 ปีที่แล้ว

    can I apply ac to arduino if not than why

  • @hoangan_tran2992
    @hoangan_tran2992 8 ปีที่แล้ว +6

    My Program name is : untitled1
    Why when i put the "run" button, this lines appear :
    " Error in untitled1 (line 42)
    gui_mainfcn(gui_State, varargin{:}); "
    Anyone can show me the way to fix this error

    • @hoangan_tran2992
      @hoangan_tran2992 8 ปีที่แล้ว +1

      And this :
      Error using untitled1_untitled1_OpeningFcn (line 65)
      Failed to open serial port COM3 to communicate with board Uno. Make sure
      there is no other MATLAB arduino object for this board. For troubleshooting,
      see Arduino Hardware Troubleshooting.

    • @lagankapoor007
      @lagankapoor007 6 ปีที่แล้ว

      Mr Kitter are you solved this problem ?

  • @sanjayakumar8219
    @sanjayakumar8219 3 ปีที่แล้ว

    Good job sir..💛💛

  • @vanfly
    @vanfly 8 ปีที่แล้ว

    Excellent. Maybe, could you help me with a track for a project.
    I need to do a controller for a helicopter and I do not know how to do a virtual simulation with the transfer function of system and the function of controller.
    Thank you for your time.

  • @rafifwirareswara7770
    @rafifwirareswara7770 3 ปีที่แล้ว +1

    Reference to non-existent field 'output'.
    Error in LIGHT_SENSOR_GUI_MATLAB>LIGHT_SENSOR_GUI_MATLAB_OutputFcn (line 77)
    varargout{1} = handles.output;
    Error in gui_mainfcn (line 264)
    feval(gui_State.gui_OutputFcn, gui_hFigure, [], gui_Handles);
    Error in LIGHT_SENSOR_GUI_MATLAB (line 42)
    gui_mainfcn(gui_State, varargin{:});

  • @nabilkarame6999
    @nabilkarame6999 9 ปีที่แล้ว

    thanks you ,
    you are doing a great job

  • @feli___b
    @feli___b 7 ปีที่แล้ว +12

    Do not make people lose their time... You should update it or take off the video. It doesn't work anymore.

    • @manupatel1063
      @manupatel1063 6 ปีที่แล้ว

      hii @Felipe Boscardin use this code
      function varargout = analogReadWithDigitalWrite(varargin)
      % ANALOGREADWITHDIGITALWRITE MATLAB code for analogReadWithDigitalWrite.fig
      % ANALOGREADWITHDIGITALWRITE, by itself, creates a new ANALOGREADWITHDIGITALWRITE or raises the existing
      % singleton*.
      %
      % H = ANALOGREADWITHDIGITALWRITE returns the handle to a new ANALOGREADWITHDIGITALWRITE or the handle to
      % the existing singleton*.
      %
      % ANALOGREADWITHDIGITALWRITE('CALLBACK',hObject,eventData,handles,...) calls the local
      % function named CALLBACK in ANALOGREADWITHDIGITALWRITE.M with the given input arguments.
      %
      % ANALOGREADWITHDIGITALWRITE('Property','Value',...) creates a new ANALOGREADWITHDIGITALWRITE or raises the
      % existing singleton*. Starting from the left, property value pairs are
      % applied to the GUI before analogReadWithDigitalWrite_OpeningFcn gets called. An
      % unrecognized property name or invalid value makes property application
      % stop. All inputs are passed to analogReadWithDigitalWrite_OpeningFcn via varargin.
      %
      % *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
      % instance to run (singleton)".
      %
      % See also: GUIDE, GUIDATA, GUIHANDLES
      % Edit the above text to modify the response to help analogReadWithDigitalWrite
      % Last Modified by GUIDE v2.5 19-Oct-2018 07:40:12
      % Begin initialization code - DO NOT EDIT
      gui_Singleton = 1;
      gui_State = struct('gui_Name', mfilename, ...
      'gui_Singleton', gui_Singleton, ...
      'gui_OpeningFcn', @analogReadWithDigitalWrite_OpeningFcn, ...
      'gui_OutputFcn', @analogReadWithDigitalWrite_OutputFcn, ...
      'gui_LayoutFcn', [] , ...
      'gui_Callback', []);
      if nargin && ischar(varargin{1})
      gui_State.gui_Callback = str2func(varargin{1});
      end
      if nargout
      [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
      else
      gui_mainfcn(gui_State, varargin{:});
      end
      % End initialization code - DO NOT EDIT
      % --- Executes just before analogReadWithDigitalWrite is made visible.
      function analogReadWithDigitalWrite_OpeningFcn(hObject, eventdata, handles, varargin)
      % This function has no output args, see OutputFcn.
      % hObject handle to figure
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      % varargin command line arguments to analogReadWithDigitalWrite (see VARARGIN)
      % Choose default command line output for analogReadWithDigitalWrite
      handles.output = hObject;
      % Update handles structure
      guidata(hObject, handles);
      % UIWAIT makes analogReadWithDigitalWrite wait for user response (see UIRESUME)
      % uiwait(handles.figure1);
      % --- Outputs from this function are returned to the command line.
      function varargout = analogReadWithDigitalWrite_OutputFcn(hObject, eventdata, handles)
      % varargout cell array for returning output args (see VARARGOUT);
      % hObject handle to figure
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      % Get default command line output from handles structure
      varargout{1} = handles.output;
      clear ab;
      delete(instrfind('port','COM6'))
      global ab;
      ab = arduino('COM6','uno');
      %pinMode = configurePin(ab,'D12');
      %pinMode = configurePin(ab,'A5');
      configurePin(ab,'D12','DigitalOutput');
      configurePin(ab,'A5','Unset');
      % --- Executes on button press in turn_on_button.
      function turn_on_button_Callback(hObject, eventdata, handles)
      % hObject handle to turn_on_button (see GCBO)
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      global ab;
      writeDigitalPin(ab,'D12',1);
      % --- Executes on button press in turn_off_button.
      function turn_off_button_Callback(hObject, eventdata, handles)
      % hObject handle to turn_off_button (see GCBO)
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      global ab;
      writeDigitalPin(ab,'D12',0);
      % --- Executes on button press in temp_reading_button.
      function temp_reading_button_Callback(hObject, eventdata, handles)
      % hObject handle to temp_reading_button (see GCBO)
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      global ab k;
      x=0;
      for k=1:1:handles.data2
      v1 = readVoltage(ab,'A5');
      analog = (v1/0.0048875);
      temp1 = analog*0.48828125;
      disp(temp1);
      x=[x,temp1];
      plot(handles.axes1,x);grid on;
      set(handles.temp_ddisplay);
      % axis([0 handles.data2 0 500]);
      pause(1);
      end
      function temp_ddisplay_Callback(hObject, eventdata, handles)
      % hObject handle to temp_ddisplay (see GCBO)
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles structure with handles and user data (see GUIDATA)
      % Hints: get(hObject,'String') returns contents of temp_ddisplay as text
      % str2double(get(hObject,'String')) returns contents of temp_ddisplay as a double
      handles.data1=get(hObject, 'String');
      handles.data2=str2double(handles.data1);
      guidata(hObject,handles);
      % --- Executes during object creation, after setting all properties.
      function temp_ddisplay_CreateFcn(hObject, eventdata, handles)
      % hObject handle to temp_ddisplay (see GCBO)
      % eventdata reserved - to be defined in a future version of MATLAB
      % handles empty - handles not created until after all CreateFcns called
      % Hint: edit controls usually have a white background on Windows.
      % See ISPC and COMPUTER.
      if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
      set(hObject,'BackgroundColor','white');
      end

    • @nicolasroseroeraso6099
      @nicolasroseroeraso6099 4 ปีที่แล้ว

      @@manupatel1063 Hello, a have the same problem when I use the "analogRead(0)" command from the guide, I don't know how to use the code that you shared, can you explain me? please

  • @HimanshuSharma-kr3qv
    @HimanshuSharma-kr3qv 9 ปีที่แล้ว +1

    Hi Dejan!
    Really cool video was that. But i have an enquiry to make.
    I did exactly the same as you did in this video, but whenever i successfully upload the code, it shows the following errors. The graph kills it always. Although the LED is still in work. Please help me! Here are the following errors shown to me-
    >> gui_no_1
    Attempting connection .............
    Analog & Digital I/O + Encoders + Servos (adioes.pde) sketch detected !
    Arduino successfully connected !
    Undefined function 'grip' for input arguments of type 'char'.
    Error in gui_no_1>read_the_input_Callback (line 110)
    plot(x,'LineWidth', 1 ); grip on;
    Error in gui_mainfcn (line 95)
    feval(varargin{:});
    Error in gui_no_1 (line 42)
    gui_mainfcn(gui_State, varargin{:});
    Error in @(hObject,eventdata)gui_no_1('read_the_input_Callback',hObject,eventdata,guidata(hObject))
    Error while evaluating uicontrol Callback
    "I have done EXACTLY thee same like you."

    • @maartenwijnants1947
      @maartenwijnants1947 9 ปีที่แล้ว +2

      Himanshu Sharma You should change 'grip on' into 'grid on'. Than your code should run fine

    • @HimanshuSharma-kr3qv
      @HimanshuSharma-kr3qv 9 ปีที่แล้ว

      Let me give it a try !

    • @HimanshuSharma-kr3qv
      @HimanshuSharma-kr3qv 9 ปีที่แล้ว

      It shows the grid lines (dotted lines) and the graph is changing values as per my read samples box too but no values plotting still!

    • @HimanshuSharma-kr3qv
      @HimanshuSharma-kr3qv 9 ปีที่แล้ว

      Maarten Wijnants Great!
      I finally had the code working.
      But if you could please tell me what is the diference between GRIP ON and GRID ON!!!
      Thanks a lot again

    • @maartenwijnants1947
      @maartenwijnants1947 9 ปีที่แล้ว

      The difference is more simple than it sounds. 'grip' is not a matlab function, and 'grid' is. this was a typo in the script. That's why Matlab gives you the error that it doesn't recognize the function grip.
      Enjoy your GUI!

  • @rafifwirareswara7770
    @rafifwirareswara7770 3 ปีที่แล้ว +1

    Reference to non-existent field 'output'.
    Error in LIGHT_SENSOR_GUI_MATLAB>LIGHT_SENSOR_GUI_MATLAB_OutputFcn (line 77)
    varargout{1} = handles.output;
    Error in gui_mainfcn (line 264)
    feval(gui_State.gui_OutputFcn, gui_hFigure, [], gui_Handles);
    Error in LIGHT_SENSOR_GUI_MATLAB (line 42)
    gui_mainfcn(gui_State, varargin{:});

  • @ehsanerashed
    @ehsanerashed 8 ปีที่แล้ว

    Thank you for the helpful Video you have put on the TH-cam ,
    I have a question about, how can I Connect my Heartbeat sensors (( which is On the Olimex ECG/EMG shield and arduino Uno)) TO the MATLAB software and see the sinusoidal signal Online ?

    • @amyfalyn
      @amyfalyn 8 ปีที่แล้ว

      +Ehsan Rashed Have you figured out how to read in a heart rate signal?

  • @manupatel1063
    @manupatel1063 6 ปีที่แล้ว

    grate effort

  • @sahadevaneganahallinageshg98
    @sahadevaneganahallinageshg98 7 ปีที่แล้ว

    Thank you bro

  • @dr.kirbimkistreu5531
    @dr.kirbimkistreu5531 9 ปีที่แล้ว

    yo se por qué no funciona, si usan matlab ver. 2014 y el arduino support package actualizado, deben declarar las entradas analogicas y salidas digitales con la nueva sintaxis

  • @mehmetselcukaltnok1718
    @mehmetselcukaltnok1718 9 ปีที่แล้ว +1

    function varargout = example1(varargin)
    % EXAMPLE1 MATLAB code for example1.fig
    % EXAMPLE1, by itself, creates a new EXAMPLE1 or raises the existing
    % singleton*.
    %
    % H = EXAMPLE1 returns the handle to a new EXAMPLE1 or the handle to
    % the existing singleton*.
    %
    % EXAMPLE1('CALLBACK',hObject,eventData,handles,...) calls the local
    % function named CALLBACK in EXAMPLE1.M with the given input arguments.
    %
    % EXAMPLE1('Property','Value',...) creates a new EXAMPLE1 or raises the
    % existing singleton*. Starting from the left, property value pairs are
    % applied to the GUI before example1_OpeningFcn gets called. An
    % unrecognized property name or invalid value makes property application
    % stop. All inputs are passed to example1_OpeningFcn via varargin.
    %
    % *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
    % instance to run (singleton)".
    %
    % See also: GUIDE, GUIDATA, GUIHANDLES
    % Edit the above text to modify the response to help example1
    % Last Modified by GUIDE v2.5 15-Oct-2015 21:36:44
    % Begin initialization code - DO NOT EDIT
    gui_Singleton = 1;
    gui_State = struct('gui_Name', mfilename, ...
    'gui_Singleton', gui_Singleton, ...
    'gui_OpeningFcn', @example1_OpeningFcn, ...
    'gui_OutputFcn', @example1_OutputFcn, ...
    'gui_LayoutFcn', [] , ...
    'gui_Callback', []);
    if nargin && ischar(varargin{1})
    gui_State.gui_Callback = str2func(varargin{1});
    end
    if nargout
    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
    else
    gui_mainfcn(gui_State, varargin{:});
    end
    % End initialization code - DO NOT EDIT
    % --- Executes just before example1 is made visible.
    function example1_OpeningFcn(hObject, eventdata, handles, varargin)
    % This function has no output args, see OutputFcn.
    % hObject handle to figure
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    % varargin command line arguments to example1 (see VARARGIN)
    % Choose default command line output for example1
    handles.output = hObject;
    % Update handles structure
    guidata(hObject, handles);
    % UIWAIT makes example1 wait for user response (see UIRESUME)
    % uiwait(handles.figure1);
    delete(instrfind({'port'} , {'COM7'} ) )
    clear a;
    global a;
    a=arduino('COM7');
    a.pinMode(8, 'output');
    % --- Outputs from this function are returned to the command line.
    function varargout = example1_OutputFcn(hObject, eventdata, handles)
    % varargout cell array for returning output args (see VARARGOUT);
    % hObject handle to figure
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    % Get default command line output from handles structure
    varargout{1} = handles.output;
    % --- Executes on button press in turn_on_button.
    function turn_on_button_Callback(hObject, eventdata, handles)
    % hObject handle to turn_on_button (see GCBO)
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    global a;
    a.digitalWrite(8,1);
    % --- Executes on button press in turn_off_button.
    function turn_off_button_Callback(hObject, eventdata, handles)
    % hObject handle to turn_off_button (see GCBO)
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    global a;
    a.digitalWrite(8,0);
    % --- Executes on button press in read_button.
    function read_button_Callback(hObject, eventdata, handles)
    % hObject handle to read_button (see GCBO)
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    lobal a k;
    x=0;
    for k=1:1:handles.xSamples
    b= a.analogRead(0);
    x=[x,b];
    plot(x,'LineWidLH'2); grip on;
    axis([0 handles.xSamples 0 500 ]);
    pause(0.01);
    end
    function edit_text_samples_Callback(hObject, eventdata, handles)
    % hObject handle to edit_text_samples (see GCBO)
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles structure with handles and user data (see GUIDATA)
    % Hints: get(hObject,'String') returns contents of edit_text_samples as text
    % str2double(get(hObject,'String')) returns contents of edit_text_samples as a double
    handles.data1=get(hObject, 'String');
    handles.xSamples=str2double(handles.data1);
    guidata(hObject , handles );
    % --- Executes during object creation, after setting all properties.
    function edit_text_samples_CreateFcn(hObject, eventdata, handles)
    % hObject handle to edit_text_samples (see GCBO)
    % eventdata reserved - to be defined in a future version of MATLAB
    % handles empty - handles not created until after all CreateFcns called
    % Hint: edit controls usually have a white background on Windows.
    % See ISPC and COMPUTER.
    if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
    end

  • @miguelmorales3194
    @miguelmorales3194 7 ปีที่แล้ว

    mexican english

  • @harfogolo
    @harfogolo 8 ปีที่แล้ว

    The adds u cant quit with about 2 minutes are horrible! Dislike