@ray-js/robot-custom-log Custom Log Utility Library
Overview
@ray-js/robot-custom-log is a custom utility library designed for robot vacuum business scenarios. It enables developers to easily record and export raw data such as maps and paths reported by devices, facilitating troubleshooting. It also provides a companion online parsing tool platform that significantly improves problem identification efficiency.
Features
-
Multi-type Log Recording: Supports independent recording of map data, path data, and custom logs
-
Secure Storage: Log content is encrypted before being written to the local file system
-
Real-time Monitoring: Provides log file change callbacks, supporting dynamic log list updates
-
Easy Sharing: Built-in log file sharing functionality for convenient data export
-
Online Parsing: Supports uploading log files to Tuya's official platform for visual parsing and dynamic rendering
Installation
Quick Start
- Record Logs
- Monitor and Display Log Files
- File Management
Log Parsing Platform
Exported log files can be uploaded to Tuya's official parsing platform for visual analysis:
-
Platform URL: https://developer.tuya.com/tools/vacuum/
-
Supported Features:
-
Log content parsing and display
-
Map data visualization rendering
-
Path data dynamic drawing
-
Multi-type data correlation analysis
-
Notes
- Call
authorizeFileWrite()to obtain file write permission before first use - Log file size and quantity are limited by local storage; regular cleanup is recommended
- It is recommended to disable this feature by default in production environments; control should be managed by the business side, as the SDK does not handle this
API Reference
Type Definitions
With this utility library, developers can quickly integrate data recording and debugging capabilities for robot vacuum businesses, effectively improving troubleshooting efficiency. For questions or suggestions, please refer to the official documentation or contact technical support.