forked from firebee-org/BaS_gcc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmcf5474.gdb
71 lines (56 loc) · 1.48 KB
/
mcf5474.gdb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#
# GDB Init script for the Coldfire 5474 processor (firebee).
#
define addresses
set $vbr = 0x00000000
#monitor bdm-ctl-set 0x0801 0x00000000
set $mbar = 0xFF000000
#monitor bdm-ctl-set 0x0C0F 0xFF000000
set $rambar0 = 0xFF100000
#monitor bdm-ctl-set 0x0C04 0xFF100007
set $rambar1 = 0xFF101000
#monitor bdm-ctl-set 0x0C05 0xFF101001
end
#
# Setup the DRAM controller.
#
define setup-dram
# Init CS0 (BootFLASH @ E000_0000 - E07F_FFFF 8Mbytes)
set *((long *) 0xFF000500) = 0xE0000000
set *((long *) 0xFF000508) = 0x00041180
set *((long *) 0xFF000504) = 0x007F0001
# set *((long *) 0xFF00050C) = 0xFFF00000 # ATARI I/O address
# SDRAM Initialization @ 0000_0000 - 1FFF_FFFF 512Mbytes
set *((long *) 0xFF000004) = 0x000002AA
set *((long *) 0xFF000020) = 0x0000001A
set *((long *) 0xFF000024) = 0x0800001A
set *((long *) 0xFF000028) = 0x1000001A
set *((long *) 0xFF00002C) = 0x1800001A
set *((long *) 0xFF000108) = 0x73622830
set *((long *) 0xFF00010C) = 0x46770000
set *((long *) 0xFF000104) = 0xE10D0002
set *((long *) 0xFF000100) = 0x40010000
set *((long *) 0xFF000100) = 0x048D0000
set *((long *) 0xFF000104) = 0xE10D0002
set *((long *) 0xFF000104) = 0xE10D0004
set *((long *) 0xFF000104) = 0xE10D0004
set *((long *) 0xFF000100) = 0x008D0000
set *((long *) 0xFF000104) = 0x710D0F00
end
define cu
!killall m68k-bdm-gdbserver
end
#
# Wake up the board
#
define ib
addresses
setup-dram
end
define run
continue
end
tr
ib
#add-symbol-file ../emutos/emutos2.img 0xe00000
#load firebee/ram.elf