aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2010-04-06 08:14:08 +0000
committerDean Camera <dean@fourwalledcubicle.com>2010-04-06 08:14:08 +0000
commitc77f136661ae0fa779c02ef6efeab95aa4b92068 (patch)
treef01814bcc62d2498f733bc954c364283c0b721aa /Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
parentb9c7d196152652df918a822522061c3fe193d273 (diff)
downloadlufa-c77f136661ae0fa779c02ef6efeab95aa4b92068.tar.gz
lufa-c77f136661ae0fa779c02ef6efeab95aa4b92068.tar.bz2
lufa-c77f136661ae0fa779c02ef6efeab95aa4b92068.zip
Add bidirectional channel configuration -- remote device is not ACKing sent Configuration Requests, needs further debugging. Implement Bluetooth spec's channel states.
Use abbreviations for the structure and function names where possible to try to cut down on the code verbosity.
Diffstat (limited to 'Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c')
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
index 5ed120a62..fbacc2537 100644
--- a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
+++ b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
@@ -247,11 +247,12 @@ void Bluetooth_DisconnectionComplete(void)
void Bluetooth_PacketReceived(uint16_t* PacketLength, Bluetooth_Channel_t* Channel)
{
uint8_t DataPayload[*PacketLength];
+
Pipe_Read_Stream_LE(&DataPayload, *PacketLength);
*PacketLength = 0;
- BT_ACL_DEBUG("-- Data Payload: ", NULL);
- for (uint16_t B = 0; B < sizeof(DataPayload); B++)
- printf("0x%02X ", DataPayload[B]);
- printf("\r\n");
+ printf_P(PSTR("L2CAP Packet Recetion on channel %02X:\r\n"), Channel->LocalNumber);
+ for (uint16_t Byte = 0; Byte < *PacketLength; Byte++)
+ printf_P(PSTR("0x%02X "), DataPayload[Byte]);
+ puts_P(PSTR("\r\n"));
}