Moving MQX Development Tools to another PC

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Moving MQX Development Tools to another PC

Jump to solution
2,272 Views
myke_predko
Senior Contributor III

Hiya,

I haven't been on here in a while, but I wanted to see if there's a quick answer to my problem.  

I've been running my application on a Windows 7 PC for a number of years without any problems (including backing up the source code and keeping the original installation programs).  The PC has died and I wanted to move my development tools to another (Windows 7) PC.  

This MQX 4 for CodeWarrior 10.4.  I install MQX followed by CW, when CW comes up for the first time, I do all the updates.  I've copied in my project folder from the previous system.

When I start up CW, I get the "Start Multiple Errors" dialog box that's below.  There's no useful information other than saying "Unknown target type".  I've looked through "Properties" in the project and I can't find any setting for that - I would have thought that information would be copied in with the project.  I've sent this in as an issue to NXP as well.

2018.07.06 - CW Start Multiple Errors 2.png

When I try to build, everything seems to compile okay but the linker upchucks with:

**** Build of configuration j20_Int_Flash_Debug for project J20_Test_45 ****

C:\Freescale\CW MCU v10.4\gnu\bin\mingw32-make -j8 all
'Building target: J20_Test_45.afx'
'Executing target #59 J20_Test_45.afx'
'Invoking: ARM Linker'
"C:/Freescale/CW MCU v10.4/MCU/ARM_Tools/Command_Line_Tools/mwldarm" -o "J20_Test_45.afx" @@"J20_Test_45.args"
C:/Freescale/CW MCU v10.4/MCU/ARM_Tools/Command_Line_Tools/mwldarm|Linker|Warning
>Symbol _bsp_get_adc_base_address multiply defined in bsp.a(lwadc_k20_c.o )
>and bsp.a(adc_mk20_c.o )
>Ignoring the definition in bsp.a(lwadc_k20_c.o )
>psp.a(comp_c.o )
>Ignoring the definition in libc99_Thumb_LE_v7M.a(abort_exit.o )
>psp.a(comp_c.o )
>Ignoring the definition in libc99_Thumb_LE_v7M.a(alloc.o )
>psp.a(comp_c.o )
>Ignoring the definition in libc99_Thumb_LE_v7M.a(alloc.o )
>psp.a(comp_c.o )
>Ignoring the definition in libc99_Thumb_LE_v7M.a(alloc.o )

I suspect that it's not bringing in the correct bsp (I created one for the project).  

Can anybody point me in the right direction to get these builds working?

UPDATE 2018.08.08 - Added console log with build result after installing MQX first as was suggested below.

1 Solution
1,678 Views
myke_predko
Senior Contributor III

SUCCESS!!!!

I was able to review my notes from five years ago (something that I wanted to avoid) and go through the process of recreating the BSP.  Over the past month, I've been going through and reviewing the process and testing it so I'm very confident that it works.  

I've attached the document that I created for creating the BSP if anybody is interested.  

Now, I think I'll toodle around with MCUXpresso and consider moving my app to FreeRTOS.  

Thanx to everybody for their suggestions and help.

View solution in original post

25 Replies
1,679 Views
myke_predko
Senior Contributor III

SUCCESS!!!!

I was able to review my notes from five years ago (something that I wanted to avoid) and go through the process of recreating the BSP.  Over the past month, I've been going through and reviewing the process and testing it so I'm very confident that it works.  

I've attached the document that I created for creating the BSP if anybody is interested.  

Now, I think I'll toodle around with MCUXpresso and consider moving my app to FreeRTOS.  

Thanx to everybody for their suggestions and help.

1,574 Views
danielchen
NXP TechSupport
NXP TechSupport

Glad to hear the good news.  Thanks for your sharing.

Regards

Daniel

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Okay, I'm moving forwards - two steps forwards but one back.  

Using BSP Cloning Wizard, I created a new BSP based on TWRK60D100M and then modified it to match the original BSP using "Freescale MQXTM RTOS BSP Porting Guide" (Document Number: MQXBSPPG) and then clicked on "Generate MQX Projects".  All good and I'm comfortable with the changes I made before generating the MQX Projects.  

Here are the results of Cloning Wizard and I've attached the Console Log for generating the projects to this post):

