Skip to content

Commit 84ce5af

Browse files
committed
wip
Signed-off-by: Douglas Reis <doreis@lowrisc.org>
1 parent c823e7e commit 84ce5af

22 files changed

Lines changed: 705 additions & 474 deletions

File tree

data/sonata_udp.rdl

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
/* Copyright lowRISC contributors.
2+
* Licensed under the Apache License, Version 2.0; see LICENSE for details.
3+
* SPDX-License-Identifier: Apache-2.0
4+
*/
5+
6+
/* Indicates what the signal is used for.
7+
*/
8+
enum SigType {
9+
None;
10+
PadInOut; // Signal is a pad for In and Out. i.e: i2c.sda.
11+
PadInput; // Signal is a pad for Input. i.e: uart.rx
12+
PadOutput; // Signal is a pad for Output. i.e: uart.tx
13+
Interrupt;// Signal is an Interrupt
14+
};
15+
16+
/* Indicates what the signal will be used for.
17+
*/
18+
property sigtype {
19+
type = SigType;
20+
component = signal;
21+
default = SigType::None;
22+
};
23+
24+
enum IoCombine {
25+
None;
26+
Mux;
27+
And;
28+
Or;
29+
};
30+
31+
/*
32+
*/
33+
property io_combine {
34+
type = IoCombine;
35+
component = signal;
36+
default = IoCombine::None;
37+
};
38+
39+
struct parameter {
40+
string type_;
41+
string name;
42+
string value;
43+
};
44+
45+
property xbar {
46+
type = parameter[];
47+
component = addrmap|mem;
48+
default = '{};
49+
};
50+

data/top.rdl

Lines changed: 51 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
`include "udp.rdl"
2+
`include "sonata_udp.rdl"
23
`include "../rtl/ip/system_info/data/system_info.rdl"
34
`include "../rtl/ip/spi/data/spi.rdl"
45
`include "../rtl/ip/rgbled_ctrl/data/rgbled_ctrl.rdl"
@@ -7,28 +8,67 @@
78
`include "../rtl/ip/usbdev/data/usbdev.rdl"
89
`include "../rtl/ip/i2c/data/i2c.rdl"
910
`include "../rtl/ip/uart/data/uart.rdl"
10-
`include "../rtl/system/autogen/rv_plic/data/rv_plic.rdl"
11+
`include "../rtl/ip/xadc/data/xadc.rdl"
12+
`include "../rtl/ip/rev_ctl/data/rev_ctl.rdl"
13+
`include "../rtl/system/data/rv_plic.rdl"
14+
`include "../rtl/system/data/pinmux.rdl"
15+
`include "../rtl/system/data/rv_timer.rdl"
1116

1217
addrmap top_sonata {
13-
external mem sram { memwidth = 0x20000; } SRAM @ 0x00100000;
14-
external mem hyperram { memwidth = 0x100000; } HYPERRAM @ 0x40000000;
15-
external mem rev_tag { memwidth = 0x800; } REV_TAG @ 0x30000000;
18+
external mem sram {
19+
mementries = 0x20000; memwidth=8;
20+
clk_input = '{ "clk_sys_i" };
21+
rst_input = '{ "rst_sys_ni" };
22+
} SRAM @ 0x00100000;
23+
24+
external mem hyperram {
25+
mementries = 0x100000; memwidth=8;
26+
clk_input = '{ "clk_sys_i" };
27+
rst_input = '{ "rst_sys_ni" };
28+
} HYPERRAM @ 0x40000000;
29+
30+
external mem rev_tag {
31+
mementries = 0x800; memwidth=8;
32+
clk_input = '{ "clk_sys_i" };
33+
rst_input = '{ "rst_sys_ni" };
34+
} REV_TAG @ 0x30000000;
35+
1636
gpio GPIO @ 0x80000000;
17-
gpio GPIO_RPI @ 0x80000040;
18-
gpio GPIO_ARDUINO @ 0x80000080;
19-
gpio GPIO_PMOD[2] @ 0x800000C0 += 0x40;
20-
gpio GPIO_PMODC @ 0x80000140;
21-
pwm PWM[6] @ 0x80001000 += 0x08;
22-
pwm PWM_LCD;
37+
38+
pwm PWM @ 0x80001000;
39+
40+
pinmux PINMUX @ 0x80005000;
41+
2342
rgbled_ctrl RGBLED_CTRL @ 0x80009000;
43+
44+
rev_ctl HW_REV @ 0x8000A000;
45+
46+
xadc XADC @ 0x8000B000;
47+
2448
system_info SYSTEM_INFO @ 0x8000C000;
49+
50+
rv_timer TIMER @ 0x80040000;
51+
2552
uart uart[3] @ 0x80100000 += 0x1000;
53+
2654
i2c I2C[2] @ 0x80200000 += 0x1000;
55+
2756
spi SPI_LCD @ 0x80300000;
57+
2858
spi SPI_ETHMAC @ 0x80301000;
59+
2960
spi SPI[3] @ 0x80302000 += 0x1000;
61+
3062
usbdev USBDEV @ 0x80400000;
63+
64+
// This block is overaligned to 0x0800_0000 bytes since OpenTitan RV_PLIC block expects it.
3165
rv_plic RV_PLIC @ 0x88000000;
32-
external mem dgb_dev { memwidth = 0x1000; } DBG_DEV @ 0xB0000000;
66+
67+
external mem dgb_dev {
68+
mementries = 0x1000; memwidth=8;
69+
xbar = '{ parameter'{ type_: "bool", name: "pipeline", value: "true" }};
70+
clk_input = '{ "clk_sys_i" };
71+
rst_input = '{ "rst_sys_ni" };
72+
} DBG_DEV @ 0xB0000000;
3373
};
3474

0 commit comments

Comments
 (0)