We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello!
I've been using Keil IDE for 8051 since years and it always worked fine. Now I need to work with ARM processor. Since I'm new to it, I wanted to start with the examples. I got the MCB2300 board v4.0 with uLink 2 and, of course, the appropriate Keil ARM IDE with RV.
1. In all the documentation it tells about the JTAG jumper to be set for uLink - but there is no JTAG jumper
2. When I open the example project "blinky", the target is set to LPC2378, though the MCB2300 has LPC2368. The abstract.txt says, there is a target called "mcb2300 flash", but it's actually named "lpc2378 flash".
3. In the target settings, it already selected ULINK debugger, which is set to 1MHz speed, though the online step-by-step guide says it should be set to 200kHz
4. Compiling the project works fine, but going to debug reports error "memory mismatch, address: 0x0, value: 0x0, expected: 0x18" - this looks like there was no code. Is it required to create a hex file and if so, why is this not activated in the target options? I thought these are ready-to-run projects.
5. After activating "Create hex file", it still shows the error, but enters debug mode and the disassembly windows shows more than zeros
6. The code is running instantly, at least the JTAG interface says so. But there is no LED bar or character display on the LCD. The little beeper produces low, high frequency noise. Looking into the code (as far as I understand the ARM assembler) tells me, it is not correct. Resetting the target to 0 and going stepwise lets the debugger jump to address 0xfffffff3 after a few steps. So the debugger does not really work. If I let the the code run after reset and stop it, it halts at 0x0000000C, going in a loop to 0x00000014. Not really a working code...
7. Opening example projects with abstract.txt in it gives error "abstract.txt contains a invalid path". Huh? Since when can a text file contain a path?
8. At least, example project EasyWeb compiles and uploads to the MCU. But then it says "Can't stop the ARM device - check JTAG cable". Hilarious! There is a hardware debug tool with a reset line and it can't stop the controller! Even I manually reset the whole board by unplugging the USB cable and inserting it again, the flash uploader gives the same error. Sure, it is possible that the cable is broken, but board and uLink are quite new and the cable has only beed unplugged a several times.
Now I wonder how this can be possible. I mean, it can't be the way to read hundreds of pages and books just to be able to setup Keil! Why must every tiny piece of software have thousands of settings? An ARM controller might be more complex than a 8051, but from the IDE it is still the same. Setup, project, compilation, debug.
This is a hardware/software package that costs some hundred or even some thousand Euros. I simply expect it to work! I mean, what else can occur if not even small example projects work?
(By the way, selecting a different country still shows the american flag on the preview)
The different boards have their examples in different directories.
But when you open a Keil example for a specific board, then the project file contains one build target for running in flash, and one build target for debugging directly in RAM.
There is most definitely input boxes to specify the memory range to use for code and the memory range to use for RAM. Each target in the project file has its own set of all settings.
No, Per, they don't do! There is mostly only one target and in some cases also the simulator as second target. But they are not distinguished by memory type. Also, a target has settings. In the target settings dialogue I can not selected whether the code shall be compiled for RAM or ROM. I can only set the debugger to not use flash (ROM), so it must be using RAM. The input boxes you refer to are to define and tell the compiler what memory areas the specific controller has. I don't think they are used to define the target memory type, because if both, RAM and ROM, are enabled, there must be a priority of one (in this case ROM) and so the compiler should compile the code for ROM. If "Download to flash" is activated, the code should work now. If not, then it would run from RAM and the debugger/flashloader would tell me. This would explain one of the items I told in my first post. But how will I know? These demo apps are actually supposed to work as is.
I'm running a bit older version of the tools - I don't much like upgrading when there is no need.
Seems like you are right - Keil has been a bit lazy.
For MCB2300 board: Blinky,RTX_Blinky,RTX_Traffic seems to have Simulator + Flash
For MCB2100 board: Bliny,BlinkyCAN,BlinkyIRQ has Simulator + Flash + RAM RTX_Blinky: Simulator + Flash
For MCB2400 board: Blinky has Simulator + Flash + Ext SDRAM + Ext NOR Flash
Seems like Keil has been slowing down a bit. I can't see any real reason for the big lack of RAM targets for newer boards. It isn't completely obvious how to set up one, without having an example to look at.
=>If I open the "blinky" demo from that folder with "LPC2378 Flash" target and change the controller type to LPC2368, compile it and want upload it, the flash uploader tells me "Could not load flash programming algorithms" (LPC_2000_IAP2_512.flx). Now you tell me this is all my fault??<=
(I don't know much about all these.)
Hi Maik,
There is one setting to tell KEIL compiler what the MCU you are using. And there is another setting to tell the JTAG Tool what the MCU you are using.
Maybe you can check this:
Options for Target -> Debug and Utilities -> there is a button "Setting". If you haven't done this, click that button, and configure it.
Adding New Algorithms
www.keil.com/.../ulinkme_su_newalgorithms.htm
www.keil.com/.../ulink2_su_newalgorithms.htm
www.keil.com/.../ulink_su_newalgorithms.htm
There is no difference to the flash memory in the LPC2368 and LPC2378, so they should use the same flash algorithm.
Thanks, John. But this is not the problem, since the programming algorithm works with other projects. I was just giving an example.