Commit Graph

2033 Commits

Author SHA1 Message Date
Alex X ebe454e3be Fix relative links in readme 2026-01-17 18:24:24 +03:00
Alex X 1ec40f2fc3 Move schema.json to www/static 2026-01-17 13:57:05 +03:00
Alex X 790fdfbf7a Remove unnecessary codecs.html 2026-01-17 13:56:40 +03:00
Alex X 6d77b175d8 Move all JS libs to cdn.jsdelivr.net 2026-01-17 13:47:21 +03:00
Alex X 425fcffbe1 Code refactoring for xiaomi source 2026-01-17 10:06:13 +03:00
Alex X 9a1eac8ef4 Add cache to xiaomi cloud logins 2026-01-17 09:41:41 +03:00
Alex X 4ffdeb06d0 Merge branch 'xiaomi'
# Conflicts:
#	pkg/xiaomi/miss/client.go
#	pkg/xiaomi/miss/cs2/conn.go
#	pkg/xiaomi/producer.go
2026-01-17 09:23:23 +03:00
Alex X 6b4eb8ffb6 Big rewrite tutk proto support 2026-01-17 09:05:54 +03:00
Alex X 2f43bfe5dc Fix two-way audio for cs2+tcp proto for xiaomi source 2026-01-13 21:26:01 +03:00
Alex X 59161fcef2 Improve cs2+udp proto for xiaomi source #2026 #2030 2026-01-13 21:25:30 +03:00
Alex X fd68107940 Add "bad conn" for debugging UDP 2026-01-13 12:15:48 +03:00
Alex X b19c081642 Improve cs2+udp proto for xiaomi source 2026-01-13 12:13:58 +03:00
Alex X e614513b97 Fix formats table in readme 2026-01-11 19:57:52 +03:00
Alex X f9f22cdd0b Add about OS versions to readme 2026-01-11 19:56:45 +03:00
Alex X dab9efb7d0 Merge pull request #2029 from Johnnybyzhang/master
xiaomi/cs2: fix TCP keepalive to match official Mi Home app
2026-01-11 19:55:23 +03:00
Alex X eb39b80883 Fix login to Xiaomi account with captcha #1985 2026-01-11 16:46:23 +03:00
Johnnybyzhang ff04a0d4b2 xiaomi/cs2: reduce TCP keepalive interval to 1 second
Based on PCAP analysis of official Mi Home app traffic:
- Official app sends PING every ~1 second
- Previous 5-second interval was too slow, causing connection resets

Simply reduce keepalive timeout from 5s to 1s.
2026-01-11 20:26:34 +08:00
Johnnybyzhang c4b32e3a0b xiaomi/cs2: fix TCP keepalive to match official Mi Home app
Based on PCAP analysis of official Mi Home app traffic, the keepalive
mechanism was incorrect:

Before (broken):
- Sent PING every 5s only when receiving data
- Responded to PING with PONG

After (fixed):
- Send PING every 1 second independently via dedicated goroutine
- Don't respond to PING with PONG (official app doesn't either)
- Both sides send PING bidirectionally as heartbeats

The official app sends 199 PING messages and 0 PONG messages in a
typical session. This fix matches that behavior.

