Refactor vusb to protocol use pre/post task (#14944)
This commit is contained in:
		
							parent
							
								
									4bbfecae90
								
							
						
					
					
						commit
						63dd131d81
					
				
					 5 changed files with 35 additions and 61 deletions
				
			
		| 
						 | 
				
			
			@ -151,7 +151,7 @@ __attribute__((weak)) void raw_hid_receive(uint8_t *data, uint8_t length) {
 | 
			
		|||
 *
 | 
			
		||||
 * FIXME: Needs doc
 | 
			
		||||
 */
 | 
			
		||||
static void raw_hid_task(void) {
 | 
			
		||||
void raw_hid_task(void) {
 | 
			
		||||
    // Create a temporary buffer to hold the read in data from the host
 | 
			
		||||
    uint8_t data[RAW_EPSIZE];
 | 
			
		||||
    bool    data_read = false;
 | 
			
		||||
| 
						 | 
				
			
			@ -865,10 +865,6 @@ void protocol_post_task(void) {
 | 
			
		|||
    CDC_Device_USBTask(&cdc_device);
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
#ifdef RAW_ENABLE
 | 
			
		||||
    raw_hid_task();
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
#if !defined(INTERRUPT_CONTROL_ENDPOINT)
 | 
			
		||||
    USB_USBTask();
 | 
			
		||||
#endif
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue