Tim Edwards01/27/2023, 1:58 PM
Philipp Gühring01/28/2023, 4:09 PM
Tim Edwards01/28/2023, 4:15 PM
to bit-bang the serial transfer, just set the configuration data per the output of
, then run
to run the automatic serial transfer. Follow that transfer by setting the configuration values to what they were intended to be, so that the housekeeping module understands which GPIOs are supposed to be inputs and which are supposed to be outputs.
reg_mprj_xfer = 1; while (reg_mprj_xfer == 1);
. This is for the Efabless example user project (which is just a simple multi-bit counter). I want to set all of the GPIOs to output, which puts the counter value on the GPIO outputs. So I run the usual python to calibrate the chip and to get the two bit-bang bitstreams. Then, once I have the file
for the configuration I want in my program, I run
, which gives me an output that I drop into my program, and that gives me lines 20 to 57 in the attached C code (
) below. Then in lines 65-67 I run the automatic serial load, and in lines 72-109 I set the configuration in the housekeeping registers back to what was intended (which is all outputs).