HotFix: MBD Toolbox rev2.0.0 for MPC5744P (Panther)

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

HotFix: MBD Toolbox rev2.0.0 for MPC5744P (Panther)

14,658件の閲覧回数
Daniel_Popa
NXP Employee
NXP Employee

HotFix_1: Missing lsp.h file 

 

Problem: Model compilation terminates with the following error:

SWLIBS_Defines.h:132:17: fatal error: lsp.h: No such file or directory
#include <lsp.h>

 

Root Cause: S32DS for PA version 1.1 Build id: 170203 does not contain the file in the compiler toolchain

 

Workaround: Save the file attached lsp.h in 

{S32DS for PA installation folder}S32_Power_v1.1\S32DS\e200_ewl2\EWL_C\include\pa\ folder

Original Attachment has been moved to: lsp.h.zip

ラベル(1)
30 返答(返信)

6,878件の閲覧回数
mahesh_narni
Contributor I

pastedImage_1.png

hello,

I am receiving this error while running PIL mode

could you please tell me solution  and how to rectify this issue

0 件の賞賛
返信

6,878件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello 飞 崔,

For Rev 3.0.0, in order to copy the required files you need to follow the response for this thread https://community.nxp.com/message/1145779?commentID=1145779#comment-1145779 (you need to rename the mbd_mpc574x_user_copy_required_files.m and and add there the sources). The mbd_mpc_copy is p-coded and added into path, so you don't need to search it. 

Unfortunately you can not avoid using the main() code generated process. You can add code instead, in the Initialization function generated which is called before the step functions. You can use the suggestion from this thread Including custom code to call in the initialize function the code you add from the S32DS.

Hope this helps,

Marius

0 件の賞賛
返信

6,879件の閲覧回数
c飞崔
Contributor I

thanks a lot, Marius. 

most of our code are handwirted including the main(), so i would like to find a way to compile the S32DS project through matlab environment. Maybe I had to manually configure and call S32DS compiler in matlab, to achieve expected result.

Do you have any instructions or guide documents about how to configure or call S32DS compiler in matlab? 

0 件の賞賛
返信

6,879件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello 飞 崔,

The toolbox uses the same compiler as in S32DS, only the makefile is different and it is regenerated each time the codegen button is pressed. I can not guide you through that, since the mbdt main() project is using the PIT peripheral to trigger the step function, initializes clocks and so on. But what you can do is to  use the custom code and copy the code from the S32DS project into Initialize function. 

Hope this helps,

Marius

0 件の賞賛
返信

6,878件の閲覧回数
c飞崔
Contributor I

OK,I wil give it a try,thanks.

0 件の賞賛
返信

6,879件の閲覧回数
c飞崔
Contributor I

dumitru-daniel.popa jimtrudeau

We face a challenge :

   Our project is partly design by simulink, the hardware drive codes and main function is handwirted in S32DS. We got the project code (partly generate by simulink, partly handwrite) compiled in S32DS successfully. but to simplify the compile process, we need to compile the project by matlab rather than S32DS. 

   My question is: Can i compile one S32DS project by the MBD tools? 

   expect for your reply.

0 件の賞賛
返信

6,879件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello 飞 崔

Assuming that you are using the Toolbox for MPC Rev 2.0.0, it you want to still make changes in simulink, you can make your model to automatically import the c sources developed in S32DS by using the mbd_pnt_user_copy_required_files.m script which you can be found under src\mbdtbx_pnt\mbdtbx_pnt\mscripts\utils path. This will copy the files from DS under the generated code and will add your files in makefile.

Hope this helps,

Marius

0 件の賞賛
返信

6,879件の閲覧回数
c飞崔
Contributor I

Thanks for your reply, i use Rev 3.0.0. i find a similar file mbd_mpc574x_user_copy_required_files.m, maybe i can use this file to copy .c&.h files. But i cannot find the mbd_mpc_copy() function used in the .m script, in which I  want to find how to copy *.c and *.h  under the generated code by one command.

If i use the 'MBD_MPC574x_Config_Information ' bolck in simulink library, it auto generate a main(). While the 'main() ' was handwrited, so i think it won't got the right compile result. So can i avoid the main code generated process?If so, how to configure it ?

0 件の賞賛
返信

6,879件の閲覧回数
1490491886
Contributor I

hello,can this MBD toolbox work in matlab 2018b?

0 件の賞賛
返信

6,879件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello 1490491886@qq.com‌,

If you are interested in using the Model Based Design Toolbox for MPC57xx Boards in Matlab 2018b you can download and install our newly released https://community.nxp.com/docs/DOC-342724 .

Best Regards, 

Marius

0 件の賞賛
返信

6,900件の閲覧回数
zongchen
Contributor I

xxx.PNG

Hello Daniel, When I was trying to generate code with matlab2017a, a message box came out. As no Evaluation Board was connected, then I press OK, another message box came out as below.

yyyy.PNG

Do you know how to solve this problem? Thanks in advance.

0 件の賞賛
返信

6,882件の閲覧回数
1506840872
Contributor II

Hey, 琛 踪

I am not NXP engineer but a developper working with MPC5744P as you. 

I have encountered the same question as yours before. The first messagebox came out because you click the checkbox as below. 

Actually, if you click the checkbox, the Simulink will start the Rappid Bootloader and enable the download process. If you unclick, the Simulink will just generate code, not downlaod.

