
๐๐ฎ๐๐ฌ๐ญ๐ข๐จ๐ง: Can we delete or skip any port in instantiation of entities in ๐๐๐๐?
๐๐ง๐ฌ๐ฐ๐๐ซ: If the port you do not want to use is an ๐จ๐ฎ๐ญ๐ฉ๐ฎ๐ญ port, then it is OK to remove this port from instantiation or connect the port with โ๐จ๐ฉ๐๐งโ keyword of VHDL:
๐๐ธ๐๐_๐ผ๐๐๐_๐ผ : ๐๐๐ก๐๐ก๐ฆ ๐ค๐๐๐.๐ก๐๐ ๐ก_๐๐๐ ๐ก(๐ต๐โ๐๐ฃ๐๐๐๐๐) ๐๐๐๐ก ๐๐๐ ( ๐๐๐ย ย ย ย => ๐๐๐ย ย ย , ๐๐ ๐กย ย ย ย => ๐๐ ๐กย ย ย , ๐๐ข๐1_๐ย ย ย => ๐๐ข๐1_๐ย ย , ๐๐ข๐2_๐ย ย ย => ๐๐ข๐2_๐ย ย , โ๐๐ข๐_๐ ๐ข๐_๐ย => ๐๐๐๐, ๐๐ข๐_๐๐๐_๐ย => ๐๐ข๐_๐๐๐_๐ );
But, if the port you do not want to use is an ๐ข๐ง๐ฉ๐ฎ๐ญ port, then Vivado gives you an error. So, you have to connect some signal to an input port even a constant is OK.
For example, if we delete rst input port in the instantiation, then we get this error from Vivado:
๐๐ธ๐๐_๐ผ๐๐๐_๐ผ : ๐๐๐ก๐๐ก๐ฆ ๐ค๐๐๐.๐ก๐๐ ๐ก_๐๐๐ ๐ก(๐ต๐โ๐๐ฃ๐๐๐๐๐) ๐๐๐๐ก ๐๐๐ ( ๐๐๐ย ย ย ย => ๐๐๐ย ย ย , โ ๐๐ ๐กย ย ย ย => ๐๐ ๐กย ย ย , ๐๐ข๐1_๐ย ย ย => ๐๐ข๐1_๐ย ย , ๐๐ข๐2_๐ย ย ย => ๐๐ข๐2_๐ย ย , โ๐๐ข๐_๐ ๐ข๐_๐ย => ๐๐๐๐, ๐๐ข๐_๐๐๐_๐ย => ๐๐ข๐_๐๐๐_๐ );
[๐๐ฆ๐๐กโ 8-2029] ๐๐๐๐๐๐ ๐๐ ๐ก โ๐๐ ๐๐ ๐๐๐ก๐ข๐๐ ๐๐ ๐๐๐๐๐ข๐๐ก ๐ฃ๐๐๐ข๐
I prefer to keep the output port and use โ๐จ๐ฉ๐๐งโ keyword when I wonโt plan to use that output port.
What about you? Please share your thoughts in comment section.
โ๐บ๐๐๐๐๐๐ ๐๐๐๐๐๐๐ ๐๐ ๐๐ ๐๐๐ ๐๐๐๐ ๐๐๐๐๐๐๐๐๐ ๐๐๐๐๐๐๐๐ ๐๐๐๐๐๐ โ
