Skip to content
Snippets Groups Projects
Verified Commit e990df75 authored by schneider's avatar schneider Committed by rahix
Browse files

fix(ble): Remove obsolete stuff from fit example

parent b3eec4e7
No related branches found
No related tags found
No related merge requests found
......@@ -179,9 +179,9 @@ uint8_t appNumConns(uint8_t role)
* \return None.
*/
/*************************************************************************************************/
void AppHandlerInit(wsfHandlerId_t handlerId)
void AppInit(void)
{
appHandlerId = handlerId;
appHandlerId = WsfOsSetNextHandler(AppHandler);
AppDbInit();
}
......
......@@ -45,7 +45,8 @@ static wsfBufPoolDesc_t mainPoolDesc[WSF_BUF_POOLS] =
};
/*! \brief Stack initialization for app. */
extern void StackInitFit(void);
extern void StackInit(void);
extern void AppInit(void);
/*************************************************************************************************/
void PalSysAssertTrap(void)
......@@ -316,12 +317,14 @@ void ble_uart_write(uint8_t *pValue, uint8_t len)
static void ble_init(void)
{
WsfInit();
StackInitFit();
StackInit();
setAddress();
NVIC_SetPriority(BTLE_SFD_TO_IRQn, 2);
NVIC_SetPriority(BTLE_TX_DONE_IRQn, 2);
NVIC_SetPriority(BTLE_RX_RCVD_IRQn, 2);
FitStart();
AppInit();
BleStart();
/* Add the UART service dynamically */
AttsDynInit();
......
This diff is collapsed.
......@@ -2,7 +2,7 @@
/*!
* \file
*
* \brief Stack initialization for fit.
* \brief Stack initialization
*
* Copyright (c) 2016-2017 ARM Ltd. All Rights Reserved.
* ARM Ltd. confidential and proprietary.
......@@ -107,7 +107,7 @@ const BbRtCfg_t _bb_cfg = {
* \return None.
*/
/*************************************************************************************************/
void StackInitFit(void)
void StackInit(void)
{
wsfHandlerId_t handlerId;
......@@ -134,8 +134,8 @@ void StackInitFit(void)
#endif /* DATS_APP_USE_LEGACY_API */
if(memUsed != LL_MEMORY_FOOTPRINT)
{
printf("Controller memory mismatch 0x%x != 0x%x\n", memUsed,
LL_MEMORY_FOOTPRINT);
printf("Controller memory mismatch 0x%x != 0x%x\n", (unsigned int)memUsed,
(unsigned int)LL_MEMORY_FOOTPRINT);
}
#endif
......@@ -180,11 +180,7 @@ void StackInitFit(void)
SmpHandlerInit(handlerId);
SmprInit();
SmprScInit();
HciSetMaxRxAclLen(100);
/* card10:
* Here it gets weird: application logic and stack are
* mixed a lot. */
handlerId = WsfOsSetNextHandler(AppHandler);
AppHandlerInit(handlerId);
/*TODO card10: Probably want to adjust this */
HciSetMaxRxAclLen(100);
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment