Getting started problems

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

Getting started problems

1,478 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mfc on Mon Jan 10 04:36:56 MST 2011
Connected up my LPCXpresso [1114 target] this morning, and thought I'd follow through the Getting Started PDF first to check it is all working.  All went fine at first (apart for some minor difficulty logging in and out to activate) -- but then I got in a terrible mess in section 5.1.   The browse showed folders not archives, but by drilling down I found some .zip files and opened the LPCXpresso one, which seemed to work.

I then selected the Blinky and CMSIS projects (actually they had longer names) then Finish and debug build.   The console then showed a few error mesages (implicit declarations, etc.), ending with the helpful message "Error 1".  The next step just did not work at all.   I eventually got a clean compile by importing all the projects and re-starting (for some reason this needed to be done twice, as one project did not 'take' on the first attempt).

Download then proceeded relatively smoothly and the LED started blinking.   I then changed the timing parameters in the C code, and re-started the build.  This refused to download at the end (device in use), so I then clicked terminate in the debug window.  At this point, nothing happened until a few seconds later when a dialogue pops up: "target request failed: failed to interrupt".  Nothing I tried seemed to get around this until I unplugged and replugged the USB and restarted the IDE, at which point it would download the new code and I could observe the different flash rate.   I checked the troubleshooting hints but nothing seems to apply ([I]e.g[/I]., the correct device is shown).

Surely it is not necessary to unplug the device before every download?

This is all quite frustrating -- the instructions in the Getting Started document just do not work as written.  :(

Software & the Getting Started document (Sept. 2010) downloaded this morning.  OpSys is Windows 7.

Mike Cowlishaw
0 Kudos
Reply
8 Replies

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mfc on Tue Jan 11 08:29:18 MST 2011

Quote: igorsk
I'm not sure what's starter.exe, but csrss.exe and conhost.exe provide support for console (command-line) programs. Just try opening a command prompt (cmd.exe) and you'll see them.



OK, thanks.  I had no windows (command-line or others) open at the time, so I suspect these were running as part of the un-dead Eclipse application (which I had closed some hours before) .  <sigh> 

A reboot did 'fix' them, thankfully.

Mike
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by igorsk on Tue Jan 11 08:18:36 MST 2011

Quote: mfc

along with the more mysterious

[COLOR=navy]starter.exe[/COLOR]
[COLOR=navy]csrss.exe[/COLOR]
[COLOR=navy]conhost.exe[/COLOR]

none of which I normally expect to see in the process list.

Mike


I'm not sure what's starter.exe, but csrss.exe and conhost.exe provide support for console (command-line) programs. Just try opening a command prompt (cmd.exe) and you'll see them.
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mfc on Tue Jan 11 04:32:53 MST 2011
Hi, thanks for the reply -- some additional details below.

> I'm sorry you have been having problems getting started with your
> LPCxpresso1114.
>
> Looking again at your text, I think that you initial build problems
> were caused by picking the "wrong" set of LPCXpresso1114 examples.
> Inside the LPC11 examples subdirectory there are actually several
> sets of examples. I think that you chose "LPCXpresso1114.zip" which
> is a set of simple examples maintained by CodeRed.

Yes, there were three zips there and the Getting Started guide did
not say which. Since only one had 'LPCXpresso' in the name that
seemed the obvious one to select...

> This ZIP contains a number of application projects, plus TWO library
> projects - CMSIS and LPC11_Lib. The application projects require both
> of these library projects in order to build (this should be described
> in the readme contained within each project). As you originally did
> not import the LPC11_Lib project, building the blinky application
> failed.

Yes, that sounds right -- it was not finding GPIO functions, etc.

> The Getting Started was written by NXP and focusses on their more
> indepth examples for the LPC11xx. Unfortunately the LPCXpresso 3.6.x
> release pulls in some more recent examples from NXP, which no longer
> tie up 100% with the text given in the Getting Started Guide. We'll
> discuss with NXP updating the Getting Started Guide to match the
> latest examples provided with the product.

That would be a good idea; after all, it's the first thing one sees
after installing your IDE. :-)

> With regards to your problems connecting to the board, if you
> disconnect the debug session before starting a new debug session,
> then this should "just work". I certainly cannot provoke the same
> issue you are seeing with the second connection failing (LPCXpresso
> IDE 3.6.1 running on Win7/32bit talking to an LPCXpresso1114 board).

Note that I did not disconnect/terminate the debug session before I
rebuilt (I had no idea that might be necessary). After that, it was
'broken', and the Terminate button did not work either.

> If you continue to experience problems, then please provide more
> details of your setup, including:

