Rename TOTAL_NUM_CONFIGURATIONS to FIXED_NUM_CONFIGURATIONS, to match the existing FIXED_CONTROL_ENDPOINT_SIZE compile time option. Add FIXED_NUM_CONFIGURATIONS to the descriptors of each project using the option.
This commit is contained in:
		
							parent
							
								
									bbf89d81fa
								
							
						
					
					
						commit
						6f4cc344ab
					
				
					 71 changed files with 75 additions and 76 deletions
				
			
		| 
						 | 
				
			
			@ -141,8 +141,8 @@ static void USB_Device_SetConfiguration(void)
 | 
			
		|||
{
 | 
			
		||||
	bool AlreadyConfigured = (USB_ConfigurationNumber != 0);
 | 
			
		||||
 | 
			
		||||
#if defined(TOTAL_NUM_CONFIGURATIONS)
 | 
			
		||||
	if ((uint8_t)USB_ControlRequest.wValue > TOTAL_NUM_CONFIGURATIONS)
 | 
			
		||||
#if defined(FIXED_NUM_CONFIGURATIONS)
 | 
			
		||||
	if ((uint8_t)USB_ControlRequest.wValue > FIXED_NUM_CONFIGURATIONS)
 | 
			
		||||
	  return;
 | 
			
		||||
#else
 | 
			
		||||
	#if !defined(USE_FLASH_DESCRIPTORS) && !defined(USE_EEPROM_DESCRIPTORS) && !defined(USE_RAM_DESCRIPTORS)
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -51,7 +51,7 @@
 | 
			
		|||
	/* Public Interface - May be used in end-application: */
 | 
			
		||||
		/* Macros: */
 | 
			
		||||
			#if defined(USE_SINGLE_DEVICE_CONFIGURATION)
 | 
			
		||||
				#define TOTAL_NUM_CONFIGURATIONS           1
 | 
			
		||||
				#define FIXED_NUM_CONFIGURATIONS           1
 | 
			
		||||
			#endif
 | 
			
		||||
	
 | 
			
		||||
		/* Enums: */
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue