dirkse 8 lat temu
rodzic
commit
9077c8f27b
1 zmienionych plików z 4 dodań i 3 usunięć
  1. 4 3
      matrix/sender.py

+ 4 - 3
matrix/sender.py

@@ -51,15 +51,16 @@ def matrix_api(api_index, format, names):
 
 ## API Decls
 
-@matrix_api(1, '255s', 'text')
+@matrix_api(1, '500s', 'text')
 def print_text(text):
+    '''The maximum safe UDP payload is 508 bytes'''
     return text.encode('utf-8')
 
-@matrix_api(2, 'sh', 'text loop')
+@matrix_api(2, '500sh', 'text loop')
 def scroll_text(text, loop=1):
     return text.encode('utf-8'), loop
 
-@matrix_api(3, 'shh', 'text width fade')
+@matrix_api(3, '500shh', 'text width fade')
 def fit_text(text, width=0, fade=0):
     return text.encode('utf-8'), width, fade