📄 ieee80211a_sfun_c1.c
字号:
sf_debug_transition_conflict_check_end();
if(numTransitions>1) {
_SFD_TRANSITION_CONFLICT(&(transitionList[0]),numTransitions);
}
}
_SFD_CT_CALL(TRANSITION_ACTIVE_TAG,2);
_SFD_CT_CALL(TRANSITION_WHEN_VALID_TAG,2);
_SFD_CT_CALL(TRANSITION_INACTIVE_TAG,2);
exit_atomic_m0_c1_s7_Mod_QPSK2_18Mbps();
enter_atomic_m0_c1_s1_Mod_16QAM_24Mbps();
} else {
_SFD_CT_CALL(TRANSITION_BEFORE_PROCESSING_TAG,9);
if(CV_TRANSITION_EVAL(9, _SFD_CCP_CALL(9,0,(InputData_m0_c1_d3_snrEst <=
chartInstance.LocalData.m0_c1_d2_thres[
_SFD_ARRAY_BOUNDS_CHECK(0, 2, 1, 7, 0)] -
chartInstance.LocalData.m0_c1_d1_hyst)))) {
_SFD_CT_CALL(TRANSITION_ACTIVE_TAG,9);
_SFD_CT_CALL(TRANSITION_WHEN_VALID_TAG,9);
_SFD_CT_CALL(TRANSITION_INACTIVE_TAG,9);
exit_atomic_m0_c1_s7_Mod_QPSK2_18Mbps();
enter_atomic_m0_c1_s8_Mod_QPSK_12Mbps();
}
}
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,3);
break;
case IN_m0_c1_s8_Mod_QPSK_12Mbps:
CV_CHART_EVAL(0,0,8);
_SFD_CS_CALL(STATE_ENTER_DURING_FUNCTION_TAG,5);
_SFD_CCS_CALL(STATE_DURING_COVERAGE_TAG,5,0);
_SFD_CT_CALL(TRANSITION_BEFORE_PROCESSING_TAG,12);
if(CV_TRANSITION_EVAL(12, _SFD_CCP_CALL(12,0,(InputData_m0_c1_d3_snrEst >
chartInstance.LocalData.m0_c1_d2_thres[
_SFD_ARRAY_BOUNDS_CHECK(0, 2, 1, 7, 0)] +
chartInstance.LocalData.m0_c1_d1_hyst)))) {
if(sf_debug_transition_conflict_check_enabled()) {
unsigned int transitionList[2];
unsigned int numTransitions=1;
transitionList[0] = 12;
sf_debug_transition_conflict_check_begin();
if(InputData_m0_c1_d3_snrEst <=
chartInstance.LocalData.m0_c1_d2_thres[1] -
chartInstance.LocalData.m0_c1_d1_hyst) {
transitionList[numTransitions] = 10;
numTransitions++;
}
sf_debug_transition_conflict_check_end();
if(numTransitions>1) {
_SFD_TRANSITION_CONFLICT(&(transitionList[0]),numTransitions);
}
}
_SFD_CT_CALL(TRANSITION_ACTIVE_TAG,12);
_SFD_CT_CALL(TRANSITION_WHEN_VALID_TAG,12);
_SFD_CT_CALL(TRANSITION_INACTIVE_TAG,12);
exit_atomic_m0_c1_s8_Mod_QPSK_12Mbps();
enter_atomic_m0_c1_s7_Mod_QPSK2_18Mbps();
} else {
_SFD_CT_CALL(TRANSITION_BEFORE_PROCESSING_TAG,10);
if(CV_TRANSITION_EVAL(10, _SFD_CCP_CALL(10,0,(InputData_m0_c1_d3_snrEst
<= chartInstance.LocalData.m0_c1_d2_thres[
_SFD_ARRAY_BOUNDS_CHECK(0, 1, 1, 7, 0)] -
chartInstance.LocalData.m0_c1_d1_hyst)))) {
_SFD_CT_CALL(TRANSITION_ACTIVE_TAG,10);
_SFD_CT_CALL(TRANSITION_WHEN_VALID_TAG,10);
_SFD_CT_CALL(TRANSITION_INACTIVE_TAG,10);
exit_atomic_m0_c1_s8_Mod_QPSK_12Mbps();
enter_atomic_m0_c1_s5_Mod_BPSK2_9Mbps();
}
}
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,5);
break;
default:
CV_CHART_EVAL(0,0,0);
break;
}
}
_SFD_CC_CALL(EXIT_OUT_OF_FUNCTION_TAG,0);
}
static void enter_atomic_m0_c1_s1_Mod_16QAM_24Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,1);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,1,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s1_Mod_16QAM_24Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,1);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,1);
OutputData_m0_c1_d4_modIdx = 5.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,1,1);
OutputData_m0_c1_d5_bitRate = 24.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,1,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,1);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,1);
}
static void exit_atomic_m0_c1_s1_Mod_16QAM_24Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,1);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,1,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,1);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,1);
}
static void enter_atomic_m0_c1_s2_Mod_16QAM_36Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,7);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,7,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s2_Mod_16QAM_36Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,7);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,7);
OutputData_m0_c1_d4_modIdx = 6.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,7,1);
OutputData_m0_c1_d5_bitRate = 36.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,7,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,7);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,7);
}
static void exit_atomic_m0_c1_s2_Mod_16QAM_36Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,7);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,7,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,7);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,7);
}
static void exit_atomic_m0_c1_s3_Mod_64QAM2_54Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,6);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,6,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,6);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,6);
}
static void enter_atomic_m0_c1_s4_Mod_64QAM_48Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,4);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,4,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s4_Mod_64QAM_48Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,4);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,4);
OutputData_m0_c1_d4_modIdx = 7.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,4,1);
OutputData_m0_c1_d5_bitRate = 48.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,4,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,4);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,4);
}
static void exit_atomic_m0_c1_s4_Mod_64QAM_48Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,4);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,4,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,4);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,4);
}
static void enter_atomic_m0_c1_s5_Mod_BPSK2_9Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,0);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,0,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s5_Mod_BPSK2_9Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,0);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,0);
OutputData_m0_c1_d4_modIdx = 2.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,0,1);
OutputData_m0_c1_d5_bitRate = 9.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,0,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,0);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,0);
}
static void exit_atomic_m0_c1_s5_Mod_BPSK2_9Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,0);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,0,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,0);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,0);
}
static void exit_atomic_m0_c1_s6_Mod_BPSK_6Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,2);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,2,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,2);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,2);
}
static void enter_atomic_m0_c1_s7_Mod_QPSK2_18Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,3);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,3,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s7_Mod_QPSK2_18Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,3);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,3);
OutputData_m0_c1_d4_modIdx = 4.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,3,1);
OutputData_m0_c1_d5_bitRate = 18.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,3,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,3);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,3);
}
static void exit_atomic_m0_c1_s7_Mod_QPSK2_18Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,3);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,3,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,3);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,3);
}
static void enter_atomic_m0_c1_s8_Mod_QPSK_12Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_ENTRY_FUNCTION_TAG,5);
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,5,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_m0_c1_s8_Mod_QPSK_12Mbps;
_SFD_CS_CALL(STATE_ACTIVE_TAG,5);
_SFD_CS_CALL(STATE_BEFORE_ENTRY_ACTION_TAG,5);
OutputData_m0_c1_d4_modIdx = 3.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,5,1);
OutputData_m0_c1_d5_bitRate = 12.0;
_SFD_CCS_CALL(STATE_ENTRY_COVERAGE_TAG,5,2);
_SFD_CS_CALL(STATE_AFTER_ENTRY_ACTION_TAG,5);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,5);
}
static void exit_atomic_m0_c1_s8_Mod_QPSK_12Mbps(void)
{
_SFD_CS_CALL(STATE_ENTER_EXIT_FUNCTION_TAG,5);
_SFD_CCS_CALL(STATE_EXIT_COVERAGE_TAG,5,0);
chartInstance.State.is_ieee80211a_sfun_c1 = IN_NO_ACTIVE_CHILD;
_SFD_CS_CALL(STATE_INACTIVE_TAG,5);
_SFD_CS_CALL(EXIT_OUT_OF_FUNCTION_TAG,5);
}
void sf_ieee80211a_sfun_c1_get_check_sum(mxArray *plhs[])
{
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(4203786583U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(1847780713U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(2494745738U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(4043134534U);
}
/*
* Chart initialization function
*/
/* work around the buggy macro in simstruc.h until it is fixed */
#define cdrGetOutputPortReusable(S,port) \
( (S)->portInfo.outputs[(port)].attributes.optimOpts != \
SS_NOT_REUSABLE_AND_GLOBAL )
static void initialize_ieee80211a_sfun_c1( SimStruct *S)
{
{
real_T __sfTemp1[7];
real_T __sfTemp2;
sf_set_error_prefix_string("Stateflow Runtime Error (chart): Error evaluating chart workspace data 'thres' in the chart's parent workspace.\n");
sf_mex_assign_from_mx_array(ml_get_named_mx_array("thres", 1), __sfTemp1, 0,
0, 1, 7);
{
uint8_T __sfTemp_i0;
for(__sfTemp_i0=0;__sfTemp_i0<7;__sfTemp_i0++){
chartInstance.LocalData.m0_c1_d2_thres[__sfTemp_i0] =
__sfTemp1[__sfTemp_i0];
}
}
sf_set_error_prefix_string("Stateflow Runtime Error (chart): ");
sf_set_error_prefix_string("Stateflow Runtime Error (chart): Error evaluating chart workspace data 'hyst' in the chart's parent workspace.\n");
sf_mex_assign_from_mx_array(ml_get_named_mx_array("hyst", 1), &__sfTemp2, 0,
0, 0);
chartInstance.LocalData.m0_c1_d1_hyst = __sfTemp2;
sf_set_error_prefix_string("Stateflow Runtime Error (chart): ");
if(!cdrGetOutputPortReusable(S,1)) {
OutputData_m0_c1_d4_modIdx = 0.0;
}
if(!cdrGetOutputPortReusable(S,2)) {
OutputData_m0_c1_d5_bitRate = 0.0;
}
}
/* Initialize chart's state configuration */
memset((void*)&(chartInstance.State),0,sizeof(chartInstance.State));
{
if(ssIsFirstInitCond(S)) {
/* do this only if simulation is starting */
if(!sim_mode_is_rtw_gen(S)) {
{
unsigned int chartAlreadyPresent;
chartAlreadyPresent =
sf_debug_initialize_chart(_ieee80211aMachineNumber_,
1,
8,
15,
5,
0,
0,
0,
0,
&(chartInstance.chartNumber),
&(chartInstance.instanceNumber),
ssGetPath((SimStruct *)S),
(void *)S);
if(chartAlreadyPresent==0) {
/* this is the first instance */
sf_debug_set_chart_disable_implicit_casting(_ieee80211aMachineNumber_,chartInstance.chartNumber,0);
sf_debug_set_chart_event_thresholds(_ieee80211aMachineNumber_,
chartInstance.chartNumber,
0,
0,
0);
_SFD_SET_DATA_PROPS(2,
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -