Ignore negative values
This commit is contained in:
		@@ -10,11 +10,13 @@ def config(name, port_max, ports_label):
 | 
				
			|||||||
    for port in range(1, port_max + 1):
 | 
					    for port in range(1, port_max + 1):
 | 
				
			||||||
        print(f"down{port}.label {ports_label[port - 1]}")
 | 
					        print(f"down{port}.label {ports_label[port - 1]}")
 | 
				
			||||||
        print(f"down{port}.type DERIVE")
 | 
					        print(f"down{port}.type DERIVE")
 | 
				
			||||||
 | 
					        print(f"down{port}.min 0")
 | 
				
			||||||
        print(f"down{port}.graph no")
 | 
					        print(f"down{port}.graph no")
 | 
				
			||||||
        print(f"down{port}.cdef down{port},8,*")
 | 
					        print(f"down{port}.cdef down{port},8,*")
 | 
				
			||||||
    for port in range(1, port_max + 1):
 | 
					    for port in range(1, port_max + 1):
 | 
				
			||||||
        print(f"up{port}.label {ports_label[port - 1]}")
 | 
					        print(f"up{port}.label {ports_label[port - 1]}")
 | 
				
			||||||
        print(f"up{port}.type DERIVE")
 | 
					        print(f"up{port}.type DERIVE")
 | 
				
			||||||
 | 
					        print(f"up{port}.min 0")
 | 
				
			||||||
        print(f"up{port}.negative down{port}")
 | 
					        print(f"up{port}.negative down{port}")
 | 
				
			||||||
        print(f"up{port}.cdef up{port},8,*")
 | 
					        print(f"up{port}.cdef up{port},8,*")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user