Skip to content
This repository was archived by the owner on Apr 16, 2021. It is now read-only.

Commit 24b36b2

Browse files
authored
Merge pull request #35 from arduino/restore_low_power_ble
Restore Low Power BLE functionalty
2 parents 8b642cc + 58935cd commit 24b36b2

File tree

204 files changed

+4896
-545
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

204 files changed

+4896
-545
lines changed

cores/arduino/mbed/components/802.15.4_RF/stm-s2lp-rf-driver/source/s2lpReg.h

+4
Original file line numberDiff line numberDiff line change
@@ -249,10 +249,14 @@ extern "C" {
249249
// PCKTCTRL2
250250
#define PCKT_FIXVARLEN_FIELD 0x01
251251
#define PCKT_VARIABLE_LEN (1 << 0)
252+
#define PCKT_FCS_TYPE_FIELD 0x20
253+
#define PCKT_FCS_TYPE_4_OCTET (0 << 5)
254+
#define PCKT_FCS_TYPE_2_OCTET (1 << 5)
252255

253256
// PCKTCTRL1
254257
#define PCKT_CRCMODE_FIELD 0xE0
255258
#define PCKT_CRCMODE_0X1021 (3 << 5)
259+
#define PCKT_CRCMODE_0x04C11DB7 (5 << 5)
256260
#define PCKT_TXSOURCE_FIELD 0x0C
257261
#define PCKT_TXSOURCE_NORMAL (0 << 2)
258262
#define PCKT_WHITENING_FIELD 0x10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
/*
2+
* Copyright (c) 2018-2019, Arm Limited. All rights reserved.
3+
*
4+
* SPDX-License-Identifier: BSD-3-Clause
5+
*
6+
*/
7+
8+
/*******************************************************************************
9+
* !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
10+
* THIS FILE IS AN AUTO-GENERATED FILE - DO NOT MODIFY IT.
11+
* !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
12+
* Template Version 1.0
13+
* Generated by tools/psa/generate_partition_code.py Version 1.1
14+
******************************************************************************/
15+
16+
#ifndef __TFM_SPM_SIGNAL_DEFS_H__
17+
#define __TFM_SPM_SIGNAL_DEFS_H__
18+
19+
/*************************** Service Partitions *******************************/
20+
/* -----------------------------------------------------------------------------
21+
* ATTEST_SRV Signals
22+
* -------------------------------------------------------------------------- */
23+
#define PSA_ATTEST_GET_TOKEN_POS (4UL)
24+
#define PSA_ATTEST_GET_TOKEN (1UL << PSA_ATTEST_GET_TOKEN_POS)
25+
#define PSA_ATTEST_GET_TOKEN_SIZE_POS (5UL)
26+
#define PSA_ATTEST_GET_TOKEN_SIZE (1UL << PSA_ATTEST_GET_TOKEN_SIZE_POS)
27+
#define PSA_ATTEST_INJECT_KEY_POS (6UL)
28+
#define PSA_ATTEST_INJECT_KEY (1UL << PSA_ATTEST_INJECT_KEY_POS)
29+
30+
/* -----------------------------------------------------------------------------
31+
* CRYPTO_SRV Signals
32+
* -------------------------------------------------------------------------- */
33+
#define PSA_CRYPTO_INIT_POS (4UL)
34+
#define PSA_CRYPTO_INIT (1UL << PSA_CRYPTO_INIT_POS)
35+
#define PSA_MAC_POS (5UL)
36+
#define PSA_MAC (1UL << PSA_MAC_POS)
37+
#define PSA_HASH_POS (6UL)
38+
#define PSA_HASH (1UL << PSA_HASH_POS)
39+
#define PSA_ASYMMETRIC_POS (7UL)
40+
#define PSA_ASYMMETRIC (1UL << PSA_ASYMMETRIC_POS)
41+
#define PSA_SYMMETRIC_POS (8UL)
42+
#define PSA_SYMMETRIC (1UL << PSA_SYMMETRIC_POS)
43+
#define PSA_AEAD_POS (9UL)
44+
#define PSA_AEAD (1UL << PSA_AEAD_POS)
45+
#define PSA_KEY_MNG_POS (10UL)
46+
#define PSA_KEY_MNG (1UL << PSA_KEY_MNG_POS)
47+
#define PSA_RNG_POS (11UL)
48+
#define PSA_RNG (1UL << PSA_RNG_POS)
49+
#define PSA_CRYPTO_FREE_POS (12UL)
50+
#define PSA_CRYPTO_FREE (1UL << PSA_CRYPTO_FREE_POS)
51+
#define PSA_KEY_DERIVATION_POS (13UL)
52+
#define PSA_KEY_DERIVATION (1UL << PSA_KEY_DERIVATION_POS)
53+
#define PSA_ENTROPY_INJECT_POS (14UL)
54+
#define PSA_ENTROPY_INJECT (1UL << PSA_ENTROPY_INJECT_POS)
55+
56+
/* -----------------------------------------------------------------------------
57+
* PLATFORM Signals
58+
* -------------------------------------------------------------------------- */
59+
#define PSA_PLATFORM_LC_GET_MSK_POS (4UL)
60+
#define PSA_PLATFORM_LC_GET_MSK (1UL << PSA_PLATFORM_LC_GET_MSK_POS)
61+
#define PSA_PLATFORM_LC_SET_MSK_POS (5UL)
62+
#define PSA_PLATFORM_LC_SET_MSK (1UL << PSA_PLATFORM_LC_SET_MSK_POS)
63+
#define PSA_PLATFORM_SYSTEM_RESET_MSK_POS (6UL)
64+
#define PSA_PLATFORM_SYSTEM_RESET_MSK (1UL << PSA_PLATFORM_SYSTEM_RESET_MSK_POS)
65+
66+
/* -----------------------------------------------------------------------------
67+
* ITS Signals
68+
* -------------------------------------------------------------------------- */
69+
#define PSA_ITS_GET_MSK_POS (4UL)
70+
#define PSA_ITS_GET_MSK (1UL << PSA_ITS_GET_MSK_POS)
71+
#define PSA_ITS_SET_MSK_POS (5UL)
72+
#define PSA_ITS_SET_MSK (1UL << PSA_ITS_SET_MSK_POS)
73+
#define PSA_ITS_INFO_MSK_POS (6UL)
74+
#define PSA_ITS_INFO_MSK (1UL << PSA_ITS_INFO_MSK_POS)
75+
#define PSA_ITS_REMOVE_MSK_POS (7UL)
76+
#define PSA_ITS_REMOVE_MSK (1UL << PSA_ITS_REMOVE_MSK_POS)
77+
#define PSA_ITS_RESET_MSK_POS (8UL)
78+
#define PSA_ITS_RESET_MSK (1UL << PSA_ITS_RESET_MSK_POS)
79+
80+
/*************************** Test Partitions **********************************/
81+
#ifdef USE_PSA_TEST_PARTITIONS
82+
83+
#ifdef USE_CRYPTO_ACL_TEST
84+
/* -----------------------------------------------------------------------------
85+
* CRYPTO_ACL_TEST Signals
86+
* -------------------------------------------------------------------------- */
87+
#define CRYPTO_GENERATE_KEY_MSK_POS (4UL)
88+
#define CRYPTO_GENERATE_KEY_MSK (1UL << CRYPTO_GENERATE_KEY_MSK_POS)
89+
#define CRYPTO_OPEN_KEY_MSK_POS (5UL)
90+
#define CRYPTO_OPEN_KEY_MSK (1UL << CRYPTO_OPEN_KEY_MSK_POS)
91+
#define CRYPTO_CLOSE_KEY_MSK_POS (6UL)
92+
#define CRYPTO_CLOSE_KEY_MSK (1UL << CRYPTO_CLOSE_KEY_MSK_POS)
93+
#define CRYPTO_DESTROY_KEY_MSK_POS (7UL)
94+
#define CRYPTO_DESTROY_KEY_MSK (1UL << CRYPTO_DESTROY_KEY_MSK_POS)
95+
#define CRYPTO_GET_KEY_ATTRIBUTES_MSK_POS (8UL)
96+
#define CRYPTO_GET_KEY_ATTRIBUTES_MSK (1UL << CRYPTO_GET_KEY_ATTRIBUTES_MSK_POS)
97+
#define CRYPTO_IMPORT_KEY_MSK_POS (9UL)
98+
#define CRYPTO_IMPORT_KEY_MSK (1UL << CRYPTO_IMPORT_KEY_MSK_POS)
99+
#endif // USE_CRYPTO_ACL_TEST
100+
101+
#ifdef USE_CLIENT_TESTS_PART1
102+
/* -----------------------------------------------------------------------------
103+
* CLIENT_TESTS_PART1 Signals
104+
* -------------------------------------------------------------------------- */
105+
#define PART1_ROT_SRV1_MSK_POS (4UL)
106+
#define PART1_ROT_SRV1_MSK (1UL << PART1_ROT_SRV1_MSK_POS)
107+
#define DROP_CONN_MSK_POS (5UL)
108+
#define DROP_CONN_MSK (1UL << DROP_CONN_MSK_POS)
109+
#define SECURE_CLIENTS_ONLY_MSK_POS (6UL)
110+
#define SECURE_CLIENTS_ONLY_MSK (1UL << SECURE_CLIENTS_ONLY_MSK_POS)
111+
#endif // USE_CLIENT_TESTS_PART1
112+
113+
#ifdef USE_SERVER_TESTS_PART1
114+
/* -----------------------------------------------------------------------------
115+
* SERVER_TESTS_PART1 Signals
116+
* -------------------------------------------------------------------------- */
117+
#define CONTROL_MSK_POS (4UL)
118+
#define CONTROL_MSK (1UL << CONTROL_MSK_POS)
119+
#define TEST_MSK_POS (5UL)
120+
#define TEST_MSK (1UL << TEST_MSK_POS)
121+
#endif // USE_SERVER_TESTS_PART1
122+
123+
#ifdef USE_SERVER_TESTS_PART2
124+
/* -----------------------------------------------------------------------------
125+
* SERVER_TESTS_PART2 Signals
126+
* -------------------------------------------------------------------------- */
127+
#define ROT_SRV_REVERSE_MSK_POS (4UL)
128+
#define ROT_SRV_REVERSE_MSK (1UL << ROT_SRV_REVERSE_MSK_POS)
129+
#define ROT_SRV_DB_TST_MSK_POS (5UL)
130+
#define ROT_SRV_DB_TST_MSK (1UL << ROT_SRV_DB_TST_MSK_POS)
131+
#endif // USE_SERVER_TESTS_PART2
132+
133+
#ifdef USE_SMOKE_TESTS_PART1
134+
/* -----------------------------------------------------------------------------
135+
* SMOKE_TESTS_PART1 Signals
136+
* -------------------------------------------------------------------------- */
137+
#define ROT_SRV1_MSK_POS (4UL)
138+
#define ROT_SRV1_MSK (1UL << ROT_SRV1_MSK_POS)
139+
#endif // USE_SMOKE_TESTS_PART1
140+
141+
#endif // USE_PSA_TEST_PARTITIONS
142+
143+
#endif // __TFM_SPM_SIGNAL_DEFS_H__
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
/* Copyright (c) 2019 ARM Limited
2+
*
3+
* SPDX-License-Identifier: Apache-2.0
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+
* !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
20+
* THIS FILE IS AN AUTO-GENERATED FILE - DO NOT MODIFY IT.
21+
* !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
22+
* Template Version 1.0
23+
* Generated by tools/psa/generate_partition_code.py Version 1.1
24+
******************************************************************************/
25+
26+
/****************** Service Partitions ****************************************/
27+
28+
/* -----------------------------------------------------------------------------
29+
* ATTEST_SRV Service IDs
30+
* -------------------------------------------------------------------------- */
31+
32+
#define PSA_ATTEST_GET_TOKEN_ID 0x00000F10
33+
#define PSA_ATTEST_GET_TOKEN_SIZE_ID 0x00000F11
34+
#define PSA_ATTEST_INJECT_KEY_ID 0x00000F12
35+
36+
/* -----------------------------------------------------------------------------
37+
* CRYPTO_SRV Service IDs
38+
* -------------------------------------------------------------------------- */
39+
40+
#define PSA_CRYPTO_INIT_ID 0x00000F00
41+
#define PSA_MAC_ID 0x00000F01
42+
#define PSA_HASH_ID 0x00000F02
43+
#define PSA_ASYMMETRIC_ID 0x00000F03
44+
#define PSA_SYMMETRIC_ID 0x00000F04
45+
#define PSA_AEAD_ID 0x00000F05
46+
#define PSA_KEY_MNG_ID 0x00000F06
47+
#define PSA_RNG_ID 0x00000F07
48+
#define PSA_CRYPTO_FREE_ID 0x00000F08
49+
#define PSA_KEY_DERIVATION_ID 0x00000F09
50+
#define PSA_ENTROPY_ID 0x00000F0A
51+
52+
/* -----------------------------------------------------------------------------
53+
* PLATFORM Service IDs
54+
* -------------------------------------------------------------------------- */
55+
56+
#define PSA_PLATFORM_LC_GET 0x00011000
57+
#define PSA_PLATFORM_LC_SET 0x00011001
58+
#define PSA_PLATFORM_SYSTEM_RESET 0x00011002
59+
60+
/* -----------------------------------------------------------------------------
61+
* ITS Service IDs
62+
* -------------------------------------------------------------------------- */
63+
64+
#define PSA_ITS_GET 0x00011A00
65+
#define PSA_ITS_SET 0x00011A01
66+
#define PSA_ITS_INFO 0x00011A02
67+
#define PSA_ITS_REMOVE 0x00011A03
68+
#define PSA_ITS_RESET 0x00011A04
69+
70+
/****************** Test Partitions *******************************************/
71+
72+
/* -----------------------------------------------------------------------------
73+
* CRYPTO_ACL_TEST Service IDs
74+
* -------------------------------------------------------------------------- */
75+
76+
#define CRYPTO_GENERATE_KEY 0x00000201
77+
#define CRYPTO_OPEN_KEY 0x00000202
78+
#define CRYPTO_CLOSE_KEY 0x00000203
79+
#define CRYPTO_DESTROY_KEY 0x00000205
80+
#define CRYPTO_GET_KEY_ATTRIBUTES 0x00000206
81+
#define CRYPTO_IMPORT_KEY 0x00000208
82+
83+
/* -----------------------------------------------------------------------------
84+
* CLIENT_TESTS_PART1 Service IDs
85+
* -------------------------------------------------------------------------- */
86+
87+
#define CLIENT_TESTS_PART1_ROT_SRV1 0x00001A05
88+
#define CLIENT_TESTS_PART1_DROP_CONN 0x00001A06
89+
#define CLIENT_TESTS_PART1_SECURE_CLIENTS_ONLY 0x00001A07
90+
91+
/* -----------------------------------------------------------------------------
92+
* SERVER_TESTS_PART1 Service IDs
93+
* -------------------------------------------------------------------------- */
94+
95+
#define SERVER_TESTS_PART1_CONTROL 0x00001A01
96+
#define SERVER_TESTS_PART1_TEST 0x00001A02
97+
98+
/* -----------------------------------------------------------------------------
99+
* SERVER_TESTS_PART2 Service IDs
100+
* -------------------------------------------------------------------------- */
101+
102+
#define SERVER_TESTS_PART2_ROT_SRV_REVERSE 0x00001A03
103+
#define SERVER_TESTS_PART2_ROT_SRV_DB_TST 0x00001A04
104+
105+
/* -----------------------------------------------------------------------------
106+
* SMOKE_TESTS_PART1 Service IDs
107+
* -------------------------------------------------------------------------- */
108+
109+
#define SMOKE_TESTS_PART1_ROT_SRV1 0x00001A00
110+

0 commit comments

Comments
 (0)