I have a Nexsys 2 board from Digilent. I also have the PMODJSTK. I am trying to use the joystick to control a couple of motors. I have the motor control part of the programing done. I can control the speed and direction of two different motors using the buttons and switches on the board. I am trying to write a program to get the joystick to light certain LED's - just so I can get the communication between the two to work and then I will combine the two programs. I can't get the commmunication between the board and the PMOD to work correctly. I am programing in Verilog (it's what I learned) - can anybody help?
PmodJSTK and your Nexys 2 will communicate via SPI. Nexys will be master and PmodJSTK will be slave. You should implement SPI controller in Spartan 3E. FPGA will send 5 bytes, first to light leds, the remaining four bytes that are shifted in will ignored by the PmodJSTK. PmodJSTK will response with 5 bytes X (low) X(high) Y (low) Y(high) Buttons.