Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 1 | /* |
| 2 | * |
| 3 | * Copyright (c) 2020 Project CHIP Authors |
| 4 | * |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | * |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | * |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
| 17 | |
| 18 | /** |
| 19 | * @file |
| 20 | * This file defines some of the common constants, globals and interfaces |
| 21 | * that are common to and used by CHIP example applications. |
| 22 | * |
| 23 | */ |
| 24 | |
| 25 | #pragma once |
| 26 | |
Zang MingJie | 06be401 | 2022-03-05 02:28:33 +0800 | [diff] [blame] | 27 | #include <credentials/FabricTable.h> |
Damian Królik | b07872c | 2023-02-17 13:56:47 +0100 | [diff] [blame] | 28 | #include <crypto/DefaultSessionKeystore.h> |
Jean-Francois Penven | 33f6280 | 2022-02-11 12:50:58 -0500 | [diff] [blame] | 29 | #include <lib/support/TestPersistentStorageDelegate.h> |
Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 30 | #include <messaging/ExchangeMgr.h> |
Zang MingJie | c64d9d1 | 2021-05-13 00:09:08 +0800 | [diff] [blame] | 31 | #include <protocols/secure_channel/MessageCounterManager.h> |
Zang MingJie | eca9bff | 2021-09-23 03:19:51 +0800 | [diff] [blame] | 32 | #include <transport/SessionManager.h> |
Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 33 | |
Yufeng Wang | 2c5ef7b | 2021-01-12 13:27:51 -0800 | [diff] [blame] | 34 | constexpr size_t kMaxTcpActiveConnectionCount = 4; |
| 35 | constexpr size_t kMaxTcpPendingPackets = 4; |
| 36 | constexpr size_t kNetworkSleepTimeMsecs = (100 * 1000); |
Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 37 | |
Zang MingJie | 06be401 | 2022-03-05 02:28:33 +0800 | [diff] [blame] | 38 | extern chip::FabricTable gFabricTable; |
Zang MingJie | eca9bff | 2021-09-23 03:19:51 +0800 | [diff] [blame] | 39 | extern chip::SessionManager gSessionManager; |
Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 40 | extern chip::Messaging::ExchangeManager gExchangeManager; |
Zang MingJie | c64d9d1 | 2021-05-13 00:09:08 +0800 | [diff] [blame] | 41 | extern chip::secure_channel::MessageCounterManager gMessageCounterManager; |
Jean-Francois Penven | 33f6280 | 2022-02-11 12:50:58 -0500 | [diff] [blame] | 42 | extern chip::TestPersistentStorageDelegate gStorage; |
Damian Królik | b07872c | 2023-02-17 13:56:47 +0100 | [diff] [blame] | 43 | extern chip::Crypto::DefaultSessionKeystore gSessionKeystore; |
Yufeng Wang | 4282a07 | 2020-12-08 08:58:46 -0800 | [diff] [blame] | 44 | |
| 45 | void InitializeChip(void); |
| 46 | void ShutdownChip(void); |