2018.08.12 - BSPCloningWizard Results.png

Next, I went back to CW to drag in the .wsd file for my bsp named "j20" (from Freescale_MQX_4_0\config\j20\cw10) and I got this:

2018.08.12 - Problem Adding the bsp-psp.png

I would have thought that the bsp/psp would be included here.  

Can anybody point me to what I'm doing wrong?  

Thanx,

myke

0 Kudos
1,572 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi Myke,

I performed the same test. But there is no error message from my side.

pastedImage_1.png

video is attached.  Can you please try again?


Have a great day,
Jennie Zhang

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
1,573 Views
myke_predko
Senior Contributor III

Hi Jennie,

Just looking over the FAILED files in the previous post, I noticed that a lot of these errors are with files that I copied over.  

In some cases they're new but in most others, they've been changed.  

Should I try, cloning the new bsp, generating the projects, importing the projects (as per your video) and *then* changing the various files in CW?  

Thoughts on this?

Thanx,

myke

0 Kudos
1,573 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi Myke,

In your step 3, you modify MQX files. I don't suggest you do this. You don't need modify anything.

pastedImage_1.png

then click on "Generate MQX Project". to generate .wsd serials of files. then import .wsd as I showed in my video. Build BSP and PSP. there should be no error.

I suggest you try this basic steps first to guarantee your basic system procedure is correct.

Best Regards

Jennie

1,573 Views
myke_predko
Senior Contributor III

Hi Jennie,

Okay, I've run through Steps 1. through 8. without any issues.  I was able to build the bsp and psp without any issues.  

