ice40: only set/clear negclk bit if IO clock actually used

Signed-off-by: gatecat <gatecat@ds0.me>
This commit is contained in:
gatecat 2023-09-07 11:01:56 +02:00 committed by myrtle
parent eef5243fba
commit f9825c3130

View File

@ -540,6 +540,7 @@ void write_asc(const Context *ctx, std::ostream &out)
bool val = (pin_type >> i) & 0x01;
set_config(ti, config.at(y).at(x), "IOB_" + std::to_string(z) + ".PINTYPE_" + std::to_string(i), val);
}
if (cell.second->getPort(id_INPUT_CLK) || cell.second->getPort(id_OUTPUT_CLK))
set_config(ti, config.at(y).at(x), "NegClk", neg_trigger);
bool input_en = false;