It seems you want to program the arduino itself to be able to interprete some incoming serial messages and then take action - For that type of algorithm design and implementation I would recommend the following support: http://www.mathworks.com/hardware-support/arduino-simulink.html It has serial receive blocks, and other output blocks (like Digital output for your LED blink). you will be able to create arbitrary algorithms to implement on the board... and the serial commands that come to it can be from arbitrary sources... you would be able to not have MATLAB/Simulink plugged into the board once it is programmed with the algorithm you want.
But one option may be to simply process all this in MATLAB - note this is not what you asked, but want to clarify... Given a serial command in MATLAB (that maybe even MATLAB recieves from elsewhere), you can create the algorithm there that maps to blink an LED, and that is the command you send to the arduino at that point from MATLAB. I would suggest this support in that case: http://www.mathworks.com/hardware-support/arduino-matlab.html Note that this also has Simulink blocks, but you are doing all the algorithm execution in MATLAB and Simulink on the host machine - and just sending commands to the arduino (vs programming it as with the first option).
"Srey" wrote in message <email@example.com>... > Interfacing matlab to arduino. > let my output in matlab :say some 'text'. i want to pass that text to arduino through some serial communication. Corresponding to that text, the arduino should give some output ..say..blinking an led. Any one please help me with a code .Please provide me a solution. Any packages available to inteface arduino and matlab.