Skip to content

Commit 6bcffbd

Browse files
committed
clean up warnings
1 parent 452db14 commit 6bcffbd

File tree

5 files changed

+9
-4
lines changed

5 files changed

+9
-4
lines changed

cores/nRF5/utility/debug.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ void dbgDumpMemoryCFormat(const char* str, void const *buf, uint16_t count)
262262
buf8++;
263263
}
264264

265-
printf("\n\};\n");
265+
printf("\n};\n");
266266
}
267267

268268

libraries/Bluefruit52Lib/src/BLEAdvertising.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ bool BLEAdvertising::_start(uint16_t interval, uint16_t timeout)
346346
},
347347
.p_peer_addr = NULL , // Undirected advertisement
348348
.interval = interval , // advertising interval (in units of 0.625 ms)
349-
.duration = timeout*100 , // in 10-ms unit
349+
.duration = (uint16_t) (timeout*100), // in 10-ms unit
350350

351351
.max_adv_evts = 0, // TODO can be used for fast/slow mode
352352
.channel_mask = { 0, 0, 0, 0, 0 } , // 40 channel, set 1 to disable

libraries/Bluefruit52Lib/src/BLEDiscovery.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,10 @@ uint8_t BLEDiscovery::discoverCharacteristic(uint16_t conn_handle, BLEClientChar
144144
// only discover CCCD descriptor
145145
if (disc_chr->chars[d].char_props.notify || disc_chr->chars[d].char_props.indicate )
146146
{
147-
ble_gattc_handle_range_t range = { disc_chr->chars[d].handle_value + 1, _hdl_range.end_handle };
147+
ble_gattc_handle_range_t range = {
148+
.start_handle = (uint16_t) (disc_chr->chars[d].handle_value + 1),
149+
.end_handle = _hdl_range.end_handle
150+
};
148151

149152
if ( range.start_handle <= range.end_handle )
150153
{

libraries/InternalFileSytem/src/flash/flash_cache.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
* THE SOFTWARE.
2323
*/
2424

25+
#include <string.h>
2526
#include "flash_cache.h"
2627
#include "common_func.h"
2728
#include "variant.h"
@@ -124,6 +125,6 @@ void flash_cache_read (flash_cache_t* fc, void* dst, uint32_t addr, uint32_t cou
124125
}
125126
else
126127
{
127-
fc->read(dst, (void*) addr, count);
128+
fc->read(dst, addr, count);
128129
}
129130
}

libraries/InternalFileSytem/src/flash/flash_nrf5x.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include "flash_cache.h"
2727
#include "nrf_sdm.h"
2828
#include "nrf_soc.h"
29+
#include "delay.h"
2930
#include "rtos.h"
3031

3132
//--------------------------------------------------------------------+

0 commit comments

Comments
 (0)