Commit 67645743 authored by Martin Jeřábek's avatar Martin Jeřábek

remove trailing whitespace

parent 99be551d
--------------------------------------------------------------------------------
--
--
-- CTU CAN FD IP Core
-- Copyright (C) 2015-2018 Ondrej Ille <ondrej.ille@gmail.com>
--
-- Project advisors and co-authors:
--
-- Project advisors and co-authors:
-- Jiri Novak <jnovak@fel.cvut.cz>
-- Pavel Pisa <pisa@cmp.felk.cvut.cz>
-- Martin Jerabek <jerabma7@fel.cvut.cz>
-- Department of Measurement (http://meas.fel.cvut.cz/)
-- Faculty of Electrical Engineering (http://www.fel.cvut.cz)
-- Czech Technical University (http://www.cvut.cz/)
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
-- Component is furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in
--
-- The above copyright notice and this permission notice shall be included in
-- all copies or substantial portions of the Component.
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- IN THE COMPONENT.
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
-- protocol license from Bosch.
--
--
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
-- Purpose:
-- Feature test for immediate abortion of CAN Transmission.
--
--
-- Test sequence:
-- 1. Generate CAN Frame, and start transmission by Node 1.
-- 2. Wait until transmission is started, plus some random time.
......@@ -68,7 +68,7 @@ USE work.randomLib.All;
use work.CAN_FD_register_map.all;
package abort_transmittion_feature is
procedure abort_transmittion_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -78,14 +78,14 @@ package abort_transmittion_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
);
end package;
package body abort_transmittion_feature is
procedure abort_transmittion_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -95,7 +95,7 @@ package body abort_transmittion_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
)is
variable r_data : std_logic_vector(31 downto 0) :=
(OTHERS => '0');
......@@ -135,12 +135,12 @@ package body abort_transmittion_feature is
if (status.transmitter) then
exit;
end if;
end loop;
end loop;
------------------------------------------------------------------------
-- Now wait random time up to 25 000 clock cycles!
-- But at least 200 clock cycles! We want to avoid situation that unit
-- aborts immediately after the frame was commited and SOF was not
-- aborts immediately after the frame was commited and SOF was not
-- yet sent!
------------------------------------------------------------------------
wait_rand_cycles(rand_ctr, mem_bus_1.clk_sys, 200, 25000);
......@@ -170,7 +170,7 @@ package body abort_transmittion_feature is
--------------------------------------------------------------------
command.abort_transmission := true;
give_controller_command(command, ID_1, mem_bus_1);
--------------------------------------------------------------------
-- Now wait for few clock cycles until Node aborts the transmittion
--------------------------------------------------------------------
......@@ -182,14 +182,14 @@ package body abort_transmittion_feature is
if (status.transmitter) then
outcome := false;
end if;
--------------------------------------------------------------------
-- Now wait until unit 2 starts transmitting error frame! Note that
-- we cant wait until unit 1 starts to transmitt error frame! This
-- works only when both units are error active! When unit 2 turns
-- error passive unit 1 never starts transmitting active error
-- frame. It stays idle since it recieves recessive error passive
-- error frame from 2!
-- error frame from 2!
--------------------------------------------------------------------
CAN_wait_error_transmitted(ID_2, mem_bus_2);
......@@ -216,7 +216,7 @@ package body abort_transmittion_feature is
end if;
end if;
------------------------------------------------------------------------
-- Erase the error counter. We need node 1 to be error active since when
-- transmittion is aborted in last bit of crc field then Unit 2 sends
......@@ -225,11 +225,11 @@ package body abort_transmittion_feature is
-- hook up by error frame and test will stuck in infinite loop!
------------------------------------------------------------------------
err_counters.err_norm := 0;
err_counters.err_fd := 0;
err_counters.err_fd := 0;
err_counters.rx_counter := 0;
err_counters.tx_counter := 0;
set_error_counters(err_counters, ID_1, mem_bus_1);
end procedure;
end package body;
--------------------------------------------------------------------------------
--
--
-- CTU CAN FD IP Core
-- Copyright (C) 2015-2018 Ondrej Ille <ondrej.ille@gmail.com>
--
-- Project advisors and co-authors:
--
-- Project advisors and co-authors:
-- Jiri Novak <jnovak@fel.cvut.cz>
-- Pavel Pisa <pisa@cmp.felk.cvut.cz>
-- Martin Jerabek <jerabma7@fel.cvut.cz>
-- Department of Measurement (http://meas.fel.cvut.cz/)
-- Faculty of Electrical Engineering (http://www.fel.cvut.cz)
-- Czech Technical University (http://www.cvut.cz/)
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
-- Component is furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in
--
-- The above copyright notice and this permission notice shall be included in
-- all copies or substantial portions of the Component.
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- IN THE COMPONENT.
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
-- protocol license from Bosch.
--
--
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
......@@ -59,7 +59,7 @@
-- 7. Wait until one of the units turn receiver or collision appears.
-- 8. Compare expected outcome with actual outcome.
-- 9. Wait until bus is idle.
--
--
--------------------------------------------------------------------------------
-- Revision History:
--
......@@ -81,7 +81,7 @@ use work.CAN_FD_register_map.all;
use work.CAN_FD_frame_format.all;
package arbitration_feature is
procedure arbitration_feature_exec(
variable outcome :inout boolean;
signal rand_ctr :inout natural range 0 to RAND_POOL_SIZE;
......@@ -91,7 +91,7 @@ package arbitration_feature is
signal drv_bus_1 :in std_logic_vector(1023 downto 0);
signal drv_bus_2 :in std_logic_vector(1023 downto 0);
signal stat_bus_1 :in std_logic_vector(511 downto 0);
signal stat_bus_2 :in std_logic_vector(511 downto 0)
signal stat_bus_2 :in std_logic_vector(511 downto 0)
);
end package;
......@@ -99,7 +99,7 @@ end package;
package body Arbitration_feature is
procedure arbitration_feature_exec(
variable outcome :inout boolean;
signal rand_ctr :inout natural range 0 to RAND_POOL_SIZE;
......@@ -109,7 +109,7 @@ package body Arbitration_feature is
signal drv_bus_1 :in std_logic_vector(1023 downto 0);
signal drv_bus_2 :in std_logic_vector(1023 downto 0);
signal stat_bus_1 :in std_logic_vector(511 downto 0);
signal stat_bus_2 :in std_logic_vector(511 downto 0)
signal stat_bus_2 :in std_logic_vector(511 downto 0)
) is
variable rand_value : real;
variable alc : natural;
......@@ -179,7 +179,7 @@ package body Arbitration_feature is
frame_1.ident_type := frame_2.ident_type;
frame_1.rtr := not frame_2.rtr;
end if;
------------------------------------------------------------------------
-- Recalc ID to decimal value with Ident type
------------------------------------------------------------------------
......@@ -205,9 +205,9 @@ package body Arbitration_feature is
-- 2. NON Matching ID -> Lower ID should win!
------------------------------------------------------------------------
if (ident_1 = ident_2) then
-- ID Type, ID, RTR the same -> collision!
if (frame_1.rtr = frame_2.rtr and
if (frame_1.rtr = frame_2.rtr and
frame_1.ident_type = frame_2.ident_type)
then
exp_winner := 2;
......@@ -287,7 +287,7 @@ package body Arbitration_feature is
exit;
end if;
end loop;
------------------------------------------------------------------------
-- Loop as long as one of the units turns to be reciever, or error
-- appears.
......@@ -317,12 +317,12 @@ package body Arbitration_feature is
unit_rec := 3;
end if;
end loop;
------------------------------------------------------------------------
-- Check whether expected winner is the unit which lost the arbitration
------------------------------------------------------------------------
if (unit_rec = 1 and exp_winner = 0) or
(unit_rec = 2 and exp_winner = 1)
if (unit_rec = 1 and exp_winner = 0) or
(unit_rec = 2 and exp_winner = 1)
then
report "Wrong unit lost arbitration. Expected: " &
integer'image(exp_winner) & " Real: " & integer'image(unit_rec)
......@@ -342,9 +342,9 @@ package body Arbitration_feature is
------------------------------------------------------------------------
send_TXT_buf_cmd(buf_set_abort, 1, ID_1, mem_bus_1);
send_TXT_buf_cmd(buf_set_abort, 1, ID_2, mem_bus_2);
CAN_wait_frame_sent(ID_1, mem_bus_1);
------------------------------------------------------------------------
-- Check what is the value in the ALC register
------------------------------------------------------------------------
......@@ -370,9 +370,8 @@ package body Arbitration_feature is
outcome := false;
end if;
wait for 100000 ns;
end procedure;
end package body;
end package body;
--------------------------------------------------------------------------------
--
--
-- CTU CAN FD IP Core
-- Copyright (C) 2015-2018 Ondrej Ille <ondrej.ille@gmail.com>
--
-- Project advisors and co-authors:
--
-- Project advisors and co-authors:
-- Jiri Novak <jnovak@fel.cvut.cz>
-- Pavel Pisa <pisa@cmp.felk.cvut.cz>
-- Martin Jerabek <jerabma7@fel.cvut.cz>
-- Department of Measurement (http://meas.fel.cvut.cz/)
-- Faculty of Electrical Engineering (http://www.fel.cvut.cz)
-- Czech Technical University (http://www.cvut.cz/)
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
-- Component is furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in
--
-- The above copyright notice and this permission notice shall be included in
-- all copies or substantial portions of the Component.
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- IN THE COMPONENT.
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
-- protocol license from Bosch.
--
--
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
-- Purpose:
-- Feature test for setting error counters from user and its appropriate fault
-- confinement state manipulation!
--
--
--------------------------------------------------------------------------------
-- Revision History:
--
......@@ -58,7 +58,7 @@ USE work.randomLib.All;
use work.CAN_FD_register_map.all;
package fault_confinement_feature is
procedure fault_confinement_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -68,14 +68,14 @@ package fault_confinement_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
);
end package;
package body fault_confinement_feature is
procedure fault_confinement_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -85,7 +85,7 @@ package body fault_confinement_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
)is
variable r_data : std_logic_vector(31 downto 0) :=
(OTHERS => '0');
......@@ -99,7 +99,7 @@ package body fault_confinement_feature is
variable th_1 : natural := 0;
variable rxc : natural := 0;
variable txc : natural := 0;
variable err_counters : SW_error_counters;
variable fault_th : SW_fault_thresholds := (0, 0);
variable fault_th_2 : SW_fault_thresholds := (0, 0);
......@@ -139,7 +139,7 @@ package body fault_confinement_feature is
if (fault_th.erp /= fault_th_2.erp) then
outcome := false;
end if;
------------------------------------------------------------------------
-- Read fault confinement state
------------------------------------------------------------------------
......@@ -162,7 +162,7 @@ package body fault_confinement_feature is
outcome := false;
end if;
end if;
end procedure;
end package body;
--------------------------------------------------------------------------------
--
--
-- CTU CAN FD IP Core
-- Copyright (C) 2015-2018 Ondrej Ille <ondrej.ille@gmail.com>
--
-- Project advisors and co-authors:
--
-- Project advisors and co-authors:
-- Jiri Novak <jnovak@fel.cvut.cz>
-- Pavel Pisa <pisa@cmp.felk.cvut.cz>
-- Martin Jerabek <jerabma7@fel.cvut.cz>
-- Department of Measurement (http://meas.fel.cvut.cz/)
-- Faculty of Electrical Engineering (http://www.fel.cvut.cz)
-- Czech Technical University (http://www.cvut.cz/)
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
-- Component is furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in
--
-- The above copyright notice and this permission notice shall be included in
-- all copies or substantial portions of the Component.
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- IN THE COMPONENT.
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.
-- Anybody who wants to implement this IP core on silicon has to obtain a CAN
-- protocol license from Bosch.
--
--
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
......@@ -53,7 +53,7 @@
-- was decreased.
-- 9. If error counters are over 70, restart them so that nodes won't
-- turn error passive.
--
--
--------------------------------------------------------------------------------
-- Revision History:
-- 21.6.2016 Created file
......@@ -73,7 +73,7 @@ use work.CAN_FD_frame_format.all;
package forbid_fd_feature is
procedure forbid_fd_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -83,14 +83,14 @@ package forbid_fd_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
);
end package;
package body forbid_fd_feature is
procedure forbid_fd_feature_exec(
variable outcome : inout boolean;
signal rand_ctr : inout natural range 0 to RAND_POOL_SIZE;
......@@ -100,7 +100,7 @@ package body forbid_fd_feature is
signal drv_bus_1 : in std_logic_vector(1023 downto 0);
signal drv_bus_2 : in std_logic_vector(1023 downto 0);
signal stat_bus_1 : in std_logic_vector(511 downto 0);
signal stat_bus_2 : in std_logic_vector(511 downto 0)
signal stat_bus_2 : in std_logic_vector(511 downto 0)
) is
variable r_data : std_logic_vector(31 downto 0) :=
(OTHERS => '0');
......@@ -130,7 +130,7 @@ package body forbid_fd_feature is
-- Read RX Error counter node 1
------------------------------------------------------------------------
read_error_counters(err_counters_1, ID_1, mem_bus_1);
------------------------------------------------------------------------
-- Send FD frame by node 2 and wait for error frame...
------------------------------------------------------------------------
......@@ -164,7 +164,7 @@ package body forbid_fd_feature is
------------------------------------------------------------------------
-- Counter should be decreased by one now due to sucesfull reception.
-- But it should be increased by 8 since it is the first node that
-- But it should be increased by 8 since it is the first node that
-- detected the error!
------------------------------------------------------------------------
if ((err_counters_1.rx_counter + 8) /= err_counters_2.rx_counter) then
......@@ -196,7 +196,7 @@ package body forbid_fd_feature is
------------------------------------------------------------------------
if ((err_counters_1.rx_counter + 7) /= err_counters_2.rx_counter) then
outcome := false;
end if;
end if;
------------------------------------------------------------------------
-- Since counter is incremented more than decremented, after many
......@@ -213,5 +213,3 @@ package body forbid_fd_feature is
end procedure;
end package body;
--------------------------------------------------------------------------------
--
--
-- CTU CAN FD IP Core
-- Copyright (C) 2015-2018 Ondrej Ille <ondrej.ille@gmail.com>
--
-- Project advisors and co-authors:
--
-- Project advisors and co-authors:
-- Jiri Novak <jnovak@fel.cvut.cz>
-- Pavel Pisa <pisa@cmp.felk.cvut.cz>
-- Martin Jerabek <jerabma7@fel.cvut.cz>
-- Department of Measurement (http://meas.fel.cvut.cz/)
-- Faculty of Electrical Engineering (http://www.fel.cvut.cz)
-- Czech Technical University (http://www.cvut.cz/)
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this VHDL component and associated documentation files (the "Component"),
-- to deal in the Component without restriction, including without limitation
-- the rights to use, copy, modify, merge, publish, distribute, sublicense,
-- and/or sell copies of the Component, and to permit persons to whom the
-- Component is furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in
--
-- The above copyright notice and this permission notice shall be included in
-- all copies or substantial portions of the Component.
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
--
-- THE COMPONENT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHTHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- FROM, OUT OF OR IN CONNECTION WITH THE COMPONENT OR THE USE OR OTHER DEALINGS
-- IN THE COMPONENT.
--
-- The CAN protocol is developed by Robert Bosch GmbH and protected by patents.