Modified Type Size convention
The RTPS Payload size overhead was defined in the rtps_package, and is to be used by all type packages to calculate the MAX_<TYPENAME>_SIZE. The service overhead size was also renamed to ROS_SERVICE_OVERHEAD_BYTES to make the connection with ROS clearer.
This commit is contained in:
parent
5f7f2685c2
commit
f0cc29fcd6
@ -29,16 +29,16 @@ package user_config is
|
||||
constant NUM_ENDPOINTS : natural := NUM_READERS+NUM_WRITERS;
|
||||
-- PB Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PB : natural := 7400;
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_DG : natural := 250;
|
||||
-- PG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
-- D0 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
-- D1 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D1 : natural := 10;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D3 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D3 : natural := 11;
|
||||
-- MAC Address of underlying network stack (Used to generate GUIDs)
|
||||
@ -89,7 +89,7 @@ package body user_config is
|
||||
c.RELIABILITY_QOS := RELIABLE_RELIABILITY_QOS;
|
||||
c.MAX_SAMPLES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_INSTANCES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE + 4; -- (+ PAYLOAD HEADER)
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE;
|
||||
|
||||
ret := (others => c);
|
||||
|
||||
|
||||
@ -29,16 +29,16 @@ package user_config is
|
||||
constant NUM_ENDPOINTS : natural := NUM_READERS+NUM_WRITERS;
|
||||
-- PB Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PB : natural := 7400;
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_DG : natural := 250;
|
||||
-- PG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
-- D0 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
-- D1 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D1 : natural := 10;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D3 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D3 : natural := 11;
|
||||
-- MAC Address of underlying network stack (Used to generate GUIDs)
|
||||
@ -89,7 +89,7 @@ package body user_config is
|
||||
c.RELIABILITY_QOS := RELIABLE_RELIABILITY_QOS;
|
||||
c.MAX_SAMPLES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_INSTANCES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE + 4; -- (+ PAYLOAD HEADER)
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE;
|
||||
|
||||
ret := (others => c);
|
||||
|
||||
|
||||
@ -24,21 +24,21 @@ package user_config is
|
||||
-- Number of RTPS Writer Endpoints
|
||||
constant NUM_WRITERS : natural := 1;
|
||||
-- Number of RTPS Reader Endpoints
|
||||
constant NUM_READERS : natural := 1;
|
||||
constant NUM_READERS : natural := 1;
|
||||
-- Number of RTPS Endpoints (Do not modify)
|
||||
constant NUM_ENDPOINTS : natural := NUM_READERS+NUM_WRITERS;
|
||||
-- PB Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PB : natural := 7400;
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_DG : natural := 250;
|
||||
-- PG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
-- D0 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
-- D1 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D1 : natural := 10;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D3 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D3 : natural := 11;
|
||||
-- MAC Address of underlying network stack (Used to generate GUIDs)
|
||||
@ -90,7 +90,7 @@ package body user_config is
|
||||
c.HISTORY_DEPTH := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_SAMPLES := std_logic_vector(to_unsigned(20, CDR_LONG_WIDTH));
|
||||
c.MAX_INSTANCES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE + 4; -- (+ PAYLOAD HEADER)
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE;
|
||||
|
||||
ret := (others => c);
|
||||
|
||||
|
||||
@ -24,21 +24,21 @@ package user_config is
|
||||
-- Number of RTPS Writer Endpoints
|
||||
constant NUM_WRITERS : natural := 1;
|
||||
-- Number of RTPS Reader Endpoints
|
||||
constant NUM_READERS : natural := 1;
|
||||
constant NUM_READERS : natural := 1;
|
||||
-- Number of RTPS Endpoints (Do not modify)
|
||||
constant NUM_ENDPOINTS : natural := NUM_READERS+NUM_WRITERS;
|
||||
-- PB Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PB : natural := 7400;
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
-- DG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_DG : natural := 250;
|
||||
-- PG Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
constant PORT_CONFIG_PG : natural := 2;
|
||||
-- D0 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
constant PORT_CONFIG_D0 : natural := 0;
|
||||
-- D1 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D1 : natural := 10;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D2 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D2 : natural := 1;
|
||||
-- D3 Value of Default Port Generation (see DDSI-RTPS 2.3 Section 9.6.1)
|
||||
constant PORT_CONFIG_D3 : natural := 11;
|
||||
-- MAC Address of underlying network stack (Used to generate GUIDs)
|
||||
@ -90,7 +90,7 @@ package body user_config is
|
||||
c.HISTORY_DEPTH := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_SAMPLES := std_logic_vector(to_unsigned(20, CDR_LONG_WIDTH));
|
||||
c.MAX_INSTANCES := std_logic_vector(to_unsigned(5, CDR_LONG_WIDTH));
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE + 4; -- (+ PAYLOAD HEADER)
|
||||
c.MAX_PAYLOAD_SIZE := MAX_TYPE1_SIZE;
|
||||
|
||||
ret := (others => c);
|
||||
|
||||
|
||||
@ -7,12 +7,9 @@ use work.rtps_package.all;
|
||||
|
||||
package Type1_package is
|
||||
|
||||
|
||||
|
||||
constant MAX_ID_SIZE : natural := 4;
|
||||
constant MAX_A_SIZE : natural := 4; -- 8
|
||||
constant MAX_TYPE1_SIZE : natural := 8;
|
||||
|
||||
constant MAX_TYPE1_KEY_HOLDER_SIZE : natural := 4;
|
||||
constant MAX_TYPE1_SIZE : natural := 8 + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -45,8 +45,7 @@ package Type2_package is
|
||||
constant MAX_TESTUNION_SIZE : natural := 7; -- 180
|
||||
constant MAX_TESTBITMASK_SIZE : natural := 4; -- 184
|
||||
constant MAX_TESTSTRING_SIZE : natural := 17; -- 201
|
||||
constant MAX_TYPE2_SIZE : natural := 201;
|
||||
|
||||
constant MAX_TYPE2_KEY_HOLDER_SIZE : natural := 28;
|
||||
constant MAX_TYPE2_SIZE : natural := 201 + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -6,7 +6,7 @@ GENERAL
|
||||
|
||||
The wrapper Entities that define and implement the ROS Publisher and Subscriber - named <MESSAGENAME>_ros_pub
|
||||
and <MESSAGENAME>_ros_sub - are basically carbon copies of a normal <TYPENAME>_reader_interface and
|
||||
<TYPENAME>_writer_interface, with the exception of hiding all the user facing DDS signals and being
|
||||
<TYPENAME>_writer_interface, with the exception of hiding all the user facing DDS signals and being
|
||||
responsible for interacting with the DDS entity directly.
|
||||
All these changes are static for all ROS messages, and the actual message dependent VHDL generation is the
|
||||
same, as the RTPS IDL interface generation.
|
||||
@ -21,20 +21,20 @@ The Service VHDL generation closely follows the general RTPS IDL interface gener
|
||||
For each Service (i.e. .srv File) two files are generated, a server (called <SERVICENAME>_ros_srv_server)
|
||||
and a client (called <SERVICENAME>_ros_srv_client) file.
|
||||
Each file contains both encoding and decoding functionality (similar to the key_holder entities).
|
||||
The files also contain extra logic that may be necessary to parse the SERVICE_OVERHEAD_BYTES that may be
|
||||
The files also contain extra logic that may be necessary to parse the ROS_SERVICE_OVERHEAD_BYTES that may be
|
||||
present in the payload.
|
||||
The code generation follows the normal code generation for encoding and decoding with following changes:
|
||||
|
||||
* Encoding and Decoding stages get a "RQ_" or "RR_" prefixed to the <NAME> to differentiate between
|
||||
Request and Response message members, respectively.
|
||||
e.g. GET_A -> GET_RQ_A, WRITE_SUM -> WRITE_RR_SUM
|
||||
* Similar to the previous point, the <SERVICENAME>_package differentiates the MAX_* sizes of the Request
|
||||
* Similar to the previous point, the <SERVICENAME>_package differentiates the MAX_* sizes of the Request
|
||||
and Response message members.
|
||||
e.g. MAX_A_SIZE -> MAX_RQ_A_SIZE, MAX_SUM_SIZE -> MAX_RR_SUM_SIZE
|
||||
* The <SERVICENAME>_package calculates both a maximum request and response message size, named
|
||||
* The <SERVICENAME>_package calculates both a maximum request and response message size, named
|
||||
MAX_<SERVICENAME>_RQ_SIZE and MAX_<SERVICENAME>_RR_SIZE, respectively.
|
||||
The maximum includes the service overhead bytes that are contained in the DDS Payloads. The constant
|
||||
SERVICE_OVERHEAD_BYTES from ros_package gives this overhead bytes.
|
||||
The maximum includes the service overhead bytes that are contained in the DDS Payloads. The constant
|
||||
ROS_SERVICE_OVERHEAD_BYTES from ros_package gives this overhead bytes.
|
||||
|
||||
|
||||
ACTION
|
||||
@ -73,35 +73,35 @@ In the IDLE stage, similar to the normal code generation, the memory signals are
|
||||
user facing port signals, allowing the user to write the RESULT. The 'result_addr' signal is used to index
|
||||
the (outer) memories.
|
||||
If r_sel is '1', the FETCH_RESULT stage is entered, which is responsible for fetching the correct RESULT.
|
||||
The FETCH_RESULT stage is split into 2 sub-stages, a GET and a READ sub-stage. The GET sub-stage is waiting
|
||||
The FETCH_RESULT stage is split into 2 sub-stages, a GET and a READ sub-stage. The GET sub-stage is waiting
|
||||
for all memories to be ready (ANDing the ready_in signals) before toggling the valid_in signal to initiate
|
||||
the memory read operation and proceeding to the next sub-stage. The READ sub-stage is waiting for all
|
||||
memory read operations to finish (ANDing the valid_out signals) before proceeding to the next stage.
|
||||
If the RESULT contains collections, they have to be manually pushed to the
|
||||
If the RESULT contains collections, they have to be manually pushed to the
|
||||
<ACTIONNAME>_ros_action_result_srv_server. In that case the next stage is a stage called PUSH_<COLLECTIONNAME>,
|
||||
which, similar to the normal code generation of a collection in a writer_interface, has 2 sub-stages
|
||||
which, similar to the normal code generation of a collection in a writer_interface, has 2 sub-stages
|
||||
(GET, WRITE). The difference is that the second sub-stage (WRITE) is not only waiting on the valid_out
|
||||
signal of the memory, but also on the respective ready port signal of the
|
||||
signal of the memory, but also on the respective ready port signal of the
|
||||
<ACTIONNAME>_ros_action_result_srv_server.
|
||||
Once the RESULT is ready and available on the <ACTIONNAME>_ros_action_result_srv_server, the PASSTHROUGH
|
||||
stage is entered. In this stage the r_sel_ack signal is toggled, signaling to the ros_action_server that
|
||||
it can continue its operations. The stage is held until the r_sel goes low, in which case the IDLE stage
|
||||
it can continue its operations. The stage is held until the r_sel goes low, in which case the IDLE stage
|
||||
is resumed.
|
||||
If r_index is equal to MAX_GOALS, it is treated as a special value, in which the RESULT is empty/don't care.
|
||||
If that is the case the PASSTHROUGH stage is taken directly (since we don't have to fetch any particular
|
||||
result from the memories), and a empty RESULT is made available to the
|
||||
If that is the case the PASSTHROUGH stage is taken directly (since we don't have to fetch any particular
|
||||
result from the memories), and a empty RESULT is made available to the
|
||||
<ACTIONNAME>_ros_action_result_srv_server.
|
||||
If ENABLE_FEEDBACK is '0', no ROS publisher for the FEEDBACK is generated, and the FEEDBACK output ports
|
||||
If ENABLE_FEEDBACK is '0', no ROS publisher for the FEEDBACK is generated, and the FEEDBACK output ports
|
||||
have to manually be set to default values.
|
||||
|
||||
NOTE: If the RESULT contains a collection, the read port signals of the
|
||||
NOTE: If the RESULT contains a collection, the read port signals of the
|
||||
<ACTIONNAME>_ros_action_result_srv_server are not needed, and can be hardwired to defaults
|
||||
(*_ren = '0', *_valid = open, *_ack = '1', *_r = open)
|
||||
|
||||
ACTION CLIENT
|
||||
-------------
|
||||
The <ACTIONNAME>_ros_action_client contains a FSM responsible for interfacing all the underlying service
|
||||
clients and subscribers. Since this state machine is static, only the port connection of the
|
||||
The <ACTIONNAME>_ros_action_client contains a FSM responsible for interfacing all the underlying service
|
||||
clients and subscribers. Since this state machine is static, only the port connection of the
|
||||
instantiated entities has to be generated.
|
||||
Similarly to the action server, if ENABLE_FEEDBACK is '0', the FEEDBACK output ports have to manually be
|
||||
Similarly to the action server, if ENABLE_FEEDBACK is '0', the FEEDBACK output ports have to manually be
|
||||
set to default values.
|
||||
|
||||
@ -3,6 +3,7 @@ use ieee.std_logic_1164.all;
|
||||
use ieee.numeric_std.all;
|
||||
|
||||
use work.math_pkg.all;
|
||||
use work.rtps_package.all;
|
||||
use work.ros_package.all;
|
||||
|
||||
package AddTwoInts_package is
|
||||
@ -10,10 +11,10 @@ package AddTwoInts_package is
|
||||
-- REQUEST
|
||||
constant MAX_RQ_A_SIZE : natural := 8;
|
||||
constant MAX_RQ_B_SIZE : natural := 8; -- 16
|
||||
constant MAX_ADDTWOINTS_RQ_SIZE : natural := 16 + SERVICE_OVERHEAD_BYTES;
|
||||
constant MAX_ADDTWOINTS_RQ_SIZE : natural := 16 + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
-- RESPONSE
|
||||
constant MAX_RR_SUM_SIZE : natural := 8;
|
||||
constant MAX_ADDTWOINTS_RR_SIZE : natural := 8 + SERVICE_OVERHEAD_BYTES;
|
||||
constant MAX_ADDTWOINTS_RR_SIZE : natural := 8 + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -3,6 +3,7 @@ use ieee.std_logic_1164.all;
|
||||
use ieee.numeric_std.all;
|
||||
|
||||
use work.math_pkg.all;
|
||||
use work.rtps_package.all;
|
||||
use work.ros_package.all;
|
||||
use work.GoalInfo_package;
|
||||
|
||||
@ -20,7 +21,7 @@ package Fibonacci_package is
|
||||
constant G_RR_MAX_STAMP_SEC_SIZE : natural := GoalInfo_package.MAX_STAMP_SEC_SIZE;
|
||||
constant G_RR_MAX_STAMP_NANOSEC_SIZE : natural := GoalInfo_package.MAX_STAMP_NANOSEC_SIZE;
|
||||
constant G_RR_MAX_STAMP_SIZE : natural := GoalInfo_package.MAX_STAMP_SIZE;
|
||||
constant G_RR_MAX_FIBONACCI_SIZE : natural := G_RR_MAX_ACCEPTED + G_RR_MAX_STAMP_SIZE;
|
||||
constant G_RR_MAX_FIBONACCI_SIZE : natural := G_RR_MAX_ACCEPTED + G_RR_MAX_STAMP_SIZE + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
-- RESULT
|
||||
constant R_RQ_GOAL_ID_MAX_DEPTH : natural := GoalInfo_package.GOAL_ID_MAX_DEPTH;
|
||||
@ -34,7 +35,7 @@ package Fibonacci_package is
|
||||
|
||||
constant R_RR_MAX_STATUS_SIZE : natural := 1;
|
||||
constant R_RR_MAX_SEQ_SIZE : natural := R_RR_SEQ_MAX_DEPTH * 4;
|
||||
constant R_RR_MAX_FIBONACCI_SIZE : natural := R_RR_MAX_STATUS_SIZE + R_RR_MAX_SEQ_SIZE;
|
||||
constant R_RR_MAX_FIBONACCI_SIZE : natural := R_RR_MAX_STATUS_SIZE + R_RR_MAX_SEQ_SIZE + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
-- FEEDBACK
|
||||
constant F_GOAL_ID_MAX_DEPTH : natural := GoalInfo_package.GOAL_ID_MAX_DEPTH;
|
||||
@ -44,6 +45,6 @@ package Fibonacci_package is
|
||||
|
||||
constant F_MAX_GOAL_ID_SIZE : natural := GoalInfo_package.MAX_GOAL_ID_SIZE;
|
||||
constant F_MAX_SEQ_SIZE : natural := F_SEQ_MAX_DEPTH * 4;
|
||||
constant F_MAX_FIBONACCI_SIZE : natural := F_MAX_GOAL_ID_SIZE + F_MAX_SEQ_SIZE;
|
||||
constant F_MAX_FIBONACCI_SIZE : natural := F_MAX_GOAL_ID_SIZE + F_MAX_SEQ_SIZE + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -17,7 +17,7 @@ package CancelGoal_package is
|
||||
constant RQ_MAX_GOAL_INFO_STAMP_NANOSEC_SIZE : natural := GoalInfo_package.MAX_STAMP_NANOSEC_SIZE;
|
||||
constant RQ_MAX_GOAL_INFO_STAMP_SIZE : natural := GoalInfo_package.MAX_STAMP_SIZE;
|
||||
constant RQ_MAX_GOAL_INFO_SIZE : natural := RQ_MAX_GOAL_INFO_GOAL_ID_SIZE + RQ_MAX_GOAL_INFO_STAMP_SIZE;
|
||||
constant RQ_MAX_CANCELGOAL_SIZE : natural := RQ_MAX_GOAL_INFO_SIZE;
|
||||
constant RQ_MAX_CANCELGOAL_SIZE : natural := RQ_MAX_GOAL_INFO_SIZE + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
-- RESPONSE
|
||||
constant RR_ERROR_NONE : std_logic_vector(CDR_INT8_WIDTH-1 downto 0) := std_logic_vector(to_unsigned(0,CDR_INT8_WIDTH));
|
||||
@ -36,5 +36,5 @@ package CancelGoal_package is
|
||||
constant RR_MAX_GOALS_CANCELING_STAMP_NANOSEC_SIZE : natural := GoalInfo_package.MAX_STAMP_NANOSEC_SIZE;
|
||||
constant RR_MAX_GOALS_CANCELING_STAMP_SIZE : natural := GoalInfo_package.MAX_STAMP_SIZE;
|
||||
constant RR_MAX_GOALS_CANCELING_SIZE : natural := RR_GOALS_CANCELING_MAX_DEPTH * GoalInfo_package.MAX_GOALINFO_SIZE;
|
||||
constant RR_MAX_CANCELGOAL_SIZE : natural := RR_MAX_RETURN_CODE_SIZE + RR_MAX_GOALS_CANCELING_SIZE;
|
||||
constant RR_MAX_CANCELGOAL_SIZE : natural := RR_MAX_RETURN_CODE_SIZE + RR_MAX_GOALS_CANCELING_SIZE + ROS_SERVICE_OVERHEAD_BYTES + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
end package;
|
||||
@ -21,5 +21,5 @@ package GoalInfo_package is
|
||||
constant MAX_STAMP_NANOSEC_SIZE : natural := 4;
|
||||
constant MAX_STAMP_SIZE : natural := MAX_STAMP_SEC_SIZE + MAX_STAMP_NANOSEC_SIZE;
|
||||
|
||||
constant MAX_GOALINFO_SIZE : natural := MAX_GOAL_ID_SIZE + MAX_STAMP_SIZE;
|
||||
constant MAX_GOALINFO_SIZE : natural := MAX_GOAL_ID_SIZE + MAX_STAMP_SIZE + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
end package;
|
||||
@ -3,6 +3,7 @@ use ieee.std_logic_1164.all;
|
||||
use ieee.numeric_std.all;
|
||||
|
||||
use work.math_pkg.all;
|
||||
use work.rtps_package.all;
|
||||
use work.ros_package.all;
|
||||
use work.GoalInfo_package;
|
||||
use work.GoalStatus_package;
|
||||
@ -22,6 +23,6 @@ package GoalStatusArray_package is
|
||||
constant MAX_STATUS_LIST_STATUS_SIZE : natural := GoalStatus_package.MAX_STATUS_SIZE;
|
||||
constant MAX_STATUS_LIST_SIZE : natural := STATUS_LIST_MAX_DEPTH * (GoalStatus_package.MAX_GOALSTATUS_SIZE);
|
||||
|
||||
constant MAX_GOALSTATUSARRAY_SIZE : natural := MAX_STATUS_LIST_SIZE;
|
||||
constant MAX_GOALSTATUSARRAY_SIZE : natural := MAX_STATUS_LIST_SIZE + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -17,7 +17,7 @@ package GoalStatus_package is
|
||||
constant STATUS_CANCELED : std_logic_vector(CDR_INT8_WIDTH-1 downto 0) := std_logic_vector(to_unsigned(5, CDR_INT8_WIDTH));
|
||||
constant STATUS_ABORTED : std_logic_vector(CDR_INT8_WIDTH-1 downto 0) := std_logic_vector(to_unsigned(6, CDR_INT8_WIDTH));
|
||||
|
||||
type GOALSTATUS_TYPE is record
|
||||
type GOALSTATUS_TYPE is record
|
||||
goal_info : Goalinfo_package.GOALINFO_TYPE;
|
||||
status : std_logic_vector(CDR_INT8_WIDTH-1 downto 0);
|
||||
end record;
|
||||
@ -25,6 +25,6 @@ package GoalStatus_package is
|
||||
constant MAX_GOAL_INFO_SIZE : natural := Goalinfo_package.MAX_GOALINFO_SIZE;
|
||||
constant MAX_STATUS_SIZE : natural := 1;
|
||||
|
||||
constant MAX_GOALSTATUS_SIZE : natural := MAX_GOAL_INFO_SIZE + MAX_STATUS_SIZE;
|
||||
constant MAX_GOALSTATUS_SIZE : natural := MAX_GOAL_INFO_SIZE + MAX_STATUS_SIZE + RTPS_PAYLOAD_HEADER_SIZE;
|
||||
|
||||
end package;
|
||||
@ -306,7 +306,7 @@ package ros_package is
|
||||
|
||||
type ENDPOINT_ROS_NODE_MAPPING_ARRAY_TYPE is array (natural range <>) of natural;
|
||||
|
||||
constant SERVICE_OVERHEAD_BYTES : natural := 16;
|
||||
constant ROS_SERVICE_OVERHEAD_BYTES : natural := 16;
|
||||
|
||||
constant GOAL_HANDLE_WIDTH : natural := WORD_WIDTH;
|
||||
constant GOAL_HANDLE_UNKNOWN : std_logic_vector(GOAL_HANDLE_WIDTH-1 downto 0) := (others => '1');
|
||||
|
||||
@ -134,7 +134,7 @@ package rtps_package is
|
||||
constant TIME_INFINITE : TIME_TYPE := (x"ffffffff", x"fffffffe");
|
||||
constant FIRST_SEQUENCENUMBER : SEQUENCENUMBER_TYPE := (x"00000000", x"00000001");
|
||||
constant SEQUENCENUMBER_UNKNOWN : SEQUENCENUMBER_TYPE := (x"ffffffff", x"00000000");
|
||||
constant PROTOCOL_RTPS : std_logic_vector(PROTOCOL_WIDTH-1 downto 0) := x"52545053"; -- 'RTPS' in Ascii code
|
||||
constant PROTOCOL_RTPS : std_logic_vector(PROTOCOL_WIDTH-1 downto 0) := x"52545053"; -- 'RTPS' in Ascii code
|
||||
constant PROTOCOLVERSION_1_0 : std_logic_vector(PROTOCOLVERSION_WIDTH-1 downto 0) := x"0100";
|
||||
constant PROTOCOLVERSION_1_1 : std_logic_vector(PROTOCOLVERSION_WIDTH-1 downto 0) := x"0101";
|
||||
constant PROTOCOLVERSION_2_0 : std_logic_vector(PROTOCOLVERSION_WIDTH-1 downto 0) := x"0200";
|
||||
@ -341,6 +341,9 @@ package rtps_package is
|
||||
constant PL_CDR2_LE : std_logic_vector(PAYLOAD_REPRESENTATION_ID_WIDTH-1 downto 0) := x"0013";
|
||||
constant D_CDR_BE : std_logic_vector(PAYLOAD_REPRESENTATION_ID_WIDTH-1 downto 0) := x"0014";
|
||||
constant D_CDR_LE : std_logic_vector(PAYLOAD_REPRESENTATION_ID_WIDTH-1 downto 0) := x"0015";
|
||||
|
||||
-- Size of RTPS Payload Header in Bytes
|
||||
constant RTPS_PAYLOAD_HEADER_SIZE : natural := 4;
|
||||
|
||||
-- *ENTITY ID*
|
||||
constant ENTITYID_UNKNOWN : std_logic_vector(ENTITYID_WIDTH-1 downto 0) := (others => '0');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user