FCCU problems about MPC5744P

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

FCCU problems about MPC5744P

ソリューションへジャンプ
852件の閲覧回数
shaoduoduo
Contributor I

The example is provided by NXP. :fccu_fault_injection_mpc5744p

shaoduoduo_0-1710231064306.png

 

I have change the setting of the FCCU, to test the sequence of the EOUT[0] and EOUT[1].

shaoduoduo_1-1710231149878.png

 

When the fccu1_EoutConfig0.mode  is set to FCCU_FO_BISTABLE. The output is not change when FCCU go to error state. The sequence of the EOUT[0] and EOUT[1] is not right. EOUT[0] is always high, and EOUT[1] is always low.

They do  not change when the FCCU state changes.

But when fccu1_EoutConfig0.mode  is set to FCCU_FO_DUAL_RAIL or FCCU_FO_TIME_SWITCHING. The output sequence of the EOUT[0] and EOUT[1]  is right.

can you tell me the reason.

Below is my setting code .

Best regard.

 

/* ###################################################################
** This component module is generated by Processor Expert. Do not modify it.
** Filename : fccu1.c
** Project : fccu_fault_injection_mpc5744p
** Processor : MPC5744P_144
** Component : fccu
** Version : Component C55_Repository, Driver 01.00, CPU db: 3.00.000
** Repository : SDK_S32_PA_11
** Compiler : GNU C Compiler
** Date/Time : 2024-03-09, 10:48, # CodeGen: 0
**
** Copyright 1997 - 2015 Freescale Semiconductor, Inc.
** Copyright 2016-2017 NXP
** All Rights Reserved.
**
** THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
** IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
** INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
** STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
** IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
** THE POSSIBILITY OF SUCH DAMAGE.
** ###################################################################*/
/*!
** @file fccu1.c
** @version 01.00
*/
/*!
** @addtogroup fccu1_module fccu1 module documentation
** @{
*/
/*
* @page misra_violations MISRA-C:2012 violations
*
* @section [global]
* Violates MISRA 2012 Advisory Rule 8.7, External could be made static.
* The function is defined for use by application code.
*
* @section [global]
* Violates MISRA 2012 Required Rule 10.1, Unpermitted operand to operator '<<'
* The shifting operation don't exceed size of the variable, used to mark bit
* flags for different actions
*
* @section [global]
* Violates MISRA 2012 Required Rule 11.8, Attempt to cast away const/volatile from
* a pointer or reference
* The cast is required to initialize the pointer for EOUT configuration structure
*
*/

/* MODULE fccu1. */

#include "fccu1.h"

/*! fccu1 configuration structure */
/*! @brief Noncritical fault configuration 0 */
/*! @brief Number 0 */
const fccu_config_ncf_t fccu1_NcfConfig0_0 =
{
.functionID = 8U,
.hwSwRecovery = FCCU_NCF_SW_REC_FAULT,
.reset = FCCU_NCFS_SHORT_RESET,
.timeoutEnable = false,
.reactionType = 0U,
.callback = NULL,
.callbackParam = NULL
};
/*! @brief Number 1 */
const fccu_config_ncf_t fccu1_NcfConfig0_1 =
{
.functionID = 12U,
.hwSwRecovery = FCCU_NCF_HW_REC_FAULT,
.reset = FCCU_NCFS_NO_RESET,
.timeoutEnable = false,
.reactionType = (1<<FCCU_INT_NMI),
.callback = NULL,
.callbackParam = NULL
};
/*! @brief Number 2 */
const fccu_config_ncf_t fccu1_NcfConfig0_2 =
{
.functionID = 69U,
.hwSwRecovery = FCCU_NCF_SW_REC_FAULT,
.reset = FCCU_NCFS_NO_RESET,
.timeoutEnable = true,
.reactionType = (1<<FCCU_INT_ALARM),
.callback = TestAlarm,
.callbackParam = NULL
};
/*! @brief Configuration 0 */
const fccu_config_ncf_t * fccu1_NcfConfig0[] =
{
&fccu1_NcfConfig0_0,
&fccu1_NcfConfig0_1,
&fccu1_NcfConfig0_2
};


