Skip to content

Client Architecture

graph TD
    A[Open MCTool Client] --> B{Device Matching}
    B -- Success --> C[Device Home Page]
    B -- Failure --> D{Check Wi-Fi\\n Rematch}
    C --> E[MDVR Device Configuration]
    C --> F[Real-time Video Live Stream]
    C --> G{Device File List}
    G --> H{Download File}
    H --> I[Device File Download]
    I --> J[Downloaded Files]
    J --> K[Play and Manage Files]
    C --> L[Client Settings]

    subgraph Device Matching
        B -- Auto Search --> B1{Show Matching Progress}
    end

    subgraph MDVR Device Configuration
        E --> E1[Enter Password to Log In]
        E --> E2[Configure Device Options]
        E --> E3{Refresh Configuration}
    end

    subgraph Real-time Video Live Stream
        F --> F1{Select Stream Type}
        F --> F2{Select Channel}
        F --> F3{Playback Control}
    end

subgraph Device File List
G --> G1{Filter Files: Channel, Date, Time}
G --> G2{View File Info}
G --> G3{Refresh File List}
end

subgraph Device File Download
I --> I1{Show Download Status}
I --> I2{Show File Info}
I --> I3{Show Download Progress}
I --> I4{Show Transcoding Progress}
end

subgraph Downloaded Files
J --> J1{View File Info}
J --> J2{Play File}
J --> J3{Save to Gallery}
J --> J4{Delete File}
end

subgraph Client Settings
L --> L1{Language Settings}
L --> L2{View Version Info}
L --> L3{View User Agreement}
end
sequenceDiagram
    participant User
    participant MCTool Client
    participant MDVR Device
    User ->> MCTool Client: Opens the client
    activate MCTool Client
    MCTool Client ->> MDVR Device: Connects via Wi-Fi, attempts to match device
    alt Match Successful
        MDVR Device -->> MCTool Client: Returns success message
        MCTool Client ->> User: Displays device home page
    else Match Failed
        MDVR Device -->> MCTool Client: Returns failure message
        MCTool Client ->> User: Shows failure prompt, suggests checking Wi-Fi
    end

    User ->> MCTool Client: Enters device password, clicks login
    MCTool Client ->> MDVR Device: Sends login request
    alt Login Successful
        MDVR Device -->> MCTool Client: Returns success message
        MCTool Client ->> User: Displays device configuration page
    else Login Failed
        MDVR Device -->> MCTool Client: Returns failure message
        MCTool Client ->> User: Shows failure prompt, suggests checking password
    end

    User ->> MCTool Client: Selects Live/Playback function
    activate MCTool Client
    MCTool Client ->> MDVR Device: Sends live/playback request
    MDVR Device -->> MCTool Client: Returns video stream data
    MCTool Client ->> User: Displays video player interface
    deactivate MCTool Client
    User ->> MCTool Client: Downloads file / Manages downloaded files
    activate MCTool Client
    MCTool Client ->> MDVR Device: Sends file download/management request
    MDVR Device -->> MCTool Client: Returns file data / operation result
    MCTool Client ->> User: Updates download progress / file list
    deactivate MCTool Client
    User ->> MCTool Client: Enters settings page
    MCTool Client ->> User: Displays settings options
    User ->> MCTool Client: Modifies settings
    MCTool Client ->> User: Saves and applies settings