Strengths
  
    
    
     
   
   Formal Definition
  
   The strength declaration construct is used for modeling net type 
   variables for a close correspondence with physical wires. 
  
   Simplified Syntax
  
   (Strength1, Strength0) 
   (Strength0, Strength1) 
   Strength1: 
   supply1, strong1, pull1, large1, 
   weak1, medium1, small1, highz1 
   Strength0: 
   supply0, strong0, pull0, large0, 
   weak0, medium0, small0, highz0 
  
   Description
  
   Strengths can be used to resolve which value should appear on a net 
   or gate output. 
  
   There are two types of strengths: drive strengths (Example
    1) and charge strengths (Example
    2). The drive strengths can be used for nets (except trireg 
   net), gates, and UDPs. The charge strengths can be used only for trireg 
   nets. The drive strength types are supply,
    strong, pull,
    weak, and highz 
   strengths. The charge strength types are large,
    medium and small strengths. 
  
   All strengths can be ordered by their value. The supply 
   strength is the strongest and the highz 
   strength is the weakest strength level. Strength value can be 
   displayed by system tasks ($display,
    $monitor - by using of the 
   %v characters - see Display tasks for more explanation). 
  
    
    
     | 
       
       Strength  | 
     
       
       Value  | 
     
       
       Value displayed by display tasks  | 
     
    
     | 
       
       supply  | 
     
       
       7  | 
     
       
       Su  | 
     
    
     | 
       
       strong  | 
     
       
       6  | 
     
       
       St  | 
     
    
     | 
       
       pull  | 
     
       
       5  | 
     
       
       Pu  | 
     
    
     | 
       
       large  | 
     
       
       4  | 
     
       
       La  | 
     
    
     | 
       
       weak  | 
     
       
       3  | 
     
       
       We  | 
     
    
     | 
       
       medium  | 
     
       
       2  | 
     
       
       Me  | 
     
    
     | 
       
       small  | 
     
       
       1  | 
     
       
       Sm  | 
     
    
     | 
       
       highz  | 
     
       
       0  | 
     
       
       HiZ  | 
     
    
  
   Table 23 Strengths ordered by value 
  
   If two or more drivers drive a signal then it will have the value of 
   the strongest driver (Example 3). 
  
   If two drivers of a net have the same strength and value, then the 
   net result will have the same value and strength (Example
    4). 
  
   If two drivers of a net have the same strength but different values 
   then signal value will be unknown and it will have the same strength 
   as both drivers (Example 5). 
  
   If one of the drivers of a net has an H or L value, then signal value 
   will be n1n2X, where n1 
   is the strength value of the driver that has the smaller strength, 
   and n2 is strength value of 
   driver that has the larger strength (Example
    6). 
  
   The combinations (highz0, highz1)
    and (highz1, highz0)
    are illegal. 
  
   Examples
  Example 1 
   
   and (strong1, weak0) b(o, 
   i1, i2); 
  
   Instance of and gate with strong1 
   strength and weak0 strength specified. 
  Example 2 
  
   trireg (medium)
    t; 
  
   The charge strength declaration for trireg net. 
  Example 3 
  
   buf (strong1,
    weak0) g1 (y, a); 
   buf (pull1,
    supply0) g2 (y, b); 
  
   If a = 0 and b = 0 then y will be 0 with supply 
   strength because both gates will set y to 0 and supply 
   (7) strength has bigger value than weak 
   (3) strength. 
  
   If a = 0 and b = 1 then y will be 1 with pull 
   strength because g1 will set y to 0 with weak 
   (3) strength and g2 will set y to 1 with pull 
   (5) strength (pull strength is stronger than the weak strength). 
  
   If a = 1 and b = 0 then y will be 0 with supply 
   strength because g1 will set y to 1 with strong 
   (6) strength and g2 will set y to 0 with supply 
   (7) strength (supply strength is stronger than the strong strength). 
  
   If a = 1 and b = 1 then y will be 1 with strong 
   strength because g1 will set y to 1 with strong 
   (6) strength and g2 will set y to 1 with pull 
   (5) strength. 
  Example 4 
  
   buf (strong1,
    weak0) g1 (y, a); 
   buf (strong1,
    weak0) g1 (y, b); 
  
   If a = 0 and 
   b = 0 then y will be 0 with weak strength. 
  
   If a = 1 and 
   b = 1 then y will be 1 with strong strength. 
  Example 5 
  
   buf (strong1,
    weak0) g1 (y, a); 
   buf (weak1,
    strong0) g1 (y, b); 
  
   If a = 1 and b = 0 then y will be x with strong strength. 
  Example 6 
  
   bufif0 (strong1,
    weak0) g1 (y, i1, ctrl); 
   bufif0 (strong1,
    weak0) g2 (y, i2, ctrl); 
  
   If ctrl = x, i1 = 0, and i2 = 1 then y will be x with 36X 
   strength, because g1 will set y to L with strong 
   strength (StL - 6) and g2 will set y to H with weak 
   strength (WeH - 3). 
  
   Important Notes
  
  
    
 
    |