Z5RWeb с webjson не записывает ключ в банк памяти 1. Писал в саппорт, получил сообщение "передано программистам, ожидайте решения". И молчок. Ни уточнения, ни решения. Видимо, сочли, что не важно. А оно важно - мы сделали ставку на эти контроллеры для ряда клиентов, а они не работают. Поэтому дублирую сюда с моими комментариями и логами.
...
--- Контроллер пришел, здравствуйте
DEBUG:root:BaseACSHTTPRequestHandler (WebJSON): Execute ACSEngine.ProcessHTTPRequest, params:
{'ControllerType': 'WebJSON', 'RequestType': 'POST', 'Path': '/', 'Data': b'{"type":"Z5RWEB","sn":42058,"messages":[{"id":1804289383,"operation":"power_on","fw":"3.26","conn_fw":"1.0.129","active":0,"mode":0,"controller_ip":"10.76.175.203","reader_protocol":"wiegand"}]}'}
DEBUG:root:Resp:
--- Здравствуй, контроллер. Я тебя знаю.
b'{"interval": 10, "date": "2018-09-12 10:13:07", "messages": [{"id": 855484826, "operation": "set_active", "online": 0, "active": 1}]}\n'
--- End Resp ---
--- Что мне сделать?
DEBUG:root:BaseACSHTTPRequestHandler (WebJSON): Execute ACSEngine.ProcessHTTPRequest, params:
{'ControllerType': 'WebJSON', 'RequestType': 'POST', 'Path': '/', 'Data': b'{"type":"Z5RWEB","sn":42058,"messages":[{ "id":855484826, "success":1},{"id":846930886,"operation":"ping","active":1,"mode":0}]}'}
DEBUG:root:Resp:
--- Запиши карточку
b'{"interval": 10, "date": "2018-09-12 10:13:08", "messages": [{"id": 161277, "operation": "add_cards", "cards": [{"tz": 255, "flags": 32, "card": "00000016B82A"}]}]}\n'
--- End Resp ---
--- Записал. Что еще сделать?
DEBUG:root:BaseACSHTTPRequestHandler (WebJSON): Execute ACSEngine.ProcessHTTPRequest, params:
{'ControllerType': 'WebJSON', 'RequestType': 'POST', 'Path': '/', 'Data': b'{"type":"Z5RWEB","sn":42058,"messages":[{ "id":161277, "success":1},{"id":1681692777,"operation":"ping","active":1,"mode":0}]}'}
DEBUG:root:Resp:
--- Больше ничего не надо
b'{"interval": 10, "date": "2018-09-12 10:13:09", "messages": []}\n'
--- End Resp ---
...
--- Переключаемся на протокол Z397Guard
DEBUG:root:Z5R: Accepted client connection from ('10.76.175.203', 44912), starting handler thread
DEBUG:root:Z397: get_device_info_brief - Z5R-WEB, 42058, 1, ......
DEBUG:root:Z5RServer: Device 42058's TTL has been expired, reloading...
DEBUG:root:ACSDevice.GetACSDeviceByObjectNameAndSerialNumber {'ClientID': 3, 'ACSDeviceID': 877, 'DeviceUUID': '1eae3fe7-53a7-41df-99db-fa1b118a04ab'}
DEBUG:root:Z397Guard: cmd_get_license - Reading base license
DEBUG:root:Z397Guard: License: max_contr_cnt = 32, max_key_cnt = 65535, lic_date = None, lic_ttl_minutes = None
DEBUG:root:Z397Guard: cmd_get_contr_list - Reading controller list
DEBUG:root:Z397Guard: cmd_get_contr_info - Reading controller info, contr_id = 2
DEBUG:root:Z397Guard: parse_response_converter - Controller params: contr_id = 2, factory_number = 42058, software_version = 3.26, event_addr_written = 37808, event_addr_read = 37808, contr_type = 40, contr_params = 78, contr_mem_size = 2, has_two_banks = True
DEBUG:root:Z397Guard: cmd_get_contr_settings - Reading controller settings, contr_id = 2, direction = 0
DEBUG:root:Z397Guard: cmd_get_contr_timeframes - Reading base controller timeframes, contr_id = 2, direction = 0
DEBUG:root:Z397Guard: cmd_get_contr_timeframes_ex - Reading additional controller timeframes, contr_id = 2, direction = 0
DEBUG:root:Z397Guard: cmd_contr_load_all_keys - Start loading keys, contr_id = 2
DEBUG:root:Z397Guard: cmd_contr_load_all_keys - Loading keys, bank_no = 0, key_total = 8168
DEBUG:root:Z397Guard: cmd_contr_load_all_keys - Loading keys, bank_no = 1, key_total = 8168
DEBUG:root:Z397Guard: cmd_contr_load_all_keys - End loading keys
--- Выведем содержимое прочитанных банков памяти
DEBUG:root:[{0: [1488938, 32, 255]}, {}] <-- В нулевой карточка записана, в первый - нет
...