Fixes connection resets after prolonged streaming sessions with
Xiaomi cameras using the CS2 P2P protocol.
2026-01-11 14:57:50 +08:00
Alex X e960f90a97 Add formats and protocols to readme 2026-01-05 10:17:08 +03:00
Alex X d4dc670cb5 Add support two-way audio for Dafang camera 2026-01-02 10:19:58 +03:00
Alex X e77210f916 Improve support tutk vendor for xiaomi source 2026-01-01 09:28:02 +03:00
Alex X 44da81774c Add recv/send counters to xiaomi source 2026-01-01 08:42:36 +03:00
Alex X 4dae65a535 Fix audio sample rate for some xiaomi cameras #2006 2025-12-31 17:55:47 +03:00
Alex X a09e1b2f90 Update openapi 2025-12-27 17:50:40 +03:00
Alex X d183b99a44 Update GitHub Pages site link 2025-12-27 15:43:07 +03:00
Alex X 654e78b7c5 Add suggest button to config editor 2025-12-27 12:34:08 +03:00
Alex X 1cd5517026 Log all modules with custom loggers 2025-12-27 12:17:40 +03:00
Alex X 07fb78d661 Merge pull request #1980 from skrashevich/monaco-editor-141225
Replace ace editor to Monaco with config hints
2025-12-27 12:10:15 +03:00
Alex X 86f9f114b5 Code refactoring for #1980 2025-12-27 12:08:39 +03:00
Sergey Krashevich 7e38b4fe89 Add enum and pattern constraint checks to YAML linter
Enhances the YAML linter to validate scalar values against enum and pattern constraints defined in the schema. Adds utility functions for value comparison, schema constraint collection, and applies these checks during linting to provide more precise error messages for invalid values.
2025-12-27 12:00:47 +03:00
Sergey Krashevich 0fd2217bd2 Trigger suggestions for property completions
Adds logic to trigger the suggestion widget when completing a property if it expects a block or has value suggestions, improving the user experience in the config editor.
2025-12-27 10:26:15 +03:00
Sergey Krashevich 76bdc7e065 Refactor block scalar handling in config parser
Simplifies the logic for handling block scalar content by restructuring the conditional checks for blockScalarParentIndent. This improves readability and ensures correct processing of indented lines.
2025-12-27 09:56:52 +03:00
Sergey Krashevich 3bd433c950 Improve null checks and object handling in config.html
Replaces optional chaining with explicit null checks and more robust object property access throughout the file. Refactors destructuring and object spreading to use Object.assign for better compatibility. These changes improve code reliability and compatibility with older browsers or environments lacking support for newer JavaScript features.
2025-12-27 09:09:32 +03:00
Sergey Krashevich 4c50a2c00c Remove redundant min-height property from #config
Deleted an unnecessary 'min-height: 0;' CSS rule from the #config selector, as a fixed min-height is already set.
2025-12-27 08:50:00 +03:00
Sergey Krashevich 0e65bd05c4 Disable word-based suggestions in editor config
Updated the editor configuration in config.html to set wordBasedSuggestions to false and disable word suggestions in the suggestion widget. This change aims to refine the suggestion behavior for a more focused coding experience.
2025-12-27 08:49:26 +03:00
Alex X 05fd0c5cca Merge pull request #1956 from felipecrs/ffmpeg-timeout
Add `#timeout` param for ffmpeg source
2025-12-27 08:38:38 +03:00
Alex X a3a4276c15 Code refactoring for #1956 2025-12-27 08:36:40 +03:00
Sergey Krashevich 0f4607a070 Improve YAML language detection in config.html
Refactored the logic for detecting the YAML language in Monaco editor to handle cases where getLanguages may not be available or Monaco is not loaded. This increases robustness and prevents potential runtime errors.
2025-12-27 08:08:28 +03:00
Sergey Krashevich 11ad1129ed Add hover provider for YAML editor
Introduces a hover provider to the YAML editor using Monaco, displaying property descriptions from the schema when hovering over keys. This enhances the editor's usability by providing inline documentation for YAML properties.
2025-12-27 08:05:42 +03:00
Sergey Krashevich da0b19026c Improve YAML linter with indentation and block scalar checks
Adds detection for inconsistent indentation and unexpected indentation at the document root. Enhances block scalar handling by tracking parent indentation and skipping content lines accordingly. Also improves error reporting for missing map keys or list items.
2025-12-27 07:59:22 +03:00
Alex X c880c37d37 Merge pull request #1992 from FIGIO55/rtsp_onvif_params
Allow rtsp params (like #backchannel=0) from onvif sources
2025-12-26 23:06:30 +03:00
Alex X c4fb66a818 Code refactoring for #1992 2025-12-26 23:05:58 +03:00
Alex X 9b618f45d0 Rewrite webrtc listen logic #1890 #1892 2025-12-26 22:56:39 +03:00
Alex X 3fd1fe2622 Add net interfaces list to webrtc debug 2025-12-26 14:09:22 +03:00
Alex X 2f470fa518 Add support cs2+tcp protocol for xiaomi source 2025-12-26 12:53:52 +03:00
Alex X 212def9ceb Update app dev version format 2025-12-22 17:22:22 +03:00
Alex X 79698365bb Add fetch tags to GitHub actions 2025-12-22 12:24:00 +03:00
Alex X 5b1da84ae2 Add TUTK protocol to xiaomi source 2025-12-22 00:00:33 +03:00
Sergey Krashevich 247d4063ed Merge branch 'monaco-editor-141225' of github.com:skrashevich/go2rtc into monaco-editor-141225 2025-12-21 00:06:29 +03:00
Sergey Krashevich 7ada6d81eb Add YAML schema-based linting and validation
Integrates js-yaml for parsing and adds comprehensive YAML linting with schema-based type checking, duplicate key detection, and improved error reporting. Refactors and extends parsing utilities, enhances completion logic, and introduces a schema tools abstraction for type and property resolution.
2025-12-21 00:02:49 +03:00