Hi Xiaohong,
When you connect a Stateflow 'default transition' to a flow chart, it is designed to execute only upon entry into the state.
Please refer to the ‘Workflow for Stateflow Chart Execution’ section of the following documentation.
Below is a model similar to the model provide by you, where we can observe that the variable ‘cnt’ is updated only once.
To update the variable ‘cnt’ with each iteration, connect the junction to the Stateflow state ‘State1’ as illustrated in the following figure.
Hope this helps.