I’m trying to adapt the following fully-functional demo program using the LPC2148 on Keil’s MCB2140 eval board for use with Eclipse/GNUARM IDE with Zylin plug-in.
The demo program is called USBAudio, and is downloadable from www.keil.com. I can build it from the Keil IDE and can serially download it using Philips LPC2000 Flash Utility 2.2.3. No problems. After downloading & cycling power using my PC’s USB connection for power, I get “New hardware found.” My PC recognizes the new hardware as a speaker and magically sets it up as the default audio output. If I play a .wav file, the audio signal gets delivered via USB to the Keil board and is played on the on-board speaker. It is a very impressive demo.
Using Mr. Lynch’s LPC2148 Blinky project as a base, I can at least build the new USBaudio project. The result, however, is “USB device not recognized.” on the PC end when I boot the MCB2140. I have fixed some compile errors, and have dealt with semantic differences along the way as best I could, but am afraid I’m still missing something.
I’m going to need to abandon ship on this pretty soon. I’ve spent many hours on this, to no avail as of yet. I’m thinking of now getting the OCDremote debugger up and running next, and trying to go ahead and try and use it to help solve my original problem. In the meantime, I really have no idea how long it’s going to take, or IF I’ll eventually get there with Eclipse/GNUARM at all, since it is unknown territory. It would be one thing if I could quickly find a working USB demo, already built under the Eclipse environment, but as yet, I have not.
[ The bigger, looming question is this. Is it better for me to continue on the path that I’m on, or should I recommend to my boss that we spring for the full blown Keil JTAG debugger to the tune of $5K, a figure that I’m now rapidly approaching? ]
The top of my menory map looks like :
/* | 0x40008000 */
/* .-------->|--------------------------| */
/* . | variables and stack |0x40007FFF */
/* ram_isp_high | for Philips boot loader */
/* . | 32 + 256 = 288 bytes | */
/* . | | */
/* . | Do not put anything here 0x40007EE0 */
/* .-------->|---------------------------------| */
/* | | 0x40007EDF */
/* | UDF Stack 4 bytes | 0x40007EDC <----_stack_end */
/* .-------->|---------------------------------| */
/* | |0x40007EDB */
/* | ABT Stack 4 bytes |0x40007ED8 */
/* .-------->|---------------------------------| */
/* | |0x40007ED7 */
/* | FIQ Stack 4 bytes |0x40007ED4 */
/* .-------->|---------------------------------| */
/* | |0x40007ED3 */
/* | IRQ Stack 128 bytes |0x40007E54 */
/* .-------->|---------------------------------| */
/* | |0x40007E53 */
/* | SVC Stack 4 bytes |0x40007E50 */
/* .-------->|---------------------------------| */
/* | |0x40007E4F */
/* | USR Stack 1024 bytes |0x40007A50 stack area for user program */
/* .-------->|---------------------------------| */
/* . | |0x40007A4f */
/* . | | */
/* . | |
-
Should _stack_end be set to 0x40007EDC or 0x40007EDF ?
-
If anyone is interested in helping out a fellow down on his luck, I’ll be happy to email you my project in zip file format, if you could give it a glance and try and figure this one out…