You have defined entity spi_custom
And then define component spi_custom_slave
And then instantiate spi_custom_slave rcvr: spi_custom_slave port map (
There is no entity that is associated with the spi_custom_slave component in the code you've posted. Two options, choose one:
- Change the name of the entity to be spi_custom_slave
- Change the component and the instantiation to use spi_custom
As a side note, it is unnecessary and can cause problems when you define a component inside an architecture. It is not necessary because when you instantiate the component you can simply use direct entity instantiation like this:
rcvr: entity work.spi_custom port map (...
The problem comes in because, as you've probably noticed, the component and the entity are nearly identical which likely means you copy/paste but as the design evolves you might end up changing something one place but not in another (i.e. you didn't copy/paste) and run into a subtle difference because the component definition is slightly different (maybe just a default initializer difference). There are enough things to debug without creating your own avoidable problems that need debugging as well. As an example, had you not had the component definition in your original code, you might've spotted the error yourself since you wouldn't have been deflected by the fact that you defined a component that did not match the intended entity.
Unless you are using black box cores that you don't really have access to the code (like you will get with third party IP), you don't need to use components.
Kevin Jennings