txt wmh 2010-11-12 : instructions for the BlinkyI RQ05 demo (ARM driving P24 resources) Setting up the development software: ==================================== yagarto -- download current version (2010813) of yagarto GNU ARM toolcha in from sourceforge.net/projects/yagarto and install it on your Windows machine. Do _not_ accept the invitation to install it in 'C:\Program Files\' -- there is a warning on the www.yagarto.de site about having spaces in the installation di rectory name. You can let the install program update Window's path variables w hen it requests --OR-- you can edit '_BlinkyIRQ05make.bat', the batch file for b uilding the example program, and in it the path to wherever you have installed y agarto. You'll have to edit the batch file anyway, as I've set the path in it t o my 'C:\_software_installs' directory, which you will want to change. You can a lso download and install 'YAGARTO Tools' from www.yagarto.de -- if you do, pleas e tell me what they are good for (I haven't used them). Keil -- go to https://www.keil.com/demo/eval/arm.htm and register, then download the free Keil uVision4 ARM development software (the version I got a fe w days ago is mdk413a.exe ) and install it. FlashMagic -- you will have to install the FlashMagic tool from http://w ww.flashmagictool.com in order to download ARM programs to the LPC2300 board. P24CDC_12.hex -- the included file 'P24CDC_12.hex' must be installed on the P24. It will provide the USB connection between your PC and the ARM board's serial port which FlashMagic uses to program the ARM chip. BlinkyIRQ05 demo -- extract the attached BlinkyIRQ05.zip somewhere, prob ably not on your desktop -- we want it in a directory on C:\ which doesn't have any spaces in its name, and isn't too long. Edit '_BlinkyIRQ05make.bat' as nece ssary to get the path to your yagarto tools set to where the yagarto \bin direct ory resides, then run the batch file from Windows Explorer or the DOS prompt. If all goes well you'll get a bunch of messages, but none of them will say 'error' , and you will be ready for the next step, which is: click on BlinkyIRQ05.Uv2 in the demo directory, and uVision4 should start up with the Blinky05 project load ed. When it does, go to to {Menu bar} Debug > Start/Stop Debug Session and have fun! What is BlinkyIRQ05? ==================== BlinkyIRQ05 is a demo program written (mostly) in ARM assembly language to run on the NXP2368 ARM processor on the cuteDigi LPC2300 board. BlinkyIRQ05 s ets up the ARM processor's timer0, interrupt controller, and I/O ports, then tra nsfers to main(), which writes various patterns to the ARM's output ports. A int errupt triggered by timer0 runs concurrently and reads several port bits, then r eports the result to main(). When the P24 and the ARM board are connected, with BlinkyIRQ05.hex runni ng on the ARM board and P24CDC_12.hex running on the P24, you have a complete de monstration of the ARM processor in control of the P24's lights and switches. I n BlinkyIRQ05 the ARM outputs to the P24's anode-drivers with the data sequence '11111110', '11111101', ... , '01111111', while also outputting the same data se quence '11111110', '11111101', ... , '01111111' to the P24's cathode-drivers, re sulting in a turning on a single illuminated segment which traverses all of the P24's LEDs. Meanwhile the ARM's timer0 interrupt is periodically sampling the P

This is the P24 signal SW_COL2 which carries switch closure information back to the PIC processor's port pin RA3. To help you identify pin physical locations for installing the jumpers. Thi s signal can also be accessed on the header H_PIC at pin 10. Pin 1 on H_PIC is marked with a black dot (not as ni ce as the numbers on P4). TAfter that. Setting up the hardware: ======================== You don't need to have the P24/ARM hardware to be set up to get started on learning how to program and debug on the ARM. The switch status is also reported via a global variable to main( ). pin 2 in the upper right. bit 7.hex . Please _don't_ remember how the DIP IC packages that you used in ENEE206 are numbered (e. In fact I recommend that you ge t the yagarto and Keil development tools installed. then releasi ng S2. differently). and the remaining odd and even numbered pins on opposi te sides all the way down. Notice how they follow the usual header-pin counting convention. and step through it with the Keil debugger while observing activities in the (simulated) ports before you set up the hardware testbed. no number is available) pin on H_NOREG. P24-ARM jumper connections -. Next. put the ARM board in ISP (serial loader) mode by holding down swit ch S2 ('ISP') on LPC2300 board while pressing/releasing S1 ('RST'). look at lower left corner of t he table in P24-LPC2300_connections01.pdf'.pd f' gives a table for the jumper connections between the P24 and LPC2300 boards. Now look at the included 'P 24v02r13_illustration. Now start FlashMagic and: 1.0 Mhz read the manual for more info 2. We have it connect ed by jumper to the ARM's P4 header at pin 24. while on the ARM board its connected to the center pin of P6. as a misconnection may have an unk nown effect. build the 'BlinkyIRQ05' test program. look at the included 'cutedigi_(Colorado) $35_lpc2368mini090831.sch.24's SW1-Sw4 and displaying which switches are pressed by lighting the ARM board LEDs DS1-DS5. This is a job you should take your time with.the included 'P24-LPC2300_connections01. select device set device = LPC2368 select COM port (check windows device manager for COM po rt# for 'Microchip CDC RS-232 Emulation Demo' set baud rate as 9600 (probably doesnt matter) set interface = 'None (ISP)' set oscillator = 12. therefore. so all of the odd-numbered pins are on the top row of H_PIC. The only jumper connection not involving H_PIC or P4 is for the power su pply jumper from the P24 to the ARM board -. which turns on LED DS6 to report that it sees the switch information. select blocks to erase check 'Erase blocks used by hex file' 3.on the P24 this is connected to the left (sorry. with pin 1 in the upper left.g.pdf'. the ARM processor will be able to monitor the state of SW_COL2 on the P24 board by testing its (the AR M's) input at port 0. which shows how the pins on the ARM board's P4 connector are arranged. select file to download Browse to and select BlinkyIRQ05.pdf. l ook at information below and connect and test your boards. and the even-numbered pins are on the bottom row. To help you identify which pin does what.

Solution is to put the ARM board into programming mod e first -. A: The problem is that some ARM board outputs are conflicting with some P24 outputs during the P24's programming-selection phase (when you reset the P24 while holding down SW1). press/release S1. press/release the reset switch S1 on the ARM board.4. Options Check 'verify' 5. FAQ: Q: I loaded the BlinkIRQ05 demo on the ARM board. and you are quite likel y to see smoke. then watch LEDs march around on the P24. 'Start' Watch the counter on the bottom left. watch LEDs on the ARM board turn on. Q: How can I fry my ARM board? A: One possibility to try: with all of the jumpers betweem the boards co nnected and the boards powered up.hold down S2 on the ARM. . which I don't want to do. To test the program. You can l eave the ARM in programming mode indefinitely while doing development on the P24 alone. This will let the PIC drive the ARM's inputs at voltages well above the LPC2 368 data sheet's permissible absolute maximums over Vss. think positive tho ughts. and now I can't get my P24 into programming mode unless I disconnect all of the jumpers. then release S2. Press SW1-SW4 on the P24 in any combi nation. disconnect the power supply jumper between th em.

Master your semester with Scribd & The New York Times

Special offer for students: Only $4.99/month.

Master your semester with Scribd & The New York Times

Cancel anytime.