Re: Projekt piTelex - Vorstellung
Verfasst: Sa 21. Jan 2023, 14:40
Vielleicht kann mir auch noch jemand helfen:
Habe es mit einem fertigen Image von Jochen versucht aber es scheint als würde es nicht laufen. Die LED flackert beim Wählen, aber mehr passiert nichts. Auch an der Firewall kann ich nur sehen das der Rpi Verbindung zu einem NTP aufbaut.
Ich nutze einen RPi 1B mit dem SEU-M Board. Starte ich telex.py kommt folgendes:
Hat mir hier jemand noch eine Idee? Habe ich noch etwas vergessen?
Hier noch meine telex.json File:
Habe es mit einem fertigen Image von Jochen versucht aber es scheint als würde es nicht laufen. Die LED flackert beim Wählen, aber mehr passiert nichts. Auch an der Firewall kann ich nur sehen das der Rpi Verbindung zu einem NTP aufbaut.
Ich nutze einen RPi 1B mit dem SEU-M Board. Starte ich telex.py kommt folgendes:
Code: Alles auswählen
pi@piTelex-TW39:~/piTelex $ sudo ./telex.py --RPiTW39 --iTelex 2342 --log pitelex.log --id "134567 dummy d"
Traceback (most recent call last):
File "/home/pi/piTelex/./telex.py", line 372, in <module>
main()
File "/home/pi/piTelex/./telex.py", line 322, in main
init()
File "/home/pi/piTelex/./telex.py", line 192, in init
ctrl = txDevRPiCtrl.TelexRPiCtrl(**dev_param)
File "/home/pi/piTelex/txDevRPiCtrl.py", line 93, in __init__
self._button_U1 = Button(self._pin_button_U1, self._callback_button_U1)
File "/home/pi/piTelex/RPiIO.py", line 128, in __init__
pi.set_mode(pin, pigpio.INPUT)
File "/usr/lib/python3/dist-packages/pigpio.py", line 1376, in set_mode
return _u2i(_pigpio_command(self.sl, _PI_CMD_MODES, gpio, mode))
File "/usr/lib/python3/dist-packages/pigpio.py", line 1011, in _u2i
raise error(error_text(v))
pigpio.error: 'no permission to update GPIO'
Traceback (most recent call last):
File "/home/pi/piTelex/RPiIO.py", line 138, in __del__
self._cb.cancel() # disable
AttributeError: 'Button' object has no attribute '_cb'
--- Logging error ---
Traceback (most recent call last):
File "/usr/lib/python3.9/logging/handlers.py", line 73, in emit
if self.shouldRollover(record):
File "/home/pi/piTelex/./telex.py", line 64, in shouldRollover
current_year_month = datetime.datetime.now().strftime("%Y-%m")
ImportError: sys.meta_path is None, Python is likely shutting down
Call stack:
File "/home/pi/piTelex/./telex.py", line 145, in unraisablehook
excepthook(unraisable.exc_type, unraisable.exc_value, unraisable.exc_traceback)
File "/home/pi/piTelex/./telex.py", line 141, in excepthook
l.critical(to_log)
Message: 'Traceback (most recent call last):\n File "/home/pi/piTelex/RPiIO.py", line 138, in __del__\n self._cb.cancel() # disable\n File "/usr/lib/python3/dist-packages/pigpio.py", line 1246, in cancel\n self._notify.remove(self.callb)\n File "/usr/lib/python3/dist-packages/pigpio.py", line 1160, in remove\n _pigpio_command(\n File "/usr/lib/python3/dist-packages/pigpio.py", line 1025, in _pigpio_command\n sl.s.send(struct.pack(\'IIII\', cmd, p1, p2, 0))\nAttributeError: \'NoneType\' object has no attribute \'send\'\n'
Arguments: ()
Traceback (most recent call last):
File "/home/pi/piTelex/RPiIO.py", line 138, in __del__
self._cb.cancel() # disable
File "/usr/lib/python3/dist-packages/pigpio.py", line 1246, in cancel
self._notify.remove(self.callb)
File "/usr/lib/python3/dist-packages/pigpio.py", line 1160, in remove
_pigpio_command(
File "/usr/lib/python3/dist-packages/pigpio.py", line 1025, in _pigpio_command
sl.s.send(struct.pack('IIII', cmd, p1, p2, 0))
AttributeError: 'NoneType' object has no attribute 'send'
Hier noch meine telex.json File:
Code: Alles auswählen
pi@piTelex-TW39:~/piTelex $ cat /boot/config/telex.json
{
"devices": {
"screen": {
"type": "screen",
"enable": true,
"show_BuZi": true,
"show_ctrl": true,
"show_info": false,
"show_capital": false
},
"Terminal VFD TEC/LIUST": {
"type": "terminal",
"enable": false,
"portname": "COM3",
"baudrate": 9600,
"dsrdtr": false,
"rtscts": false,
"xonxoff": false,
"show_BuZi": true,
"show_ctrl": true,
"show_info": false,
"show_capital": true,
"send_only": true,
"auto_CRLF": 20,
"init_hex": "1B 5B 32 4A 1B 5C 3F 4C 44 35 1F 5C 3F 4C 43 31", # clear display brightness cursor mode
"init_text": "\r -= piTelex VFD =-\r\n",
"replace_hex": {
# "0": "D0",
# "1": "D1",
# "2": "D2",
# "3": "D3",
# "4": "D4",
# "5": "D5",
# "6": "D6",
# "7": "D7",
# "8": "D8",
# "9": "D9",
# "A": "DA",
# "B": "DB",
# "C": "DC",
# "D": "DD",
# "E": "DE",
# "F": "DF",
"\r": "AE", # WR
"\n": "F2", # ZL
"<": "DC", # Bu
">": "DF", # Zi
"~": "F8", # null
"%": "DB" # bell
},
"replace_text": {
" ": "_" # space
}
},
"Terminal VFD ESC/POS": {
"type": "terminal",
"enable": false,
"portname": "COM3",
"baudrate": 9600,
"dsrdtr": false,
"rtscts": false,
"xonxoff": false,
"show_BuZi": true,
"show_ctrl": true,
"show_info": false,
"show_capital": true,
"send_only": true,
"init_hex": "0C 1F 58 04 1F 43 01 1F 02", # clear display brightness cursor on vert. scroll
"init_text": " -= piTelex VFD =-\r\n",
"replace_hex": {
"\r": "AE", # WR
"\n": "F0", # ZL
"<": "DC", # Bu
">": "DF", # Zi
" ": "FA", # space
"~": "B1", # null
"%": "EA" # bell
},
"replace_text": {
"+": "+" # example
}
},
# SEU-M - TW39-teletype using an Austrian AGT (OeAGT) with SEU-M-card as controller
# Note: SEU-M-card (with aRPi) is a replacement of a SEU-B ord SES-B-card
"RPiTTY_SEU-M_Oe-AGT": {
"type": "RPiTTY",
"enable": true,
"mode": "AGT",
"pin_txd": 17,
"pin_rxd": 27,
"pin_relay": 22,
"inv_relay": true,
"pin_power": 9,
"inv_power": false,
"pin_number_switch": 10,
"inv_number_switch": true,
"baudrate": 50,
"coding": 0, # 0=ITA2
"loopback": false,
"WB_pulse_length": 60
},
"RPiCtrl": {
"type": "RPiCtrl",
"enable": true,
"pin_number_switch": 0,
"pin_button_1T": 8,
"pin_button_AT": 0,
"pin_button_ST": 0,
"pin_button_LT": 0,
"pin_button_U1": 12,
"pin_button_U2": 16,
"pin_button_U3": 20,
"pin_button_U4": 21,
"pin_LED_A": 0,
"pin_LED_WB": 0,
"pin_LED_WB_A": 9,
"pin_LED_status_R": 23,
"pin_LED_status_G": 24
},
"i-Telex": {
"type": "i-Telex",
"enable": true,
"port": 2342,
"tns-dynip-number": 1,
"tns-pin": xxxx
},
"log": {
"type": "log",
"enable": true,
"filename": "/data/piTelex/data.log"
},
"news": {
"type": "news",
"enable": false,
"newspath": "/data/piTelex/news/"
},
"archive": {
"type": "archive",
"enable": false,
"path": "/data/piTelex/"
},
"shellcmd": {
"type": "shellcmd",
"enable": false,
"LUT": {
"TP1": "curl -s -o null http://fs200.fritz.box/cm?cmnd=Power%20On",
"TP0": "curl -s -o null http://fs200.fritz.box/cm?cmnd=Power%20Off",
"x": "explorer"
}
}
},
"verbose": true,
"wru_id": "417575 47 embden db",
"wru_fallback": false,
"dial_timeout": 0,
"continue_with_no_printer": true,
"debug": 3,
"errorlog_path": "piTelex/",
"errorlog_path_x": "/data/piTelex/"
}