ChatCrawlersearch across public Telegram Open the app
P

Python

сообщение · 2026-06-20 14:04 UTC
S
import can from datetime import datetime def sniff_can() -> None: try: bus = can.Bus( interface="socketcan", channel="can0" ) print("Listening for CAN messages. Press Ctrl+C to stop.\n") while True: message = bus.recv(timeout=1.0) if message is None: continue timestamp = datetime.now().strftime("%H:%M:%S.%f")[:-3] can_id = f"{message.arbitration_id:08X}" data = " ".join(f"{byte:02X}" for byte in message.data) print( f"{timestamp} | " f"ID: {can_id} | " f"DLC: {message.dlc} | " f"DATA: {data}" ) except KeyboardInterrupt: print("\nCAN sniffing stopped.") except can.CanError as error: print(f"CAN error: {error}") finally: if "bus" in locals(): bus.shutdown() if name == "main": sniff_can()

Вся лента · оригинал в Telegram

Open in Telegram Каталог площадок Искать в ChatCrawler

A snapshot of an open public feed from the search index ChatCrawler — “Google for public Telegram”; refreshed as the venue is crawled. Times are UTC.

Public content only, official Telegram API. About · FAQ · What we do not do · Remove a page · Catalog