This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: using the Macraigor Wiggler w/MPC8260


It has been a long time since I looked at the Wiggler, but here is what I remember, ...

When you install the Wiggler software for the Voyager MPC8260 board (VADS), you get a script to initialize the board. I think that the script is in the Program Files\Macraigor directory, but I don't have it installed anymore, so I can't be sure.

I have attached two scripts, one that I used for the VADS board (I may have modified this one for the original) and one I used to initialize our custom MPC8260 board.

The scripts should set up enough of the registers (IMMR, MMU stuff, chip selects) so that you can download software to RAM (and Flash). Of course, you may need to customize the script to work with your board.

Good Luck,
--Paul

Rajesh Gottlieb wrote:

I just ordered a Macraigor Wiggler to help me port eCos/redboot to a custom
MPC8260 board. Can anyone give me some tips on how to set it up and use it with
gdb and cygwin? I take it there must be some sort of initialization needed to
set up the IMMR register and the chip select registers before I can load
anything into RAM. I'd appreciate any example config files for this. Has anyone
had any luck using the wiggler on the MPC82xx processors?

Thanks
Rajesh

__________________________________
Do you Yahoo!?
Yahoo! Mail - More reliable, more storage, less spam
http://mail.yahoo.com



#
# SingleStep hp82xx to Motorola MPC8260VADS Voyager config
#
#       version 2 (01/18/99)
#

reset
#*************************************************************
#  program the SYPCR - disable the watchdog timer
#*************************************************************
word 0x0f010004 = 0xffffffc3

#*************************************************************
#  program the MSR to clear IP and set ME and RI
#*************************************************************
# MSR = 0x1002
spr 2146t = 0x1002
# SRR1 = 0x1002
spr 27t = 0x1002

#*************************************************************
#  turn off unwanted modes
#*************************************************************
# HID0 = 0
spr 1008t = 0

#*************************************************************
#  load IMMR register with the new base address (0x04700000)
#  Warning: this assumes that the IMMR is located at 0xf0101A8
#  due to the reset configuration.  If the reset config words
#  in boot Flash/ROM are set for a different address, then you
#  must update this script to use the new IMMR address! 
#*************************************************************
word 0x0f0101A8 = 0x04700000

#*************************************************************
#  program the SCCR - disable low-power mode & set clock divider to 8
#*************************************************************
word 0x04710c80 = 0x1

#*************************************************************
#  program the BCR - single Voyager mode 
#*************************************************************
word 0x04710024 = 0x100c0000

#*************************************************************
#  initialize the memory controller registers...
#*************************************************************

#*************************************************************
#  initialize bank 0 - Flash (write BR before OR for bank 0)
#*************************************************************
word 0x04710100 = 0xfe001801 
word 0x04710104 = 0xfe000836 

#*************************************************************
#  initialize bank 1 - bcsr  (write OR before BR for all others)
#*************************************************************
word 0x0471010c = 0xffff8010  
word 0x04710108 = 0x04501801

#*************************************************************
#  program PSRT - SDRAM refresh timer 
#*************************************************************
byte 0x0471019c = 0x1c

#*************************************************************
#  program bank 2 registers 
#*************************************************************
word 0x04710114 = 0xff000ca0  
word 0x04710110 = 0x00000041  

#*************************************************************
#  setup the PSDMR 
#*************************************************************
word 0x04710190 = 0x41

#*************************************************************
#  program the PSDMR to change the SDRAM op to precharge...
#  do a write to 0 to complete op change
#*************************************************************
word 0x04710190 = 0x296EA42A
word 0x0 = 0xff

#*************************************************************
#  program the PSDMR to change the SDRAM op to CBR refresh 
#  do a write to 0 8 times to complete op change
#*************************************************************
word 0x04710190 = 0x096EA42A
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff

#*************************************************************
#  program the PSDMR to change the SDRAM op to mode register
#  write. (do the BL and CL bit programming) and do a write to
#  0.
#*************************************************************
word 0x04710190 = 0x196EA42A
word 0x0 = 0xff

#*************************************************************
#  program PSDMR one more time to turn on refresh and change
#  op to normal operation 
#*************************************************************
word 0x04710190 = 0x418eb452
word 0 100

