Skip to content
Snippets Groups Projects
Commit 493867f0 authored by Eric Kooistra's avatar Eric Kooistra
Browse files

Added extra constant c_nof_count to clarify determination of c_count_max.

parent 58d27a17
No related branches found
No related tags found
No related merge requests found
......@@ -66,7 +66,8 @@ ARCHITECTURE rtl OF dp_counter_func_single IS
-- . range(0,7,2) = [0, 2, 4, 6]
-- . range(1,7,2) = [1, 3, 5]
-- . The maximum value is: start+((stop-1-start)/step)*step
CONSTANT c_count_max : NATURAL := g_range_start+((g_range_stop-1-g_range_start)/g_range_step)*g_range_step;
CONSTANT c_nof_count : NATURAL := (g_range_stop-1-g_range_start)/g_range_step + 1;
CONSTANT c_count_max : NATURAL := g_range_start+(c_nof_count-1)*g_range_step;
CONSTANT c_count_w : NATURAL := ceil_log2(c_count_max+1);
TYPE t_reg IS RECORD
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment