Ports
June 18, 2013, 06:44:52 pm *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: SMF - Just Installed!
 
   Home   Help Search Login Register  
Welcome to the PORTS Forum. Please post your questions, answers, and comments relating to USB and other hardware interfaces in the appropriate forums below. - Jan
Pages: [1]
  Print  
Author Topic: Using an Endpoint as Input  (Read 1231 times)
gbr
Member
***
Posts: 23


« on: November 05, 2010, 01:05:36 am »

Hello Jan,

There is a point that I'd like to clarify  in the use of an Endpoint for input

There are , I think , 2 possibilities

1 Although the EndPoint is defined as Interrupt driven ,Sending a "continuous" stream of data I.E as soon as the BDSTAT of the ENDpoint IN is passed back to the program from the SIE,This does not uses interrupt ,I think
If I am correct , the last entry in the EndPoint Descriptor,the bInterval value is ignored ??

2 Make use of the interrupt flag TRNIF(in Microchip 18F's)   and send only when the interrupt is serviced ,the interval would then be applicable and the rate of Data reports would be function of the inverse of the value
Of course that implies that the Host needs to request the data at the rate described in the interval value
Logged
Jan Axelson
Administrator
Frequent Contributor
*****
Posts: 1642


WWW
« Reply #1 on: November 05, 2010, 08:25:07 am »

USB interrupt endpoints are interrupt-like because they have a guaranteed maximum latency.

An IN endpoint sends data only on receiving an IN token packet from the host.

When firmware has data to send on an interrupt IN endpoint, it arms the endpoint (in a device-specific way as described in the data sheet). On receiving an IN token packet, the hardware sends the data out and typically triggers an interrupt to inform the firmware that it can now re-arm the endpoint with new data to send on the next IN packet.
 
Jan
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!