Pin direction declarations on MKR Vidor Atmel and Cyclone 10

Hi everybody

Currently I'm working on a project using a MKR Vidor 4000, but I come across a doubt.

If I want to send data from the FPGA to the Atmel chip, or from the Atmel chip to the FPGA using the digital pins that both devices share, how should I declare this pins direction?

IE, if I write a digital value using the Atmel for the FPGA to read it, how should I declare the pins on both the Arduino IDE code, and the Verilog description? Looking to avoid damaging any device.

Should I declare the pin as output in the atmel and as a input on the FPGA, or as inout port on both of them (if that's even possible)?



Sending side configured as output and receiving side as input.

For inout / tristate. This you need some control signal or protocol level control who is sending. You can’t send from both at same time (you can if they are same. like buses that uses IO to pull down and there are resistor to pull bus up). FPGA should have driver strength but there is possibility to kill IO from FPGA.

If you don’t configure IO:s shared with SAMD as input/tristate or you left these unconfigured. check that from configuration unused pins is aren’t driving GND.