When the messagebox came out ,the Simulink has been in the process of downloading. If the EVB is connected to the USB port, you can restart the EVB and then bootloader works.

pastedImage_1.png

The second messagebox came out because your EVB is not connected to the USB! The bootloader scan the USB port and found no serialport is connected, then the error messagebox came out.

Maybe we can have a communication about the MCU.

0 件の賞賛
返信

6,899件の閲覧回数
constantinrazva
NXP Employee
NXP Employee

HotFix_9: Fix "Undefined function 'slsfnagctlr'..." when trying to generate code on R2016b/R2017a

 

Problem: If you try to generate code for any model on R2016b/R2017a, you will receive this error: "Undefined function 'slsfnagctlr' for input arguments of type 'char'." 

 

Root Cause: Matlab API change.

 

Workaround:  Download slsfnagctlr.p in the following folder

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\mscripts

0 件の賞賛
返信

6,899件の閲覧回数
adrienpol
Contributor II

HotFix_8: CAN Bus 1 And CAN Receive Data Trigger block


NXP Tracking number:  ???

 

Problem:

  • CAN Bus 1 was not working, (none Rx or Tx).
  • The block "CAN Receive Data Trigger" was not working with CAN Bus 1 and 2. (=> Crash )

 

Root Cause:

  • Wrong pin declaration for the CAN Bus 1
  • Interrupt from trigger block was not clear for CAN Bus 1 and 2.

 

Workaround:  Update the files attached in the following folders: (Files are based on the HotFix_7)

 

{Toolbox install dir}\mbdtbx_pnt\src\mbdtbx_pnt\src\c_library  folder flexcan_pnt_library.c file

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\blocks\can  folder can_pnt_receive_data_trigger.tlc file

6,899件の閲覧回数
Daniel_Popa
NXP Employee
NXP Employee

Thank you Adrien for helping with this. 

mariuslucianandrei‌, can you please add the Jira number and integrate this fix in our database.

6,899件の閲覧回数
janexzj
Contributor I

Hello,@dumitru-daniel.popa

I found a problem using MBD Toolbox along with S-Function Builder. I could run or bulid the model which contained the block created by S-function builder without the block from MBD Toolbox. But if I put the the block created by S-function builder and the block from MBD Toolbox together and build the model again, there would be an error like the picture below. 'crctry_wrapper.c' was created by S-function builder.

图片1.png

I tried again using Legacy Code Tool to build a same block. I could also run or build the model which contained the block created by S-function builder without the block from MBD Toolbox. But there was a similar problem when I built the model containing the block created by S-function builder and the blocks from MBD Toolbox. 'CRC.c' was the c code used by Legacy Code Tool.

捕获1.PNG

Is there any way to solve the problem?

0 件の賞賛
返信

6,899件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

Hello, 

Thank you adrienpol‌ for your fix.

I have integrated the fix in our database. The NXP tracking number is AST-962.

Marius

6,899件の閲覧回数
mariuslucianand
NXP Employee
NXP Employee

HotFix_7: CAN Recevier issue


NXP Tracking number:   AST-908 

Problem: CAN Receiver issue, it works only when one block is used. When is used another block, many of the can messages will be ignored.

 

Root Cause: Coding logic error.

 

Workaround:  Update the files attached in the following folders:

{Toolbox install dir}\mbdtbx_pnt\src\mbdtbx_pnt\src\c_library  folder flexcan_pnt_library.c file

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\blocks\can  folder can_pnt_receive_data_trigger.tlc file

Customer Report: CAN Recevier issue 

Special thanks to 剑明肖‌for testing and fix confirmation.

0 件の賞賛
返信

6,899件の閲覧回数
adrienpol
Contributor II

Hello,

I found an other problem on this "flexcan_pnt_library.c". The CAN Bus 1 was not working on my board due to a wrong imsr declaration in the library :

Was :
/*FlexCAN_1 :  mscr |mscr_value | imsr | imscr_value*/
static can_pinMux pinMux_1_TxD[] = { { 14, 0x32810001, 0,  0 } };
static can_pinMux pinMux_1_RxD[] = { { 15, 0x30080000, 32, 0x00000001 },
                                     { 17, 0x30080000, 32, 0x00000002 }  };

Sould be :

/*FlexCAN_1 :  mscr |mscr_value | imsr | imscr_value*/
static can_pinMux pinMux_1_TxD[] = { { 14, 0x32810001, 0,  0 } };
static can_pinMux pinMux_1_RxD[] = { { 15, 0x30080000, 33, 0x00000001 },
                                     { 17, 0x30080000, 33, 0x00000002 }  };

If you can confirm it :smileywink:

0 件の賞賛
返信

6,899件の閲覧回数
constantinrazva
NXP Employee
NXP Employee

HotFix_6: DMA config block - address and channel issue

NXP Tracking numberAST-830

 

Problem: DMA config block - address input not working for all hex numbers and some DMA channels are not usable.

 

Root Cause: Coding logic error.

 

Workaround:  Update the files attached in the following folders:

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\mbdtargetmainlibpnt.tlc

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\mbd_pnt_ec_toolbox.slx

{Toolbox install dir}\mbdtbx_pnt\mbdtbx_pnt\mscripts\dma\mbd_pnt_dma_config_ch_num.p

0 件の賞賛
返信