Jump to content
    

Подключение USB мыши к FPGA DE2-115

Уважаемые знатоки, дали задание на лабораторную работу. Нужно подключить usb мышь на плату de2-115 и сделать подобие счётчика, при нажатии лкм +1, при нажатии пкм -1, вообще никак не могу понять как именно это сделать, уже перечитал все статьи. Можете помочь, пожалуйста, может кто-нибудь занимался этим ради прикола...:insane:

Share this post


Link to post
Share on other sites

Для начала почитайте документацию, там описан пример, который содержит 99.999% решения вашей задачи:
 

Цитата

6. 3 USB Paintbrush
USB port is widely used in many multimedia products. The DE2-115 board provides a complete
USB solution for both host and device applications. In this demonstration, we implement a
Paintbrush application by using a USB mouse as the input device.
This demonstration uses the device port of the Cypress CY7C67200 chip and the Nios II processor
to implement a USB mouse movement detector. We also implemented a video frame buffer with a

VGA controller to perform the real-time image storage and display. Figure 6-3 shows the block
diagram of the circuit, which allows the user to draw lines on the VGA display screen using the
USB mouse. The VGA Controller block is integrated into the Altera Avalon bus so that it can be
controlled by the Nios II processor.
Once the program runs, the Nios II processor is started as it will detect the existence of the USB
mouse connected to DE2-115 board. When the mouse moves, the Nios II processor is able to keep
track of the movement and record it in a frame buffer memory. The VGA Controller will overlap the
data stored in the frame buffer with a default image pattern and display the overlapped image on the
VGA display.

image.thumb.png.28e519cf91aebc0b305b68fb6bf2ec38.png

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...