You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ry...@apache.org on 2020/08/03 07:52:04 UTC
[mynewt-nimble] branch master updated (aa2267a -> a7e3f7c)
This is an automated email from the ASF dual-hosted git repository.
rymek pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git.
from aa2267a apps/blestress - compilation error Building the app returned error: multiple definition of `stress_timer_callout'. Moving the it's declaration to stress.c fixes the issue - this structure is only used there.
new bf931d5 apps/blestress - switch from PSM = 1 to PSM = 0x80 (128) - from dynamic range
new 205e253 apps/blestress - remove extra SDU lenght info removed appending length of pattern data, as that is performed either way by functions called by l2cap API
new a7e3f7c apps/blestress - change pattern data offset to 0 in stress_fill_mbuf_with_pattern() filling mbuf should begin at start of pattern buffer, as the full length of that buffer if being copied
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
apps/blestress/src/rx_stress.c | 10 +---------
apps/blestress/src/stress.c | 4 ++--
apps/blestress/src/stress.h | 2 ++
apps/blestress/src/tx_stress.c | 2 +-
4 files changed, 6 insertions(+), 12 deletions(-)
[mynewt-nimble] 03/03: apps/blestress - change pattern data offset
to 0 in stress_fill_mbuf_with_pattern() filling mbuf should begin at start
of pattern buffer, as the full length of that buffer if being copied
Posted by ry...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rymek pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit a7e3f7cadee00dad2dd24d461033c336f529e3cf
Author: Krzysztof Kopyściński <kr...@codecoup.pl>
AuthorDate: Fri Jul 31 07:59:04 2020 +0200
apps/blestress - change pattern data offset to 0
in stress_fill_mbuf_with_pattern() filling mbuf should begin at start of
pattern buffer, as the full length of that buffer if being copied
---
apps/blestress/src/stress.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/apps/blestress/src/stress.c b/apps/blestress/src/stress.c
index 0bed576..1bdbafa 100644
--- a/apps/blestress/src/stress.c
+++ b/apps/blestress/src/stress.c
@@ -121,7 +121,7 @@ stress_fill_mbuf_with_pattern(struct os_mbuf *om, uint16_t len)
rest = len % STRESS_PAT_LEN;
for (i = 0; i < mul; ++i) {
- rc = os_mbuf_append(om, &test_6_pattern[29], STRESS_PAT_LEN);
+ rc = os_mbuf_append(om, &test_6_pattern[0], STRESS_PAT_LEN);
if (rc) {
os_mbuf_free_chain(om);
@@ -129,7 +129,7 @@ stress_fill_mbuf_with_pattern(struct os_mbuf *om, uint16_t len)
}
}
- rc = os_mbuf_append(om, &test_6_pattern[29], rest);
+ rc = os_mbuf_append(om, &test_6_pattern[0], rest);
if (rc) {
os_mbuf_free_chain(om);
[mynewt-nimble] 01/03: apps/blestress - switch from PSM = 1 to PSM
= 0x80 (128) - from dynamic range
Posted by ry...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rymek pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit bf931d5ee65520c9a69256d711466b210f276a8d
Author: Krzysztof Kopyściński <kr...@codecoup.pl>
AuthorDate: Fri Jul 31 07:56:12 2020 +0200
apps/blestress - switch from PSM = 1 to PSM = 0x80 (128) - from dynamic range
---
apps/blestress/src/rx_stress.c | 2 +-
apps/blestress/src/stress.h | 2 ++
apps/blestress/src/tx_stress.c | 2 +-
3 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/apps/blestress/src/rx_stress.c b/apps/blestress/src/rx_stress.c
index a4253ce..5b91e4d 100644
--- a/apps/blestress/src/rx_stress.c
+++ b/apps/blestress/src/rx_stress.c
@@ -1365,7 +1365,7 @@ rx_stress_start(int test_num)
break;
case 10:
console_printf("Stress L2CAP send\033[0m\n");
- rc = ble_l2cap_create_server(1, STRESS_COC_MTU,
+ rc = ble_l2cap_create_server(TEST_PSM, STRESS_COC_MTU,
rx_stress_10_l2cap_event, NULL);
assert(rc == 0);
rx_stress_simple_adv(&rx_stress_adv_sets[10]);
diff --git a/apps/blestress/src/stress.h b/apps/blestress/src/stress.h
index 6f19331..db4fbb3 100644
--- a/apps/blestress/src/stress.h
+++ b/apps/blestress/src/stress.h
@@ -44,6 +44,8 @@ extern "C" {
#define STRESS_FIND_SRV 1
#define STRESS_FIND_CHR 2
#define STRESS_FIND_DSC 3
+/* L2CAP PSM */
+#define TEST_PSM 0x80
struct stress_gatt_search_ctx;
typedef void stress_gatt_disc_end_fn(struct stress_gatt_search_ctx *search_ctx);
diff --git a/apps/blestress/src/tx_stress.c b/apps/blestress/src/tx_stress.c
index 1e62491..4416c56 100644
--- a/apps/blestress/src/tx_stress.c
+++ b/apps/blestress/src/tx_stress.c
@@ -1127,7 +1127,7 @@ tx_stress_10_gap_event(struct ble_gap_event *event, void *arg)
assert(sdu_rx != NULL);
tx_stress_ctx->conn_handle = event->connect.conn_handle;
- rc = ble_l2cap_connect(event->connect.conn_handle, 1,
+ rc = ble_l2cap_connect(event->connect.conn_handle, TEST_PSM,
STRESS_COC_MTU, sdu_rx,
tx_stress_10_l2cap_event, NULL);
assert(rc == 0);
[mynewt-nimble] 02/03: apps/blestress - remove extra SDU lenght
info removed appending length of pattern data,
as that is performed either way by functions called by l2cap API
Posted by ry...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rymek pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit 205e253200aaad67141d05eebc32fa1447991371
Author: Krzysztof Kopyściński <kr...@codecoup.pl>
AuthorDate: Fri Jul 31 07:57:15 2020 +0200
apps/blestress - remove extra SDU lenght info
removed appending length of pattern data, as that is performed either way
by functions called by l2cap API
---
apps/blestress/src/rx_stress.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/apps/blestress/src/rx_stress.c b/apps/blestress/src/rx_stress.c
index 5b91e4d..d9ba980 100644
--- a/apps/blestress/src/rx_stress.c
+++ b/apps/blestress/src/rx_stress.c
@@ -837,14 +837,6 @@ rx_stress_10_l2cap_event(struct ble_l2cap_event *event, void *arg)
MODLOG_DFLT(INFO, "Data buf %s\n", data_buf ? "OK" : "NOK");
assert(data_buf != NULL);
- /* The first 2 bytes of data is the size of appended pattern data. */
- rc = os_mbuf_append(data_buf, (uint8_t[]) {data_len >> 8, data_len},
- 2);
- if (rc) {
- os_mbuf_free_chain(data_buf);
- assert(0);
- }
-
/* Fill mbuf with the pattern */
stress_fill_mbuf_with_pattern(data_buf, data_len);