tools/yosys/yosys -p 'synth_ice40 -top worker -blif $@' $<
%.asc: %.pcf %.blif
- tools/arachne-pnr/bin/arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^ -P tq144
+ tools/arachne-pnr/bin/arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^ -P tq144 -s 4
%.bin: %.asc
tools/icestorm/icepack/icepack $< $@
`define UART_DIVIDE 1
`define I2C_DIVIDE 4
`else
- `define UART_DIVIDE 2048
+ `define UART_DIVIDE 1024
`define I2C_DIVIDE 256
`endif
always @(posedge clk) begin
if(busy_in)
- dont_send <= 23'b11111111111111111111111;
+ dont_send <= 21'b111111111111111111111;
else if(dont_send)
dont_send <= dont_send - 1;
end
`ifdef SIM
`define UART_DIVIDE 1
`else
- `define UART_DIVIDE 2048
+ `define UART_DIVIDE 1024
`endif
module worker (input CLKin, output [4:0] led, output uart_tx, input uart_rx, output reg busy_out = 1, input busy_in, input is_worker);
always @(posedge clk) begin
if(busy_in)
- dont_send <= 23'b11111111111111111111111;
+ dont_send <= 21'b111111111111111111111;
else if(dont_send)
dont_send <= dont_send - 1;
end