/*! @brief EOUT configuration */
/*! @brief Configuration 0 */
const fccu_eout_config_t fccu1_EoutConfig0 =
{
.activate = true,
.control = FCCU_FO_CONTROLLED_BY_FSM,//FCCU_FO_HIGH_UNTIL_FALUT_OCCUR,//FCCU_FO_CONTROLLED_BY_FSM,FCCU_FO_ALLWAY_LOW
.switchMode = false,
.mode = FCCU_FO_BISTABLE,// FCCU_FO_TIME_SWITCHING FCCU_FO_BISTABLE FCCU_FO_DUAL_RAIL
.prescaler = 10U,
.phase = FCCU_FO_OPPOSITE_PHASE_10,
.polarity = false,//false
.deltaFaultInterval = 0U
};


/*! @brief Control configuration */
/*! @brief Configuration 0 */
const fccu_control_t fccu1_Control0 =
{
.filterBypass = false,
.filterWidth = FCCU_FILTERWIDTH_UP_TO_50_US,
.debugEnable = false,
.irqEnableType = FCCU_IRQ_EN_NOIRQ,
.ncfTimeout = 2000U,
.configRun = (fccu_eout_config_t *)&fccu1_EoutConfig0,
.lockType = FCCU_LOCK_TYPE_NO_LOCK,
.ncfConfigNumber = 3U,
.callbackIsr = NULL,
.callbackIsrParam = NULL
};

/* END fccu1. */
/*!
** @}
*/
/*
** ###################################################################
**
** This file was created by Processor Expert 10.1 [05.21]
** for the NXP C55 series of microcontrollers.
**
** ###################################################################
*/

 

0 件の賞賛
返信
1 解決策
776件の閲覧回数
petervlna
NXP TechSupport
NXP TechSupport

Hello,

So you inject error before you change the protocol?

First change it and then inject error. Config mode is not accessible when you have fault active.

Also what about your FCCU CFG register?

petervlna_0-1710400058657.png

And also, do you enable the fault for Bi-stable?

petervlna_1-1710400201083.png

There is really no magic here, just set it correctly and it will output the signals.

Best regards,

Peter

元の投稿で解決策を見る

0 件の賞賛
返信
5 返答(返信)
832件の閲覧回数
petervlna
NXP TechSupport
NXP TechSupport

Hello,

When the fccu1_EoutConfig0.mode is set to FCCU_FO_BISTABLE. The output is not change when FCCU go to error state. The sequence of the EOUT[0] and EOUT[1] is not right. EOUT[0] is always high, and EOUT[1] is always low.

Well, ok. So are you injecting the FCCU error in order to get the FCCU into error state?

Second, FCCU is state machine, so in case you configure it correctly it will represent the behavior of configuration.

Best regards,

Peter

0 件の賞賛
返信
798件の閲覧回数
shaoduoduo
Contributor I

could you give me a demo which use bitsatble setting and run on the devkit-MPC5744P board。

0 件の賞賛
返信
823件の閲覧回数
shaoduoduo
Contributor I

yes .I did  inject the FCCU error in order to get the FCCU into error state.

But when fccu1_EoutConfig0.mode is set to FCCU_FO_DUAL_RAIL or FCCU_FO_TIME_SWITCHING. The output sequence of the EOUT[0] and EOUT[1] is right.when I injected errors,the output changed like thisshaoduoduo_0-1710340998353.png

 

but when I set  fccu1_EoutConfig0.mode to  bitstable only,the output did not changed when I injected error.

I don't know where the settings are incorrect.

thanks very much

 

 

 

 

0 件の賞賛
返信
777件の閲覧回数
petervlna
NXP TechSupport
NXP TechSupport

Hello,

So you inject error before you change the protocol?

First change it and then inject error. Config mode is not accessible when you have fault active.

Also what about your FCCU CFG register?

petervlna_0-1710400058657.png

And also, do you enable the fault for Bi-stable?

petervlna_1-1710400201083.png

There is really no magic here, just set it correctly and it will output the signals.

Best regards,

Peter

0 件の賞賛
返信
767件の閲覧回数
shaoduoduo
Contributor I

thank you very much.

 

I add FCCU.EOUT_SIG_EN[0].R = 0xffffff,and the err OUT changed when the err occured.

 

 

god bless you .

0 件の賞賛
返信