Note: To access all shared projects, get information about environment setup, and view other guides, please visit Explore-In-HMOS-Wearable Index.
TCP Connection is a codelab project that developed to show how to provide TCP Socket connection with different devices.
- Users can enter the IP address of other device which is desired as to be connect device.
- Languages: ArkTS, ArkUI
- Frameworks: HarmonyOS 5.1.0(18)
- Tools: DevEco Studio Vers 5.1.0.828SP1, HarmonyOS Device Connector (hdc)
- Libraries: @kit.ArkUI, @kit.NetworkKit, @kit.BasicServicesKit
- Networking: TCP/HTTP socket server on port 12345
ohos.permission.INTERNETRequired to provide connection over TCP.
entry/src/main/ets/
├───entryability
│ EntryAbility.ets
├───entrybackupability
│ EntryBackupAbility.ets
├───pages
│ Index.ets
└───
- Huawei Watch 5
- The application is not working on previewer.
- Each devices must be connected in same network
TCP Connection is distributed under the terms of the MIT License See the LICENSE for more information.



