Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

Xilinx User Constraints File for a PS2 Mouse Module

Status
Not open for further replies.

vjabagch

Member level 1
Joined
Jun 26, 2009
Messages
35
Helped
4
Reputation
8
Reaction score
4
Trophy points
1,288
Activity points
1,665
user constraints

I have been developing and simulating a PS/2 mouse controller for a Xilinx Virtex 5 FPGA (XUPV5-LX110T). This board was purchased from Digilent Incorporated.

I have created a User Constraints File (UCF) for a PS2 mouse module and have loaded my PS2 mouse module to the FPGA board to observe some LED's flash. I observe no change in output when I move the mouse.

Is my UCF properly specified. Do I need more parameters for each net such as Iostandard Declarations?


Here is where I obtained my User Constraints Template
http://www.xilinx.com/univ/xupv5-lx110t/design_files/master_xupv5-lx110t.ucf

The following is my UCF File Contents

NET "IB" LOC="J19" | IOSTANDARD = "LVDS_25"; #CLKBUF_Q1_N Bank 3, Vcco=2.5V, No DCI
NET "I" LOC="K18" | IOSTANDARD = "LVDS_25"; #CLKBUF_Q1_P Bank 3, Vcco=2.5V, No DCI

NET "PS2C" LOC="R27"; # Bank 15, Vcco=1.8V, DCI using 49.9 ohm resistors
NET "PS2D" LOC="U26"; # Bank 15, Vcco=1.8V, DCI using 49.9 ohm resistors

NET "reset" LOC="E9"; #NET FPGA_CPU_RESET_B LOC="E9" # Bank 20, Vcco=3.3V, DCI using 49.9 ohm resisto

NET "middle_button_pressed" LOC="E8"; # Bank 20, Vcco=3.3V, DCI using 49.9 ohm resistors
NET "right_button_pressed" LOC="AG23"; # Bank 2, Vcco=3.3V
NET "mouse_moving_up" LOC="AF13"; # Bank 2, Vcco=3.3V
NET "mouse_moving_down" LOC="AG12"; # Bank 2, Vcco=3.3V
NET "left_button_pressed" LOC="AF23"; # Bank 2, Vcco=3.3V

NET "absolute_x_movement<7>" LOC="H18"; # Bank 3, Vcco=2.5V, No DCI
NET "absolute_x_movement<6>" LOC="L18"; # Bank 3, Vcco=2.5V, No DCI
NET "absolute_x_movement<5>" LOC="G15"; # Bank 3, Vcco=2.5V, No DCI
NET "absolute_x_movement<4>" LOC="AD26"; # Bank 21, Vcco=1.8V, DCI using 49.9 ohm resistors
NET "absolute_x_movement<3>" LOC="G16"; # Bank 3, Vcco=2.5V, No DCI
NET "absolute_x_movement<2>" LOC="AD25"; # Bank 21, Vcco=1.8V, DCI using 49.9 ohm resistors
NET "absolute_x_movement<1>" LOC="AD24"; # Bank 21, Vcco=1.8V, DCI using 49.9 ohm resistors
NET "absolute_x_movement<0>" LOC="AE24"; # Bank 21, Vcco=1.8V, DCI using 49.9 ohm resistors



If the UCF is correct, then I am thinking that the module has one of several problems.

1) The PS2 Clock is too Fast or Slow
2) The PS2 Mouse Initialization Sequence is not correct
3) There is contention for driving PS2Clock and PS2Data High and Low during initialization
4) Some other issue I am not aware of


Some extra information.

When I power on the unit and observe the Mouse Data on Chipscope I select all the nets on the UCF but I omit the bidirectional lines because I can not observe bidirectionals. I move the mouse and all outputs remain 0. My LEDs do not light up either.

I would be happy to present my testbench and my UUT but I want to first verify that my UCF is correct. My waveform on simulation looks consistent but I am thinking that if my UCF not wrong then my initialization sequence is incorrect.

If that is the case I might need to adjust the mouse values on the testbench.

My mouse module runs at 100 MHz and the PS/2 Clock runs at 16.67 KHz.

Thank you.

Added after 5 hours 5 minutes:

It looks like after hooking up the state machine output bits to the LED's they got stuck at a state which indicates that the mouse is not sending back data from what is called a Basic Assurance Test. This confirms that the initialization sequence is not finished and therefore does not trigger the mode where the mouse reports its coordinates and buttons pressed.
 

goshka

Advanced Member level 4
Joined
Jul 26, 2003
Messages
115
Helped
9
Reputation
18
Reaction score
5
Trophy points
1,298
Location
Tver,Russia
Activity points
951
ps2 testbench

Has ps2clk, ps2data fpga I/O pin signal level converter to 5.0V TTL (with 4k7 pull-up) ?
You must connect bank power supply correcttly.
I/O signal level voltage is depended on bank power supply only.
Iostandart constrain have effect on xst timing analys only.
 

    vjabagch

    points: 2
    Helpful Answer Positive Rating

vjabagch

Member level 1
Joined
Jun 26, 2009
Messages
35
Helped
4
Reputation
8
Reaction score
4
Trophy points
1,288
Activity points
1,665
lvds_25 1.8

Thank you for the assistance. The mouse module was stuck in the initialization state. I was able to conclude this by outputting the state bits to 5 LEDs.
 

Status
Not open for further replies.
Toggle Sidebar

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top