diff --git a/soitool/coder.py b/soitool/coder.py index e900cc3e8042f41c0a168c49d41fdd28b4e1fcf9..dd37b164f9d0a1c9f8c9195d1cfa480aa97726fd 100644 --- a/soitool/coder.py +++ b/soitool/coder.py @@ -18,7 +18,8 @@ def get_code(code_length, mode="ascii", space_interval=0): 'ascii' for letters, 'digits' for digits and 'combo' for combination of letters and digits, by default 'ascii'. space_interval : int - Spaces will be inserted to code each interval if not 0, by default 0. + Spaces will be inserted into code each interval for readability if not + 0, by default 0. Return ------ @@ -71,7 +72,8 @@ def get_code_set(count, code_length, mode="ascii", space_interval=0): 'ascii' for letters (default), 'digits' for digits and 'combo' for combination of letters and digits. space_interval : int - Spaces will be inserted to code each interval if not 0, by default 0. + Spaces will be inserted into code each interval for readability if not + 0, by default 0. Return ------ diff --git a/soitool/modules/module_authentication_board.py b/soitool/modules/module_authentication_board.py index bcdd044546dab58b1efac742c2e6704794185bae..92a35dd08f7fe9f9b030def1940564da9bd4b369 100644 --- a/soitool/modules/module_authentication_board.py +++ b/soitool/modules/module_authentication_board.py @@ -13,12 +13,18 @@ from soitool.modules.module_base import ( START_NO_OF_AUTHENTICATION_CODES = 10 CODE_LENGTH = 25 -CODE_CHARACTERS = "ascii" # Has to be 'ascii', 'digits' or 'combo' -# Codes will consist of A-Z if 'ascii', 0-9 if 'digits' and A-Z+0-9 if 'combo'. -ROW_IDENTIFIERS = string.ascii_uppercase # Characters for first column, -# it's length determines maximum number of codes (rows). -SPACE_INTERVAL = 5 # Adds space between sets of characters, 0 => no spaces + +# Has to be 'ascii', 'digits' or 'combo'. Codes will consist of A-Z if +# 'ascii', 0-9 if 'digits' and A-Z+0-9 if 'combo'. +CODE_CHARACTERS = "ascii" + +# Characters for first column. It's length determines maximum number of +# codes (rows). +ROW_IDENTIFIERS = string.ascii_uppercase + +# Adds space between sets of characters, 0 => no spaces # If code is 123456 and interval is 2, code will be 12 34 56 +SPACE_INTERVAL = 5 HEADLINE_TEXT = "Autentiseringstavle"