summaryrefslogtreecommitdiffhomepage
path: root/src/cont_params.v
diff options
context:
space:
mode:
authorPrivate Island Networks Inc <opensource@privateisland.tech>2025-12-21 20:51:04 -0500
committerPrivate Island Networks Inc <opensource@privateisland.tech>2025-12-21 20:51:04 -0500
commit7b1b5e7eb712d41888398934834cae730e0aa5a0 (patch)
tree8b8aba85e19a079fbbd4962c57ff89ca701c6e4d /src/cont_params.v
parentf4bdc9f4365d3a3ce3f906e68cd018cb57561e56 (diff)
betsy: preliminary beta snapshot
Diffstat (limited to 'src/cont_params.v')
-rw-r--r--src/cont_params.v61
1 files changed, 61 insertions, 0 deletions
diff --git a/src/cont_params.v b/src/cont_params.v
new file mode 100644
index 0000000..cbdddcc
--- /dev/null
+++ b/src/cont_params.v
@@ -0,0 +1,61 @@
+/*
+ * cont_params.v
+ *
+ * Copyright (C) 2024-2025 Private Island Networks Inc.
+ * Copyright (C) 2018-2023 Mind Chasers Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * function: Controller related parameters
+ *
+ */
+
+
+`ifdef INCLUDED
+
+/* Message Protocol:
+ * Type: 8-bit (rx_cnt==4)
+ * Token: 8-bit (rx_cnt==5)
+ * Address: 16-bit (rx_cnt==6,7)
+ * Data: 32-bit (rx_cnt==8,9,10,11)
+ */
+
+localparam MSG_SZ = 8'h8;
+
+// Message Types (16-bit address)
+localparam MSG_TYPE_NULL = 8'h0;
+localparam MSG_TYPE_WRITE = 8'h1;
+localparam MSG_TYPE_READ = 8'h2;
+localparam MSG_TYPE_REPLY_SUCCESS = 8'h3;
+localparam MSG_TYPE_REPLY_ERROR = 8'h4;
+localparam MSG_TYPE_NOTIY = 8'h5;
+
+
+localparam MSG_CONTROLLER_ADDR = 16'h0000;
+localparam MSG_MAC_ADDR = 16'h0100;
+localparam MSG_PKT_FILTER_ADDR = 16'h0200;
+localparam MSG_SWITCH_ADDR = 16'h0500;
+localparam MSG_MDIO_ADDR = 16'h0600;
+localparam MSG_MLE_ADDR = 16'h0700;
+localparam MSG_INVALID_ADDR = 16'h0800;
+
+
+localparam HF_TX_WR_PTR_ADDR = 16'd0;
+localparam HF_TX_RD_PTR_ADDR = 16'd1; // read only
+localparam HF_TX_BYTE_CNT_ADDR = 16'd1; // write only
+localparam HF_RX_WR_PTR_LTCH_ADDR = 16'd2;
+localparam HF_NULL = 16'd3;
+localparam HF_RESET_PTRS = 16'd4;
+
+
+`endif

Highly Recommended Verilog Books