mirror of
https://github.com/aolofsson/oh.git
synced 2025-01-30 02:32:53 +08:00
IOBUF name changes
-Separating pullup and pulldown signals -Changing direction of in/out names to avoid confusion -direction is now with reference to the core
This commit is contained in:
parent
c215b48a55
commit
58aabca0aa
@ -13,14 +13,15 @@ module oh_iobuf #(parameter N = 1, // BUS WIDTH
|
|||||||
inout vddio,// io supply
|
inout vddio,// io supply
|
||||||
inout vss, // ground
|
inout vss, // ground
|
||||||
//CONTROLS
|
//CONTROLS
|
||||||
input [1:0] pullsel, //pullup/pulldown select
|
input enpullup, //enable pullup
|
||||||
|
input enpulldown, //enable pulldown
|
||||||
input slewlimit, //slew limiter
|
input slewlimit, //slew limiter
|
||||||
input [3:0] drivestrength, //drive strength
|
input [3:0] drivestrength, //drive strength
|
||||||
//DATA
|
//DATA
|
||||||
input [N-1:0] ie, //input enable
|
input [N-1:0] ie, //input enable
|
||||||
input [N-1:0] oe, //output enable
|
input [N-1:0] oe, //output enable
|
||||||
input [N-1:0] out,//output TO pad
|
output [N-1:0] out,//output to core
|
||||||
output [N-1:0] in, //input FROM pad
|
input [N-1:0] in, //input from core
|
||||||
//BIDIRECTIONAL PAD
|
//BIDIRECTIONAL PAD
|
||||||
inout [N-1:0] pad
|
inout [N-1:0] pad
|
||||||
);
|
);
|
||||||
@ -30,8 +31,8 @@ module oh_iobuf #(parameter N = 1, // BUS WIDTH
|
|||||||
//TODO: Model power signals
|
//TODO: Model power signals
|
||||||
for (i = 0; i < N; i = i + 1) begin : gen_buf
|
for (i = 0; i < N; i = i + 1) begin : gen_buf
|
||||||
if(TYPE=="BEHAVIORAL") begin : gen_beh
|
if(TYPE=="BEHAVIORAL") begin : gen_beh
|
||||||
assign pad[i] = oe[i] ? out[i] : 1'bZ;
|
assign pad[i] = oe[i] ? in[i] : 1'bZ;
|
||||||
assign in[i] = ie[i] ? pad[i] : 1'b0;
|
assign out[i] = ie[i] ? pad[i] : 1'b0;
|
||||||
end
|
end
|
||||||
else begin : gen_custom
|
else begin : gen_custom
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user