Documentation inconsistency or error for MC3377xB Register Write block in MBDT S32K1xx

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

Documentation inconsistency or error for MC3377xB Register Write block in MBDT S32K1xx

ソリューションへジャンプ
1,494件の閲覧回数
ranulf
Contributor IV

I'm referring to the block at NXP Model-Based Design Toolbox for S32K1xx MCUs/External Devices/Battery Management System/BMS/MC3377xB Register Write

@mariuslucianand  The block in Simulink shows a data type mismatch between the constant (uint16) feeding Reg Value the Reg Value port (uint8). See below.

RegisterWriteInSimulink.png

The documentation shows that Reg Value is a UINT16. See below.

RegisterWriteDocs.png

Which is in error? I think the block port is in error because register values have 16 bits.

0 件の賞賛
返信
1 解決策
1,479件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello @ranulf,

You are right, the issue is with the block not with the documentation.

To get the right input value type, please replace the mc3377xb_s32k_reg_write.mexw64 file, from the archive attached to the {Toolbox install path}\external_devices\blocks\mc3377xb.

To find the Toolbox install path, please type the mbd_find_s32k_root command in Matlab.

Hope this helps,

Marius

元の投稿で解決策を見る

4 返答(返信)
1,475件の閲覧回数
ranulf
Contributor IV

Hi @mariuslucianand ,

I followed your instructions and now the block Reg Value port has the correct data type. However, I have not been successful in changing register values. I can read them but not change them. This perhaps is a different question and issue. 

0 件の賞賛
返信
1,471件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello @ranulf ,

I will investigate the behavior that you have mentioned and reply tomorrow. Until then, I remember that I've noticed at some point a reinitialization behavior to the battery cell controller and provided a file called  mbdtargetmainlibs32k.tlc that prevents this to happen. I wonder if the block writes the register but due to this reinitialization, the value is set back to reset. 

You can find the file that I am talking about here together with instructions.  https://community.nxp.com/t5/NXP-Model-Based-Design-Tools/How-to-put-S32K-MCU-into-sleep-low-power-m... 

Hope this helps,

Marius

1,463件の閲覧回数
ranulf
Contributor IV

Hi Marius,

I followed your instructions and have replaced the indicated file. The file replacement appears to have made it possible or me to write register values!! I need to test, but it looks like the blocks related to cell balancing are changing register values. Please do test yourself. 

0 件の賞賛
返信
1,480件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello @ranulf,

You are right, the issue is with the block not with the documentation.

To get the right input value type, please replace the mc3377xb_s32k_reg_write.mexw64 file, from the archive attached to the {Toolbox install path}\external_devices\blocks\mc3377xb.

To find the Toolbox install path, please type the mbd_find_s32k_root command in Matlab.

Hope this helps,

Marius