I'm going to wait until the LPC1768/9 version is available before I
try again (I've decided porting my M3 code to M0 is low value), but
here is some additional information on yesterday's attempts:

> * What operating system are you using? And are you running it
> natively or via a virtual machine.

Windows 7, fully updated. Native.

> * What version of the LPCXpresso IDE are you using?

Downloaded yesterday.

> * What is the full error message that you actually see?

There was first a popup saying the device was in use, then on trying
Terminate the 'failure to Interrupt' message (see earlier post).

> * Are you connecting the LPCXPresso board directly to your PC's USB
> port, or via a USB hub. If via a hub, then try connecting directly.

It was connected directly.

> If directly, try via a powered hub (we don't normally recommend
> the use of a hub, but if you have a power issue with the USB ports
> on your PC, then this might help.

The PC is a Lenovo Thinkpad X200 .. I've tested earlier that it will
supply the full 500 mA.

> * Do you have any other hardware connected the the LPCXPresso board
> (external hardware, including, for example, an Embedded Artists
> baseboard). If so, try removing it.

None; just came out of the package.

> * Try swapping the USB cable for another one.

Will try to remember to try that, but the cable is use is short and
has ferrite; never had a problem with it (even very heavy traffic,
such as the Saleae Logic).

Mike
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by CodeRedSupport on Mon Jan 10 10:50:36 MST 2011
I'm sorry you have been having problems getting started with your LPCxpresso1114.

Looking again at your text, I think that you initial build problems were caused by picking the "wrong" set of LPCXpresso1114 examples. Inside the LPC11 examples subdirectory there are actually several sets of examples. I think that you chose "LPCXpresso1114.zip" which is a set of simple examples maintained by CodeRed.

This ZIP contains a number of application projects, plus TWO library projects - CMSIS and LPC11_Lib. The application projects require both of these library projects in order to build (this should be described in the readme contained within each project). As you originally did not import the LPC11_Lib project, building the blinky application failed.

The Getting Started was written by NXP and focusses on their more indepth examples for the LPC11xx. Unfortunately the LPCXpresso 3.6.x release pulls in some more recent examples from NXP, which no longer tie up 100% with the text given in the Getting Started Guide. We'll discuss with NXP updating the Getting Started Guide to match the latest examples provided with the product.

With regards to your problems connecting to the board, if you disconnect the debug session before starting a new debug session, then this should "just work". I certainly cannot provoke the same issue you are seeing with the second connection failing (LPCXpresso IDE 3.6.1 running on Win7/32bit talking to an LPCXpresso1114 board).

If you continue to experience problems, then please provide more details of your setup, including:

[LIST]
[*]What operating system are you using? And are you running it natively or via a virtual machine.
[*]What version of the LPCXpresso IDE are you using?
[*]What is the full error message that you actually see?
[*]Are you connecting the LPCXPresso board directly to your PC's USB  port, or via a USB hub. If via a hub, then try connecting directly. If  directly, try via a powered hub (we don't normally recommend the use of a  hub, but if you have a power issue with the USB ports on your PC, then  this might help.
[*]Do you have any other hardware connected the the LPCXPresso board  (external hardware, including, for example, an Embedded Artists  baseboard). If so, try removing it.
[*]Try swapping the USB cable for another one.
[/LIST]
Regards,
CodeRedSupport
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mfc on Mon Jan 10 08:40:08 MST 2011

Quote: CodeRedSupport
As jim.smith mentioned, before you start a new debug session, you must terminate the previous one (by pressing the red Stop button in the Debug view). .



Hi, thanks for the reposnses, but I tried the Terminate button (see my original post below) -- several times.   It just provoked the 'Failed' message.   I only 'pulled the plug' as a last resort.

(On the lesser problem of CPU usage .. understand the issues with Windows processes, although it looked as though they were related .. however I don't understand why the application that started the debug processes cannot terminate the processes it spawned before it closed itself -- it has the handles.)

Mike
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by CodeRedSupport on Mon Jan 10 08:24:51 MST 2011
As jim.smith mentioned, before you start a new debug session, you must terminate the previous one (by pressing the red Stop button in the Debug view).

If you just 'pull the plug' on your board, that will leave the existing debug session still running, but 'orphaned'. It continues to try to talk to your board and this explains why it is still running and using processor resources. [Before you ask, we cannot detect that the board has been pulled, as the Windows USB drivers are still returning valid data].

lpcxpresso.exe is the IDE
arm-none-eabi-gdb is the debugger
crt_emu_lpc11_13_nxp.exe is the debug driver - the task that is actually talking to the debug target
starter.exe is the program we use to start the debugger (and any other 'spawned' applications).
csrss.exe and conhost.exe are standard Windows processes and nothing to do with LPCXpresso.
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by jim.smith on Mon Jan 10 08:13:52 MST 2011
If you download code to the evaluation board using the Debug function (small insect icon) the PC software goes into debug mode.  You need to hit the square red STOP button to exit that mode if you want to push new code down to the evaluation board.  Cycling power by removing the USB cable will also exit Debug mode, but hitting a button is a lot easier.
0 Kudos
Reply

1,469 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mfc on Mon Jan 10 07:19:38 MST 2011
Some more info -- possibly related.

After my last post I closed the IDE and went for lunch; on returning, I just noticed that both cores on my PC are running at 73% + .. something I have rarely seen. A quick look at the processes list shows the following are the culprits (in no particular order):

[COLOR=navy]arm-none-eabi-gdb.exe[/COLOR]
[COLOR=navy]crt_emu_lpc11_13_nxp.exe[/COLOR]
[COLOR=navy]lpcxpresso.exe[/COLOR]

along with the more mysterious

[COLOR=navy]starter.exe[/COLOR]
[COLOR=navy]csrss.exe[/COLOR]
[COLOR=navy]conhost.exe[/COLOR]

none of which I normally expect to see in the process list.

Mike
0 Kudos
Reply