Now, I want to bring in my project files (Step 9. above - the one I was pretty sure wouldn't work).  As I indicated above, I am expecting to be able to create a new project and have the board type show up.  But, when I try to do that, the new/cloned "j20" board type does not show up in the list of Kinetis board types (this was the problem I was expecting):

2018.08.18 - Imported j20.bsp build results - How to add Board to Project.png

What do I do to bring in the board files (bsp, psp, etc.) into the list of boards to select from the project.  When I read through MQXBSPPG, this isn't explained (actually, if you read the document, the approach I took before, updating the board files *before* importing to CW seems to be the correct way of doing things).  

Thanx - I know we're almost there,

myke

0 Kudos
1,573 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi Myke,

Please refer this discussion about adding new board to CW project wizard.

https://community.nxp.com/thread/328167 

Best Regards,

Jennie

0 Kudos
1,573 Views
myke_predko
Senior Contributor III

Hi Jennie,

Thanx for the pointer, but that's not the issue that I'm having.  Sorry, I should have explained that I did figure out how to update the xml files.  

What I'm asking for is adding files to the bsp and psp projects.  When I try adding files in CW for these files, all I get is links that aren't being referenced during the build.  As I indicated in the previous email, I *think* I have to update .project and .cproject - Is this correct and is there a less error prone way of doing this?  

My notes on the changes and how they are working are below.

Thanx!

myke

0. Make sure CW isn't active.
1. Find the board bsp was cloned from in C:\Freescale\CW MCU v11.0\MCU\lib\wizard_data\mqx\4.0\arm
2. Copy the mqx_baseboard.xml into the mqx_newboard.xml
3. Open mqx_newboard.xml in an editor:
3.1. find and replace all instances of ID_BOARD_baseboard to ID_BOARD_newboard
3.2. Change '<elementChoice name="baseboard Board"' to '<elementChoice name="newboard Board"'
3.3. Change `<variable name="BoardName" value="baseboard"` to `<variable name="BoardName" value="newboard"`
3.4. Look for all occurences of the baseboard processor and change to new processor
3.4.1. Leave `contentHelp` alone
4. Restart CW and see if the board shows up in `New MQX 4 Project` - yes it does
5. Try to rebuild the new project in CW - successful


Changes to the build:
1. "C:\Freescale\Freescale_MQX_4_0\config\j20\user_config.h" is different/done/verified
2. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\bsp.h" is different/done/verified
3. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\bsp_prv.h" is different/done/verified
4. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\init_bsp.c" is different/done/verified
5. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\init_gpio.c" is different/done/verified
6. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\init_lpm.c" is different/done/verified
7. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\init_sci.c" is different/done/verified
8. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\j20.h" is different/done/verified
9. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\flashx\freescale\flash_ftfl.c" is different/done/verified
10. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\flashx\freescale\flash_ftfl_prv.h" is different/done/verified
11. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\i2c\i2c_ki2c.h" is different/done/verified
12. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\serial\int\serl_int.c" is different/done/verified
13. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\serial\int\serl_int_kuart.c" is different/done/verified
14. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\serial\serial.h" is different/done/verified
15. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\serial\serl_kuart.h" is different/done/verified
16. "C:\Freescale\Freescale_MQX_4_0\mqx\source\psp\cortex_m\kinetis.h" is different/done/verified - NOTE: Looking for MK20D10.h
17. "C:\Freescale\Freescale_MQX_4_0\mqx\source\psp\cortex_m\psp_cpudef.h" is different/done/verified
18. "C:\Freescale\Freescale_MQX_4_0\lib\j20.cw10\dbg\j20.mem" is different - Not found/Changed Manually in folder with CW closed
19. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\cw\dbg\j20.mem" is different - Not found/Changed Manually in folder with CW closed
20. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\cw\intflash.lcf" is different - Not found/Changed Manually in folder with CW closed
21. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\cw\intram.lcf" is different - Not found/Changed Manually in folder with CW closed

22. "C:\Freescale\Freescale_MQX_4_0\mqx\source\bsp\j20\init_lwadc.c" NOT THERE /added/In CW but NOT in MQX Folder
23. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\i2c\int\i2c_int_k_fb.c" NOT THERE /added/In CW but NOT in MQX Folder
24. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\adc\kadc\adc_mk20.c" is different - Not found/adc_mk20.c Replaced adc_mk60.c
25. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\adc\kadc\adc_mk20.h" is different - Not found/adc_mk20.h Replaced adc_mk60.h
26. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\i2c\i2c_mk20.c" is different - Not found/i2c_mk20.h Replaced i2c_mk60.h
27. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\lwadc\lwadc_k20.c" NOT THERE - Folder not found/Copied Folder Contents from Backup
28. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\serial\serl_mk20.c is different - Not found/serl_mk20.h Replaced serl_mk60.h
29. "C:\Freescale\Freescale_MQX_4_0\mqx\source\io\spi\spi_mk20.c" is different - Not found/spi_mk20.h Replaced spi_mk60.h
30. "C:\Freescale\Freescale_MQX_4_0\mqx\source\psp\cortex_m\cpu\MK20D10.h" NOT THERE - Not found/MK20D10.h from Backup Replaced MK60D10.h

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Just doing a kDiff on .project and .cproject.  The changes look fairly straight forward but in .cproject there are a lot of 'errorParsers=""' statement differences (in the new version rather than the old) that I'm going to leave in.  

I'll let you know how it goes...

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Jennie,

I'm reloading yet again.  

My process will be:

  1. Remove MQX and CW (in that order) and it's done.  
  2. Install CW 11
  3. Install MQX
  4. Start CW and load the Updates.  I don't need to "Install New Software" as after I do the updates, everything seems to be there.  
  5. Start BSPCloningWizard and create the bsp
  6. Using KDiff, I will record the differing files between my old bsp and the one that was created.  
  7. Restart BSPCloningWizard and generate the bsp.
  8. Drag the new .wsd into CW.
  9. Try to create a new MQX project using the bsp.  This is something I don't think will work as I have never seen the new bsp coming up in the list of boards for the new MQX projects.  
  10. IFF the MQX project can take the bsp, then I will start modifying the bsp to include the updated files and then build.  
  11. IFF the previous two steps are good, I will then put in my project files to get the MQX project working.  

How does that sound?  I'll let you know how things go as I get to step 9.  I'm currently on Step 3.  

Thanx for your patience with me,

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hiya,

I'm getting there, slowly and exceedingly frustratingly.  If you look at my list of todos:

  1. Remove MQX and CW (in that order) and it's done.  
  2. Install CW 11
  3. Install MQX
  4. Start CW and load the Updates.  I don't need to "Install New Software" as after I do the updates, everything seems to be there.  
  5. Start BSPCloningWizard and create the bsp
  6. Using KDiff, I will record the differing files between my old bsp and the one that was created.  
  7. Restart BSPCloningWizard and generate the bsp.
  8. Drag the new .wsd into CW.
  9. Try to create a new MQX project using the bsp.  This is something I don't think will work as I have never seen the new bsp coming up in the list of boards for the new MQX projects.  
  10. IFF the MQX project can take the bsp, then I will start modifying the bsp to include the updated files and then build.  
  11. IFF the previous two steps are good, I will then put in my project files to get the MQX project working.  

1. through 9. are successful.  

Now, I have identified the 30 files in the bsp to change, delete and add.  For:

- Changing, no problem, I make the changes to the files in CW

- Deleting.  This seems to be okay with what seems to be the link in the project being broken in the bsp/psp project without any issues.  

- Adding.  When I try to add a file, I drag it into the bsp/psp project in CW and get a message that it can't be copied, just a link included.  

When I try to build, the bsp/psp now fails with the added files not being found or referenced (ie when I add a .h file, the constants defined in it are not found).  

Looking around, I think I have to add my files to the MQX ("io" primarily) source files and then change the .project and .cproject files for the new bsp in C:\Freescale\Freescale_MQX_4_0\mqx\build\cw10\<bspName>\ to reference these files.

Is this correct and do I have to change anything else?  

I know I had all this written out but those notes were lost with the PC.  

Thanx,

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Jennie,

Well, one step forwards but still a ways to go. 

I did the following:

  1. Took down and then reloaded CW followed by MQX (including loading the updates). 
  2. I then ran BSPCloneWizard and created the new bsp. 
  3. Next, I modified the changed files in Freescale\Freescale_MQX_4_0 so they matched the original bsp. 
  4. I then restarted BSP Cloning Wizard and generated the projects (no errors).  
  5. Next I was able to import the bsp (as you showed in your video, thanx again) without any issues.  
  6. I then tried to build the project files, but only the psp would build correctly.  I tried the bsp with c9x and ewl (no differences).  I've attached the console logs of the build attempts.  
  7. On the off chance that things would work if I created a project, I tried to create a "New" project, but the bsp wasn't listed.  

What should I try next?  

I really appreciate your help and suggestions,

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Jennie,

I got a message saying that the "working sets were already installed".  

I suspect that the problem is with me and all the things I did previously.  

So, I'm going to clear out CW and MQX and start again - I'll let you know.

Thanx for the video, it was really helpful.

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Jennie,

Just saw the video and see where I went wrong - I'll try it this afternoon and let you know.

Thanx!

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Daniel,

Tried it, no joy.  When I did a build I get the console dump that I've attached to the Original Post (I can't see where to attach something to a reply).  

