update user defines
diff --git a/verilog/rtl/user_defines.v b/verilog/rtl/user_defines.v index e577931..81c0430 100644 --- a/verilog/rtl/user_defines.v +++ b/verilog/rtl/user_defines.v
@@ -1,4 +1,4 @@ -// SPDX-FileCopyrightText: 2020 Efabless Corporation +// SPDX-FileCopyrightText: 2022 Efabless Corporation // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -19,17 +19,22 @@ // User GPIO initial configuration parameters `define __USER_DEFINES_H +// deliberately erroneous placeholder value; user required to config GPIO's to other +`define GPIO_MODE_INVALID 13'hXXXX + +// Authoritive source of these MODE defs is: caravel/verilog/rtl/user_defines.v // Useful GPIO mode values. These match the names used in defs.h. +// `define GPIO_MODE_MGMT_STD_INPUT_NOPULL 13'h0403 -`define GPIO_MODE_MGMT_STD_INPUT_PULLDOWN 13'h0803 -`define GPIO_MODE_MGMT_STD_INPUT_PULLUP 13'h0c03 +`define GPIO_MODE_MGMT_STD_INPUT_PULLDOWN 13'h0c01 +`define GPIO_MODE_MGMT_STD_INPUT_PULLUP 13'h0801 `define GPIO_MODE_MGMT_STD_OUTPUT 13'h1809 `define GPIO_MODE_MGMT_STD_BIDIRECTIONAL 13'h1801 `define GPIO_MODE_MGMT_STD_ANALOG 13'h000b `define GPIO_MODE_USER_STD_INPUT_NOPULL 13'h0402 -`define GPIO_MODE_USER_STD_INPUT_PULLDOWN 13'h0802 -`define GPIO_MODE_USER_STD_INPUT_PULLUP 13'h0c02 +`define GPIO_MODE_USER_STD_INPUT_PULLDOWN 13'h0c00 +`define GPIO_MODE_USER_STD_INPUT_PULLUP 13'h0800 `define GPIO_MODE_USER_STD_OUTPUT 13'h1808 `define GPIO_MODE_USER_STD_BIDIRECTIONAL 13'h1800 `define GPIO_MODE_USER_STD_OUT_MONITORED 13'h1802