spr 1008 = 0x10000
spr 1008
#
# SingleStep hp82xx to Motorola MPC8260VADS Voyager config
# Modified to work with the MPC8260 processor on the TS6 board
#
#       version 2 (01/18/99)
#

reset
#*************************************************************
#  program the SYPCR - disable the watchdog timer
#*************************************************************
word 0x0f010004 = 0xffffffc3

#*************************************************************
#  program the MSR to clear IP and set ME and RI
#*************************************************************
# MSR = 0x1002
spr 2146t = 0x1002
# SRR1 = 0x1002
spr 27t = 0x1002

#*************************************************************
#  turn off unwanted modes
#*************************************************************
# HID0 = 0
spr 1008t = 0

#*************************************************************
#  load IMMR register with the new base address (0x04700000)
#  Warning: this assumes that the IMMR is located at 0xf0101A8
#  due to the reset configuration.  If the reset config words
#  in boot Flash/ROM are set for a different address, then you
#  must update this script to use the new IMMR address! 
#*************************************************************
word 0x0f0101A8 = 0x04700000

#*************************************************************
#  program the SCCR - disable low-power mode & set clock divider to 8
#*************************************************************
word 0x04710c80 = 0x1

#*************************************************************
#  program the BCR - single Voyager mode 
#*************************************************************
#word 0x04710024 = 0x104c0000
# Set BCR[EAV] This should have no effect, ... its a debugging thing.
word 0x04710024 = 0x104c0000

word 0x04710000 = 0x0E300000
#*************************************************************
#  initialize the memory controller registers...
#*************************************************************

#*************************************************************
#  initialize bank 0 - Flash (write BR before OR for bank 0)
#*************************************************************
word 0x04710100 = 0xff801801 
#word 0x04710104 = 0xfe000836 
word 0x04710104 = 0xff800836 

#*************************************************************
#  initialize bank 4 - fpga  (write OR before BR for all others)
#*************************************************************
word 0x04710124 = 0xffff0E0E  
#word 0x04710120 = 0x0f001801
# Move to 0x04500000
word 0x04710120 = 0x04501801

#*************************************************************
#  initialize bank 8 - cluster bus  (write OR before BR for all others)
#*************************************************************
word 0x04710144 = 0xf0000E0E  
word 0x04710140 = 0xE0000001


#*************************************************************
#  program PSRT - SDRAM refresh timer 
#*************************************************************
byte 0x0471019c = 0x1c

#*************************************************************
#  program bank 5 registers 
#*************************************************************
#word 0x0471012c = 0xfc0028F0
# Try Page-based mode
word 0x0471012c = 0xfc002CF0  // For 64 MByte DIMM
word 0x04710128 = 0x00000041  

#*************************************************************
#  setup the PSDMR 
#*************************************************************
word 0x04710190 = 0x41

#*************************************************************
#  program the PSDMR to change the SDRAM op to precharge...
#  do a write to 0 to complete op change
#*************************************************************
#word 0x04710190 = 0x296EA42A
#word 0x04710190 = 0x294EB452
word 0x04710190 = 0xAB2EB452
word 0x0 = 0xff

#*************************************************************
#  program the PSDMR to change the SDRAM op to CBR refresh 
#  do a write to 0 8 times to complete op change
#*************************************************************
#word 0x04710190 = 0x096EA42A
#word 0x04710190 = 0x094EB452
word 0x04710190 = 0x8B2EB452
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff
word 0x0 = 0xff

#*************************************************************
#  program the PSDMR to change the SDRAM op to mode register
#  write. (do the BL and CL bit programming) and do a write to
#  0.
#*************************************************************
#word 0x04710190 = 0x196EA42A
#word 0x04710190 = 0x194EB452
word 0x04710190 = 0x9B2EB452
word 0x0 = 0xff

#*************************************************************
#  program PSDMR one more time to turn on refresh and change
#  op to normal operation 
#*************************************************************
#word 0x04710190 = 0x414EB452
word 0x04710190 = 0xC32EB452
word 0 100

#*************************************************************
#  program HID0 register NHR bit to indicate that the processor
#  has been through a hard reset
#*************************************************************
spr 1008 = 0x10000
spr 1008


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]