emWin + LPCOpen 2.10 = INCOMPATIBLE ?

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

emWin + LPCOpen 2.10 = INCOMPATIBLE ?

1,575 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Mon Apr 07 13:34:52 MST 2014
Hi!

I got my custom board with LPC1754 working with LPCOpen 2.10. Now I added this 2.4'' color TFT to the board. The driver is ILI9341.

I've downloaded emWin 5.22 BSP for EA1788 board and imported it to my workspace.

I was following the AN11218, explaining how to port EA LPC1788 BSP to a different board until the point 2.2 where it is asked to replace LPC177x_8x.h for LPC17xx.h, system_LPC177x_8x.c for system_LPC17xx.c and system_LPC177x_8x.h for system_LPC17xx.h.

Now, taking a look at LPCOpen I'm not sure what files should I use for my LPC1754 board as I can't seem to find the ones that are advised by the application note.



Any thoughs?

Labels (1)
0 Kudos
Reply
16 Replies

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Wed Apr 16 17:46:57 MST 2014
Using version 7.1.1 I got the exact same errors. Attached to this goes the log.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Wed Apr 16 07:11:28 MST 2014
I'm using LPCXpresso 7.0.2 and I didn't install any other plugins...

I've managed to compile and debug other projects succesfully with this version though...
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Wed Apr 16 06:48:09 MST 2014
It looks like you have a corrupted installation.
- which version of LPCXpresso are you using?
- have you installed any additional plugins?

Whatever, I suggest you download and install v7.1.1
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Wed Apr 16 06:03:27 MST 2014
Here you go
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Wed Apr 16 05:57:00 MST 2014
No, that is not it. Please post (attach) the file. You can rename it to log.txt.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Wed Apr 16 05:41:50 MST 2014
My posts get blocked by the spam filter if I post the hole log. I found this messages there, that I guess might point to the problem:

!ENTRY org.eclipse.ui.workbench 4 2 2014-04-16 02:09:36.601
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.ui.workbench".
!STACK 0


!ENTRY org.eclipse.ui.workbench 4 2 2014-04-16 02:09:36.670
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.ui.workbench".
!STACK 0
org.eclipse.core.runtime.AssertionFailedException: null argument:



!ENTRY org.eclipse.core.jobs 2 2 2014-04-16 03:08:11.174
!MESSAGE Job found still running after platform shutdown.  Jobs should be canceled by the plugin that scheduled them during shutdown: org.eclipse.cdt.internal.core.pdom.PDOMIndexerJob$ProgressUpdateJob
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Wed Apr 16 00:42:30 MST 2014
This is an internal error in the IDE. Please post
[your_workspace]/.metadata/.log

and we can investigate.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Tue Apr 15 19:00:05 MST 2014
Hey Wouter,

Thanks for the reply!

While waiting from an answer from nxp I went "quick & dirty" trying to write something on my TFT. I think that I'm close to do it now so, I'll try this method first before moving on to the more challenging LPCOpen approach. Are you thinking about creating some AppNote on how to port emWin using LPCOpen any time soon?


Anyway, after doing all the steps indicated on the http://www.lpcware.com/content/nxpfile/emwin-porting-guide-ea-lpc1788-bsp-keil-mcb1700-english-versi... I got a strange error and warning saying that there is a missing file (strangely the warning has been there since I imported the file to edit, even before I compile it!).

When I click on the Errors tab a window comes up saying "An error has occurred. See error log for more details". Thing is, I can't find any error on the log...

I attached a picture of the error. Do you have any idea what might this be?

0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by nxpsupport on Tue Apr 15 13:54:00 MST 2014
The emWin examples that will work with the current emWin library (released on LPCware.com) are:

[list]
  [*]emWin examples for LPC1857 [uses M3 library] (Keil MCB1800) [emWin helloworld example and emwin touch screen example]
  [*]emWin examples for LPC4357 [uses M4 library] (Keil MCB4357) [emWin hello world example, emwin touch screen example and emwin dualcore counter dialog example – can be used with blinky in M0 or lwip in M0]
  [*]emWin examples for LPC4357-M0 [uses M0 library] (Keil MCB4357) [emWin dualcore counter dialog example – can be uses
along with blinky in M4 or lwip in M4]
[/list]

We will look into adding more MCU family board examples. 

Best regards,
-NXP Support
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Wouter on Tue Apr 15 11:09:00 MST 2014
Hi guys,

