Be the first to rate this file! 102 downloads (last 30 days) File Size: 11.67 KB File ID: #15972

Modeling Mode Logic in Embedded MATLAB

by Kiran Kintali

 

17 Aug 2007 (Updated 14 Aug 2008)

Code covered by BSD License  

Implementing Mealy and Moore FSMS in an Embedded MATLAB block

Download Now | Watch this File

File Information
Description

A finite state machine is a representation of a reactive system. In an event-driven system, the system makes a transition from one state (mode) to another prescribed state, provided that the condition defining the change is true.

Stateflow is the best tool for modeling finite state machines. It provides very sophisticated capabilities to build hierarchical and parallel state machines, temporal logic and state entry/during/exit actions etc.,

However there are many Signal Processing and Communications applications where in when writing a very data flow centric algorithms, there comes a need to write a simple controller embedded in the algorithm.This example shows how to implement such a simple mealy or more state machine in Embedded MATLAB control using control flow constructs.

Mealy: y = f(x,u)
 all actions are condition actions and outputs are function of state and input

Moore: y = f(x)
 all actions are state actions and outputs are pure functions of state only

Required Products Simulink
MATLAB release MATLAB 7.4 (R2007a)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Updates
14 Aug 2008

add to eML category

Tag Activity for this File
Tag Applied By Date/Time
embedded matlab Kiran Kintali 22 Oct 2008 09:23:19
fsm Kiran Kintali 22 Oct 2008 09:23:19
hdl Kiran Kintali 22 Oct 2008 09:23:19
mealy Kiran Kintali 22 Oct 2008 09:23:19
embedded matlab Kiran Kintali 22 Oct 2008 09:23:19
moore Kiran Kintali 22 Oct 2008 09:23:21
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com