mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-10 15:44:32 +00:00
moved hexdump to hci.c, use hci_send_packet, cleanups
This commit is contained in:
parent
93b8dc03ca
commit
56fe0872e0
19
src/hci.c
19
src/hci.c
@ -8,6 +8,7 @@
|
||||
#include <unistd.h>
|
||||
#include <stdarg.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include "hci.h"
|
||||
|
||||
|
||||
@ -22,6 +23,22 @@ hci_cmd_t hci_reset = {
|
||||
|
||||
static hci_transport_t *hci_transport;
|
||||
|
||||
void hexdump(uint8_t *data, int size){
|
||||
int i;
|
||||
for (i=0; i<size;i++){
|
||||
printf("%02X ", data[i]);
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
#if 0
|
||||
static void *hci_daemon_thread(void *arg){
|
||||
printf("HCI Daemon started\n");
|
||||
hci_run(transport, &config);
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
void hci_init(hci_transport_t *transport, void *config){
|
||||
|
||||
// reference to use transport layer implementation
|
||||
@ -40,7 +57,7 @@ int hci_power_control(HCI_POWER_MODE power_mode){
|
||||
return 0;
|
||||
}
|
||||
|
||||
int hci_send_cmd(uint8_t *buffer, int size){
|
||||
int hci_send_cmd_packet(uint8_t *buffer, int size){
|
||||
return hci_transport->send_cmd_packet(buffer, size);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user