Skip to content

Commit

Permalink
Merge branch 'master' into iso-doc
Browse files Browse the repository at this point in the history
  • Loading branch information
wpiet authored Feb 19, 2024
2 parents 8d6953c + 60aab30 commit a5844f5
Show file tree
Hide file tree
Showing 11 changed files with 117 additions and 113 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build_cc_target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
gcc: ['12.2.Rel1', '11.3.Rel1', '10.3-2021.10', '9-2020-q2', '8-2019-q3']
gcc: ['13.2.Rel1', '12.2.Rel1', '11.3.Rel1', '10.3-2021.10', '9-2020-q2', '8-2019-q3']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: 'stable'
- uses: carlosperate/arm-none-eabi-gcc-action@48db4484a55750df7a0ccca63347fcdea6534d78
- uses: carlosperate/arm-none-eabi-gcc-action@v1.8.1
with:
release: ${{ matrix.gcc }}
- name: Install newt
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/compliance_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,11 @@ jobs:
- name: Install Dependencies
shell: bash
run: |
sudo apt-get update
sudo apt-get install -y libxml2-utils
mkdir repos
git clone --depth=1 https://github.com/apache/mynewt-core repos/apache-mynewt-core
wget https://repository.apache.org/content/repositories/snapshots/org/apache/rat/apache-rat/maven-metadata.xml -O snapshot.xml
SNAPSHOT=`xmllint --xpath "//latest/text()" snapshot.xml`
wget https://repository.apache.org/content/repositories/snapshots/org/apache/rat/apache-rat/$SNAPSHOT/maven-metadata.xml -O version.xml
VERSION=`xmllint --xpath "//snapshotVersion[1]/value/text()" version.xml`
wget https://repository.apache.org/content/repositories/snapshots/org/apache/rat/apache-rat/$SNAPSHOT/apache-rat-$VERSION.jar -O apache-rat.jar
wget https://dlcdn.apache.org//creadur/apache-rat-0.16.1/apache-rat-0.16.1-bin.tar.gz
tar zxf apache-rat-0.16.1-bin.tar.gz apache-rat-0.16.1/apache-rat-0.16.1.jar
mv apache-rat-0.16.1/apache-rat-0.16.1.jar apache-rat.jar
- name: check licensing
shell: bash
run: |
Expand Down
2 changes: 2 additions & 0 deletions babblesim/core/include/core_cm4.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
extern void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority);
extern void NVIC_EnableIRQ(IRQn_Type IRQn);
extern void NVIC_DisableIRQ(IRQn_Type IRQn);
extern void NVIC_SetPendingIRQ(IRQn_Type IRQn);
extern void NVIC_ClearPendingIRQ(IRQn_Type IRQn);

void __WFI(void);

Expand Down
4 changes: 3 additions & 1 deletion babblesim/core/src/main_config.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
uint global_device_nbr;
struct nrf52_bsim_args_t *args;

extern int mynewt_main(int argc, char **argv);

void
bst_tick(bs_time_t time)
{
Expand All @@ -46,7 +48,7 @@ main_clean_up_trace_wrap(void)
return inner_main_clean_up(0);
}

void
int
main(int argc, char** argv)
{
setvbuf(stdout, NULL, _IOLBF, 512);
Expand Down
13 changes: 2 additions & 11 deletions babblesim/edtt/hci_test/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
#include "os/mynewt.h"
#include "ble_hci_edtt.h"

static int
main_fn(int argc, char **argv)
int
mynewt_main(int argc, char **argv)
{
sysinit();

Expand All @@ -34,12 +34,3 @@ main_fn(int argc, char **argv)
}
return 0;
}

int
main(int argc, char **argv)
{
extern void bsim_init(int argc, char** argv, void *main_fn);
bsim_init(argc, argv, main_fn);

return 0;
}
4 changes: 3 additions & 1 deletion babblesim/hw/mcu/nordic/nrf52_bsim/src/hal_timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,9 @@ hal_timer_config(int timer_num, uint32_t freq_hz)
nrf_timer_task_trigger(hwtimer, NRF_TIMER_TASK_CLEAR);

/* Put the timer in timer mode using 32 bits. */
nrf_timer_mode_set(hwtimer, NRF_TIMER_MODE_TIMER);
hwtimer->MODE = (hwtimer->MODE & ~TIMER_MODE_MODE_Msk) |
((NRF_TIMER_MODE_TIMER << TIMER_MODE_MODE_Pos) &
TIMER_MODE_MODE_Msk);
hwtimer->BITMODE = TIMER_BITMODE_BITMODE_32Bit;

