From 06abcc1ed29eb7d04932e5a0c8b573e8a730f63f Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Tue, 19 Feb 2019 14:34:12 +0100 Subject: [PATCH] stm32-f4discovery-cc256x: print local bd addr on start --- port/stm32-f4discovery-cc256x/src/port.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/port/stm32-f4discovery-cc256x/src/port.c b/port/stm32-f4discovery-cc256x/src/port.c index 1ee6a414f..2768bf680 100644 --- a/port/stm32-f4discovery-cc256x/src/port.c +++ b/port/stm32-f4discovery-cc256x/src/port.c @@ -266,11 +266,13 @@ int _fstat(int file){ static void packet_handler (uint8_t packet_type, uint16_t channel, uint8_t *packet, uint16_t size){ UNUSED(size); UNUSED(channel); + bd_addr_t local_addr; if (packet_type != HCI_EVENT_PACKET) return; switch(hci_event_packet_get_type(packet)){ case BTSTACK_EVENT_STATE: if (btstack_event_state_get_state(packet) != HCI_STATE_WORKING) return; - printf("BTstack up and running.\n"); + gap_local_bd_addr(local_addr); + printf("BTstack up and running on %s.\n", bd_addr_to_str(local_addr)); break; case HCI_EVENT_COMMAND_COMPLETE: if (HCI_EVENT_IS_COMMAND_COMPLETE(packet, hci_read_local_version_information)){