Let me try to clarify things a bit:
- The porting guide is about porting one of the emWin BSPs (as available on the emWin project page) to a different target. The BSPs are based on the older (and deprecated) CDL/PDL. LPCOpen uses a quite different way to handle NXP's portfolio of MCU products. Therefore, the porting guide does not really apply to LPCOpen + emWin.
- The emWin library we provide, is just the compiled source code we receive from Segger. We do not add anything NXP specific to it. This way it's basically compatible to all software frameworks; emWin just does the graphical stuff, it's up to the rest of the code to interface to the HW (e.g. LCD, touchscreen and joystick).

Then also:
- Because of the emWin license, we cannot include the compiled emWin libraries in LPCOpen (also it would inflate the LPCOpen size quite a bit).Therefore the user must add the libraries (*.a, *.lib) and header files (*.h) to LPCOpen themselves.
- The older LPCOpen (up to V1.03) had emWin examples for parts with LCD controller (e.g. LPC43xx). In newer releases (>=V2), these emWin examples were not included anymore. (Sorry. not right after all, see  my edit below...)

Then regarding zepedrowdp's problem:
The preferred method would be to stick with your LPCOpen 2.10 port (with custom board). Then something like:
1. Add the latest emWin library release to the LPCOpen (e.g. at LPCOpen\Software\emWin).
2. Initialize the HW interface to the display and the display itself. Most logical choice would be to do this in the board_init.
3. In your application, add an LPCOpen compatible version of GUI_X.c, GUIConf.c and LCDConf.c. This will probably be the trickiest part, you may find the LPCOpen V1.03 emWin example helpful for that. Since your using an LPC with no LCD controller, your LCDConf.c will be a mix of the LPCOpen V1.03 LCDConf.c file and the LCDConf.c file from the MCB1700 BSP (which also uses an LPC without LCD controller).
4. Then you can start your emWin application (GUI_Init(), GUI_CreateDialogBox(), etc.)

If you want to go quick & dirty, it may be easier to simply use the MCB1700 emWin BSP and port it to your board...

Regards,
Wouter

EDIT: Sorry, seems to have missed current LPCOpen indeed still has the emWin examples for the LPC1800/LPC4300 as commented in the post below.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by rgledhill on Sat Apr 12 12:03:17 MST 2014
That's true, but the previous pre-compiled binary libraries available from NXP were using modified emWin source code which matched the CMSIS driver set.  It sounds like they haven't updated their emWin source code and rebuilt it so that it's compatible with LPCOpen.

Certainly previous versions (e.g. 5.20) have worked "out of the box" with the CMSIS driver sets - I know because we used it!

Richard
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by YOZHik on Fri Apr 11 14:06:19 MST 2014
The short answer is yes. emWin is just a precompiled library with header files. It has nothing to do with LPCOpen or whatever you use. Obviously it is a user's responsibility to implement all necessary functions to make emWin work with hardware (LCD initialization, touch screen, SDRAM initialization, ...).
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Fri Apr 11 11:17:17 MST 2014
Hmm, so I need to change the names of all the symbols that are causing errors for being named different on LPCOpen CMSIS? It's just that I've got 50+ errors related with this (all different variables and symbols) and I thought it should be a better way to do this other than alter line by line.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by YOZHik on Fri Apr 11 11:09:55 MST 2014
emWin can not be incompatible with LPCOpen 2.10. Simply include new LPCOpen headers/library, give hardware initialization function calls proper names and change their input parameters where necessary. It should be pretty easy.
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Fri Apr 11 11:02:18 MST 2014
I tried to compile emWin using LPCOpen version of CMSIS and checking the errors resulting from this I concluded that emWin is simply incompatible with LPCOpen 2.10...

All the nomenclature used is different (name of the peripherals, and the variables present in their structures) so in each function of LCDconf.c I got errors.

Would be nice to have a comment from someone represeting NXP regarding this matter...
0 Kudos
Reply

1,486 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by zepedrowdp on Wed Apr 09 10:07:28 MST 2014
Seems like most of the definitions and functions present on LPC17xx.h are divided by a couple of different .h files on LPCOpen CMSIS (cmsis_175x_6x.h, chip_lpc175x_6x.h, etc...).
If I'm thinking right, all of these files are included on the file chip.h.

Is it advisable for me to replace LPC177x_8x.h for chip.h and hope to end up with the same result, or should I just disregard LPCOpen CMSIS and use the CMSIS that comes on LPCXpresso Examples folder?


I'm still uncertain about the system_LPC177x.c and .h, but I guess including chip.h might solve this too...


What do you think?

0 Kudos
Reply