Suggestion: RedState SCT should support multiple SM

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Suggestion: RedState SCT should support multiple SM

169 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by larsen on Sat Sep 05 00:59:36 MST 2015
They cannot be operated simultaneously but it is never the less relevant when your target has multiple functional modes between which you want to select during runtime.

As of now, when I create a statemachine for SCT in RedState I _can_ define multiple statemachines (SM) in one project, but the code generated allways get into the same file and effectively overwrites previous code. Ok maybe it is possible to avoid this by having each statemachine in its own directory, but you will still be faced with muliple SM's having the same init function name: sct_fsm_init();

Why not give the generated files and functions names which reflect the statemachine they are defining - using name decoration? So in stead of always call the file sct_fsm.c call it SM1_sct_fsm.c and not sct_fsm_init(); but SM1_init(); or something like that. In fact it appears that the software SM has this feature of multiple SM's- obviously I may say.
Does'nt this make sense?

What is the best workaround for the present 7.9.0 version to have mutiple SCT SM's?
0 Kudos
2 Replies

149 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by larsen on Sat Sep 05 13:00:35 MST 2015
Perfect, just what I needed but didn't see.
Thanks for your help.
0 Kudos

149 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by DF9DQ on Sat Sep 05 11:55:37 MST 2015
When you are in the RedState editor, you will see a "State Machine Settings" tab next to the "State Table" tab. There you can change the file names for the current state machine, and also change the prefix of the created init function.
0 Kudos