eng.amr2009
Junior Member level 3
Hi guys,
I'm implementing a certain packet decoder. The incoming packet is sliced according to certain ranges defined in a standard.
I want to define the slice ranges in a package so that my code is readable and generic at the same time.
For example if I'm slicing the control_field then I want to write for example
where frame_length_range is (7 downto 0)
How can I define such range in a package ?
I used this syntax
But when I run syntax check I receive the following error:
I'm implementing a certain packet decoder. The incoming packet is sliced according to certain ranges defined in a standard.
I want to define the slice ranges in a package so that my code is readable and generic at the same time.
For example if I'm slicing the control_field then I want to write for example
Code:
frame_length <= control_field(frame_length_range);
where frame_length_range is (7 downto 0)
How can I define such range in a package ?
I used this syntax
Code:
type frame_length_range is range 7 downto 0;
But when I run syntax check I receive the following error:
Code:
Missing full type definition for frame_length_range