mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-20 18:40:31 +00:00
ports: disable hci dump in all ports
This commit is contained in:
parent
beb3c81d4f
commit
98451c7b10
@ -131,7 +131,7 @@ static void packet_handler (uint8_t packet_type, uint16_t channel, uint8_t *pack
|
||||
|
||||
static void btstack_setup(void){
|
||||
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
|
||||
/// GET STARTED with BTstack ///
|
||||
btstack_memory_init();
|
||||
|
@ -234,7 +234,7 @@ void BTSTACK_Initialize ( void )
|
||||
btstack_memory_init();
|
||||
btstack_run_loop_init(btstack_run_loop_embedded_get_instance());
|
||||
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
|
||||
// setup uart driver
|
||||
const btstack_uart_block_t * uart_block_driver = btstack_uart_block_embedded_instance();
|
||||
|
@ -147,7 +147,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// setup run loop
|
||||
|
@ -197,7 +197,7 @@ int main(int argc, const char * argv[]){
|
||||
}
|
||||
strcat(pklg_path, ".pklg");
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
|
||||
// setup USB Transport
|
||||
transport = hci_transport_usb_instance();
|
||||
|
@ -221,7 +221,7 @@ int main(int argc, const char * argv[]){
|
||||
}
|
||||
strcat(pklg_path, ".pklg");
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
|
||||
// init HCI
|
||||
hci_init(hci_transport_usb_instance(), NULL);
|
||||
|
@ -274,7 +274,7 @@ void main(void)
|
||||
btstack_run_loop_init(btstack_run_loop_zephyr_get_instance());
|
||||
|
||||
// enable full log output while porting
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
|
||||
// init HCI
|
||||
hci_init(transport_get_instance(), NULL);
|
||||
|
@ -585,7 +585,7 @@ int main(void)
|
||||
hci_init(&hci_transport, NULL);
|
||||
|
||||
// enable full log output while porting
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
|
||||
// hand over to btstack embedded code
|
||||
btstack_main();
|
||||
|
@ -170,7 +170,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port and configure uart block driver
|
||||
|
@ -165,7 +165,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port and configure uart block driver
|
||||
|
@ -165,7 +165,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port and configure uart block driver
|
||||
|
@ -141,7 +141,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port
|
||||
|
@ -242,7 +242,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port
|
||||
|
@ -204,7 +204,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port
|
||||
|
@ -302,7 +302,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "/tmp/hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// setup run loop
|
||||
|
@ -117,7 +117,7 @@ void btstack_port(void){
|
||||
hci_init(hci_transport, NULL);
|
||||
|
||||
// enable full log output while porting
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
|
||||
// hand over to btstack embedded code
|
||||
btstack_main();
|
||||
|
@ -582,7 +582,7 @@ void port_thread(void* args){
|
||||
|
||||
// enable packet logger
|
||||
#ifdef ENABLE_HCI_DUMP
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
// hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
#endif
|
||||
/// GET STARTED with BTstack ///
|
||||
btstack_memory_init();
|
||||
|
@ -164,7 +164,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port and configure uart block driver
|
||||
|
@ -143,7 +143,7 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
const char * pklg_path = "hci_dump.pklg";
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
|
||||
// pick serial port
|
||||
|
@ -226,7 +226,7 @@ int main(int argc, const char * argv[]){
|
||||
btstack_memory_init();
|
||||
btstack_run_loop_init(btstack_run_loop_windows_get_instance());
|
||||
|
||||
hci_dump_open("hci_dump.pklg", HCI_DUMP_PACKETLOGGER);
|
||||
// hci_dump_open("hci_dump.pklg", HCI_DUMP_PACKETLOGGER);
|
||||
|
||||
// pick serial port
|
||||
config.device_name = "\\\\.\\COM7";
|
||||
|
@ -152,27 +152,6 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
printf("BTstack/windows-winusb booting up\n");
|
||||
|
||||
#if 0
|
||||
int usb_path_len = 0;
|
||||
uint8_t usb_path[USB_MAX_PATH_LEN];
|
||||
if (argc >= 3 && strcmp(argv[1], "-u") == 0){
|
||||
// parse command line options for "-u 11:22:33"
|
||||
const char * port_str = argv[2];
|
||||
printf("Specified USB Path: ");
|
||||
while (1){
|
||||
char * delimiter;
|
||||
int port = strtol(port_str, &delimiter, 16);
|
||||
usb_path[usb_path_len] = port;
|
||||
usb_path_len++;
|
||||
printf("%02x ", port);
|
||||
if (!delimiter) break;
|
||||
if (*delimiter != ':' && *delimiter != '-') break;
|
||||
port_str = delimiter+1;
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
/// GET STARTED with BTstack ///
|
||||
btstack_memory_init();
|
||||
btstack_run_loop_init(btstack_run_loop_windows_get_instance());
|
||||
@ -183,21 +162,11 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
|
||||
#if 1
|
||||
char pklg_path[100];
|
||||
strcpy(pklg_path, "hci_dump");
|
||||
#if 0
|
||||
if (usb_path_len){
|
||||
strcat(pklg_path, "_");
|
||||
strcat(pklg_path, argv[2]);
|
||||
}
|
||||
#endif
|
||||
strcat(pklg_path, ".pklg");
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
#else
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
#endif
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
|
||||
// handle CTRL-c
|
||||
signal(SIGINT, sigint_handler);
|
||||
|
@ -124,52 +124,15 @@ int main(int argc, const char * argv[]){
|
||||
|
||||
printf("BTstack/windows-winusb booting up\n");
|
||||
|
||||
#if 0
|
||||
int usb_path_len = 0;
|
||||
uint8_t usb_path[USB_MAX_PATH_LEN];
|
||||
if (argc >= 3 && strcmp(argv[1], "-u") == 0){
|
||||
// parse command line options for "-u 11:22:33"
|
||||
const char * port_str = argv[2];
|
||||
printf("Specified USB Path: ");
|
||||
while (1){
|
||||
char * delimiter;
|
||||
int port = strtol(port_str, &delimiter, 16);
|
||||
usb_path[usb_path_len] = port;
|
||||
usb_path_len++;
|
||||
printf("%02x ", port);
|
||||
if (!delimiter) break;
|
||||
if (*delimiter != ':' && *delimiter != '-') break;
|
||||
port_str = delimiter+1;
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
/// GET STARTED with BTstack ///
|
||||
btstack_memory_init();
|
||||
btstack_run_loop_init(btstack_run_loop_windows_get_instance());
|
||||
|
||||
// if (usb_path_len){
|
||||
// hci_transport_usb_set_path(usb_path_len, usb_path);
|
||||
// }
|
||||
|
||||
// use logger: format HCI_DUMP_PACKETLOGGER, HCI_DUMP_BLUEZ or HCI_DUMP_STDOUT
|
||||
|
||||
#if 1
|
||||
char pklg_path[100];
|
||||
strcpy(pklg_path, "hci_dump");
|
||||
#if 0
|
||||
if (usb_path_len){
|
||||
strcat(pklg_path, "_");
|
||||
strcat(pklg_path, argv[2]);
|
||||
}
|
||||
#endif
|
||||
strcat(pklg_path, ".pklg");
|
||||
printf("Packet Log: %s\n", pklg_path);
|
||||
hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
#else
|
||||
hci_dump_open(NULL, HCI_DUMP_STDOUT);
|
||||
#endif
|
||||
// hci_dump_open(pklg_path, HCI_DUMP_PACKETLOGGER);
|
||||
|
||||
// init HCI
|
||||
hci_init(hci_transport_usb_instance(), NULL);
|
||||
|
Loading…
x
Reference in New Issue
Block a user