/* Set the pre-scalar */
Expand Down
29 changes: 26 additions & 3 deletions nimble/host/include/host/ble_audio_broadcast.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,22 @@
#ifndef H_BLE_AUDIO_BROADCAST_
#define H_BLE_AUDIO_BROADCAST_

/**
* @file ble_audio_broadcast.h
*
* @brief Bluetooth Low Energy Audio Broadcast API
*
* @defgroup bt_le_audio_broadcast Bluetooth LE Audio Broadcast
* @ingroup bt_host
* @{
*/

#include <stdint.h>
#include "host/ble_gap.h"
#include "host/ble_iso.h"
#include "host/ble_audio_common.h"

/** Parameters used for creating BASE configuration. */
struct ble_broadcast_create_params {
/** Broadcast Audio Source Endpoint */
struct ble_audio_base *base;
Expand Down Expand Up @@ -54,6 +65,7 @@ struct ble_broadcast_create_params {
uint16_t svc_data_len;
};

/** Parameters used for updating BASE configuration. */
struct ble_broadcast_update_params {
/** Broadcast name - null terminated.
* Set NULL to not include in advertising
Expand All @@ -73,6 +85,7 @@ struct ble_broadcast_update_params {
uint32_t broadcast_id;
};

/** Function prototype for broadcast destroy callback. */
typedef int ble_audio_broadcast_destroy_fn(struct ble_audio_base *base,
void *args);

Expand Down Expand Up @@ -182,7 +195,7 @@ struct ble_broadcast_subgroup_params {
* structure. Created subgroup extends subgroup list in provided BASE.
* This function increases `num_subgroups` in BASE structure.
*
* @param[in/out] base Pointer to a `ble_audio_base` structure,
* @param[in,out] base Pointer to a `ble_audio_base` structure,
* that will be extended by the new subgroup.
* In case of error, filled out data may be
* erroneous.
Expand Down Expand Up @@ -221,7 +234,7 @@ struct ble_broadcast_bis_params {
* structure. Created BIS extends BIS list in provided subgroup.
* This function increases `bis_cnt` in subgroup structure.
*
* @param[in/out] subgroup Pointer to a updated `ble_audio_big_subgroup`
* @param[in,out] subgroup Pointer to a updated `ble_audio_big_subgroup`
* structure, that will be extended by the new
* BIS. In case of error, filled out data may be
* erroneous.
Expand All @@ -241,5 +254,15 @@ int ble_audio_broadcast_build_bis(struct ble_audio_big_subgroup *subgroup,
const struct ble_broadcast_bis_params
*params);

/**
* Initializes memory for LE Audio Broadcast.
*
* @return 0 on success
*/
int ble_audio_broadcast_init(void);
#endif

/**
* @}
*/

#endif /* H_BLE_AUDIO_BROADCAST_*/
15 changes: 8 additions & 7 deletions nimble/host/include/host/ble_hs_log.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,6 @@
#ifndef H_BLE_HS_LOG_
#define H_BLE_HS_LOG_

#ifndef BLE_NPL_LOG_MODULE
#define BLE_NPL_LOG_MODULE BLE_HS_LOG
#endif

#include <nimble/nimble_npl_log.h>

/**
* @file ble_hs_log.h
*
Expand All @@ -39,6 +33,13 @@
* @{
*/

#ifndef BLE_NPL_LOG_MODULE
/** Defines the logging module for NimBLE Porting Layer (NPL). */
#define BLE_NPL_LOG_MODULE BLE_HS_LOG
#endif

#include <nimble/nimble_npl_log.h>

#ifdef __cplusplus
extern "C" {
#endif
Expand Down Expand Up @@ -103,4 +104,4 @@ void ble_hs_log_flat_buf(const void *data, int len);
* @}
*/

#endif
#endif /* H_BLE_HS_LOG_*/
8 changes: 0 additions & 8 deletions nimble/host/include/host/ble_iso.h
Original file line number Diff line number Diff line change
Expand Up @@ -288,14 +288,6 @@ int ble_iso_create_big(const struct ble_iso_create_big_params *create_params,
*/
int ble_iso_terminate_big(uint8_t big_id);

void
ble_gap_rx_create_big_complete(const struct
ble_hci_ev_le_subev_create_big_complete *ev);
void
ble_gap_rx_terminate_big_complete(const struct
ble_hci_ev_le_subev_terminate_big_complete
*ev);

/**
* Initiates the transmission of isochronous data.
*
Expand Down
30 changes: 19 additions & 11 deletions nimble/host/include/host/ble_uuid.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,8 @@ typedef union {
*
* This macro initializes a 128-bit UUID with the provided value.
*
* @param uuid128 The value of the 128-bit UUID.
* @param ... A sequence of values in little-endian order representing
* the 128-bit UUID.
*
* @return The initialized 128-bit UUID structure.
*/
Expand All @@ -148,7 +149,8 @@ typedef union {
}

/**
* @brief Macro for declaring a pointer to a 16-bit UUID structure initialized with a specific 16-bit UUID value.
* @brief Macro for declaring a pointer to a 16-bit UUID structure initialized
* with a specific 16-bit UUID value.
*
* @param uuid16 The 16-bit UUID value to initialize the structure with.
*
Expand All @@ -158,7 +160,8 @@ typedef union {
((ble_uuid_t *) (&(ble_uuid16_t) BLE_UUID16_INIT(uuid16)))

/**
* @brief Macro for declaring a pointer to a 32-bit UUID structure initialized with a specific 32-bit UUID value.
* @brief Macro for declaring a pointer to a 32-bit UUID structure initialized
* with a specific 32-bit UUID value.
*
* @param uuid32 The 32-bit UUID value to initialize the structure with.
*
Expand All @@ -168,7 +171,8 @@ typedef union {
((ble_uuid_t *) (&(ble_uuid32_t) BLE_UUID32_INIT(uuid32)))

/**
* @brief Macro for declaring a pointer to a 128-bit UUID structure initialized with specific 128-bit UUID values.
* @brief Macro for declaring a pointer to a 128-bit UUID structure initialized
* with specific 128-bit UUID values.
*
* @param uuid128 The 128-bit UUID value to initialize the structure with.
*
Expand All @@ -178,7 +182,8 @@ typedef union {
((ble_uuid_t *) (&(ble_uuid128_t) BLE_UUID128_INIT(uuid128)))

/**
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer to 16-bit UUID structure.
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer
* to 16-bit UUID structure.
*
* @param u Pointer to a `ble_uuid_t` structure.
*
Expand All @@ -188,7 +193,8 @@ typedef union {
((ble_uuid16_t *) (u))

/**
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer to 32-bit UUID structure.
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer
* to 32-bit UUID structure.
*
* @param u Pointer to a `ble_uuid_t` structure.
*
Expand All @@ -198,7 +204,8 @@ typedef union {
((ble_uuid32_t *) (u))

/**
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer to 128-bit UUID structure.
* @brief Macro for casting a pointer to a `ble_uuid_t` structure to a pointer
* to 128-bit UUID structure.
*
* @param u Pointer to a `ble_uuid_t` structure.
*
Expand All @@ -218,8 +225,8 @@ typedef union {
* @param buf The source buffer to parse.
* @param len The size of the buffer, in bytes.
*
* @return 0 on success, BLE_HS_EINVAL if the source buffer does not contain
* a valid UUID.
* @return 0 on success;
* BLE_HS_EINVAL if the source buffer does not contain a valid UUID.
*/
int ble_uuid_init_from_buf(ble_uuid_any_t *uuid, const void *buf, size_t len);

Expand All @@ -228,7 +235,8 @@ int ble_uuid_init_from_buf(ble_uuid_any_t *uuid, const void *buf, size_t len);
* @param uuid1 The first UUID to compare.
* @param uuid2 The second UUID to compare.
*
* @return 0 if the two UUIDs are equal, nonzero if the UUIDs differ.
* @return 0 if the two UUIDs are equal;
* nonzero if the UUIDs differ.
*/
int ble_uuid_cmp(const ble_uuid_t *uuid1, const ble_uuid_t *uuid2);

Expand Down Expand Up @@ -289,4 +297,4 @@ uint16_t ble_uuid_u16(const ble_uuid_t *uuid);
* @}
*/

#endif /* _BLE_HOST_UUID_H */
#endif /* H_BLE_UUID_ */
Loading

0 comments on commit a5844f5

Please sign in to comment.