tinyriscv/rtl/perips/gpio/gpio.hjson

62 lines
1.5 KiB
Plaintext
Raw Normal View History

// Copyright lowRISC contributors.
// Licensed under the Apache License, Version 2.0, see LICENSE for details.
// SPDX-License-Identifier: Apache-2.0
{ name: "gpio",
clocking: [{clock: "clk_i", reset: "rst_ni"}],
bus_interfaces: [
{ protocol: "tlul", direction: "device" }
],
regwidth: "32",
registers: [
{ name: "MODE",
desc: "gpio mode register",
swaccess: "rw",
hwaccess: "hro",
fields: [
{ bits: "15:0",
name: "GPIO",
desc: "gpio input or output mode, 2 bits for each gpio",
}
]
}
{ name: "INTR",
desc: "gpio interrupt register",
swaccess: "rw",
hwaccess: "hrw",
fields: [
{ bits: "15:0",
name: "GPIO_INT",
desc: "gpio interrupt mode, 2 bits for each gpio",
}
{ bits: "23:16",
name: "GPIO_PENDING",
swaccess: "rw1c",
desc: "gpio interrupt pending, 1 bits for each gpio",
}
]
}
{ name: "DATA",
desc: "gpio data register",
swaccess: "rw",
hwaccess: "hrw",
fields: [
{ bits: "7:0",
name: "GPIO",
desc: "gpio input or output data, 1 bits for each gpio",
}
]
}
{ name: "FILTER",
desc: "gpio input filter enable register",
swaccess: "rw",
hwaccess: "hro",
fields: [
{ bits: "7:0",
name: "GPIO",
desc: "gpio input filter enable, 1 bits for each gpio",
}
]
}
]
}