Код ниже нормально работает в iSim но не синтезируется в ISE 14.2. Подозреваю проблема в одновременном сравнении переменных и их модификации.
Код
architecture Behavioral of neuron is
signal MembranePotential: integer range smallest_int to maximum_int :=0;
signal Refract_period: integer range 0 to refractory_len:=0;
signal Refract_en: std_logic;
signal SPIKEOUT: std_logic :='0';
begin
process( FASTCLK)
begin
if falling_edge(RST) then
SPIKEOUT<='0';
MembranePotential<=0;
elsif falling_edge(SLOW_CLK) then -- degrading membrane potential
if MembranePotential>MembraneThreshold then -- spike
MembranePotential<=0;
SPIKEOUT<='1';
Refract_period<=refractory_len;
elsif MembranePotential>0 then
MembranePotential<=MembranePotential-MembraneDegradationRate;
elsif SPIKEOUT='1' then --refractory period degradation
Refract_period<=Refract_period -1;
SPIKEOUT<='0';
end if;
elsif falling_edge(IN_SPIKE) then -- adding incoming spike
if Refract_period=0 then
MembranePotential<=MembranePotential+conv_integer(IN_WEIGHT);
end if;
end if;
end process;
OUTPUT<=SPIKEOUT;
end Behavioral;
signal MembranePotential: integer range smallest_int to maximum_int :=0;
signal Refract_period: integer range 0 to refractory_len:=0;
signal Refract_en: std_logic;
signal SPIKEOUT: std_logic :='0';
begin
process( FASTCLK)
begin
if falling_edge(RST) then
SPIKEOUT<='0';
MembranePotential<=0;
elsif falling_edge(SLOW_CLK) then -- degrading membrane potential
if MembranePotential>MembraneThreshold then -- spike
MembranePotential<=0;
SPIKEOUT<='1';
Refract_period<=refractory_len;
elsif MembranePotential>0 then
MembranePotential<=MembranePotential-MembraneDegradationRate;
elsif SPIKEOUT='1' then --refractory period degradation
Refract_period<=Refract_period -1;
SPIKEOUT<='0';
end if;
elsif falling_edge(IN_SPIKE) then -- adding incoming spike
if Refract_period=0 then
MembranePotential<=MembranePotential+conv_integer(IN_WEIGHT);
end if;
end if;
end process;
OUTPUT<=SPIKEOUT;
end Behavioral;
Переписал "двуступенчато" с промежуточными сигналами, проблема осталась. В "Проектировании цифровых схем на VHDL" Суворовой ничего не говорится о таких ограничениях.