O.Of_signal
include Comb with type comb = Hardcaml.Signal.t
type comb = Hardcaml.Signal.t
val sexp_of_t : t -> Sexplib0.Sexp.t
Raise if the widths of t
do not match those specified in the interface.
val priority_select :
( ( comb, comb t ) Hardcaml.Comb.with_valid2 Base.list ->
( comb, comb t ) Hardcaml.Comb.with_valid2 )
Hardcaml.Comb.optional_branching_factor
val priority_select_with_default :
( ( comb, comb t ) Hardcaml.Comb.with_valid2 Base.list ->
default:comb t ->
comb t )
Hardcaml.Comb.optional_branching_factor
val onehot_select :
( ( comb, comb t ) Hardcaml.Comb.with_valid2 Base.list ->
comb t )
Hardcaml.Comb.optional_branching_factor
consts c
sets each field to the integer value in c
using the declared field bit width.
Create a wire for each field. If named
is true then wires are given the RTL field name. If from
is provided the wire is attached to each given field in from
.
val reg : ?enable:Hardcaml.Signal.t -> Hardcaml.Reg_spec.t -> t -> t
Defines a register over values in this interface. enable
defaults to vdd.
val pipeline :
?attributes:Hardcaml.Rtl_attribute.t Base.list ->
?enable:Hardcaml.Signal.t ->
n:Base.int ->
Hardcaml.Reg_spec.t ->
t ->
t
Defines a register pipeline over values in this interface. enable
defaults to vdd and attributes
defaults to an empty list.
val inputs : Base.unit -> t
inputs t
is wires () ~named:true
.
val apply_names :
?prefix:Base.string ->
?suffix:Base.string ->
?naming_op:( Hardcaml.Signal.t -> Base.string -> Hardcaml.Signal.t ) ->
t ->
t
Apply name to field of the interface. Add prefix
and suffix
if specified.
val validate : t -> Base.unit
Checks the port widths of the signals in the interface. Raises if they mismatch.