Any other ideas?

myke

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Okay, I've tried to creating a new project folder to see if I can create a new project and copy in the source and build from there.  

When I try to create the new project, my bsp doesn't appear as one of the target systems - I tried to copy in the contents of "Freescale_MQX_4_0" but it still isn't finding the target system.  I'm trying BSPCloningWizard but it's failing with a Java code 13:

2018.08.08 - Cloning Wizard Failure.png


Can anybody help point me in the right direction?  I feel like I'm 95% of the way there, I just need to get pointed in the right direction.

Thanx!

0 Kudos
1,574 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi,

I also wonder this is because of incomplete CW install. Because the error means your CW can't recognize your target. Please install all MQX related updates as Daniel suggested. Daniel's screenshot is for CW10.6 but you should find similar update for 10.4 in the same way.

Besides, what MCU do you work with? please install all the related MCU update for CW10.4 also. (for example, you use kinetis, please also install "Kinetis support")

If the problem still exists after install MCU and MQX updates, I would suggest you try newer version. CW10.4 is too old.

For MQX4.0,  it has been tested and confirmed to work with CW for MCU10.6. I would suggest you use CW10.6+MQX4.0 instead.

Best Regards,

Jennie Zhang.

0 Kudos
1,574 Views
myke_predko
Senior Contributor III

Hi Jennie,

I can't download CW for MCU 10.6 because my Flexera account is inactive and I can't find the login page - anybody have any ideas?

I've reached out to my FAE (who's on vacation) so if anybody has any ideas, I'd appreciate them.  

myke

0 Kudos
1,574 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Which account do you use? I just checked your account of @mimetics.ca. It is active now. Can you try again?

0 Kudos