Commit Graph

59 Commits

Author SHA1 Message Date
Jérôme Duval 2dc495dc53 bluetooth: remove DEBUG definition. 2016-06-05 18:55:44 +02:00
Augustin Cavalier 5559d51db7 bluetooth_server: Nuke the weird logging system, just use macros...
... just like everything else on Haiku does. Permanently enabled for the
time being. At least I can tell what's going on now.
2016-05-07 21:10:34 -04:00
Alexander von Gluck IV c58e1d7feb l2cap: Fix x86_64 build and refactor trace 2016-04-10 00:49:32 -05:00
Alexander von Gluck IV 1f2fa6cd09 bluetooth: Refactor debugging and trace calls
* The old debug system was too complex and made
  troubleshooring difficult. (it also was unique
  like a snowflake... which we don't want)
* Move to the classic TRACE / ERROR a large majority
  of the code has changed to.
* I like trace statements, but drop some obvious ones
* Fix style issues along the way
2016-04-09 23:40:54 -05:00
Adrien Destugues a5a3b2d9a3 Bluetooth: fix thread safety issue.
Fixes #11428.
2016-02-14 14:07:21 +01:00
Alexander von Gluck IV a8f9011015 h2: Fix bluetooth driver build, missing PrivateKernelHeaders
* We likely should move all of this stuff to normal
  atomic test and set operations at some point.
2014-05-18 22:33:56 -05:00
Fredrik Modéen 34dad10384 Adding debug file to bluetooth.
* more changes will come.
2013-01-12 20:01:28 +01:00
Fredrik Modéen 7a74a5df45 WIP... Updating Bluetooth.
* Some bugfixes.
* added scan mode read.
* inactivated some printout for now. Was a lot of noice in terminal
2012-08-27 19:23:22 +00:00
Oliver Tappe 269ebc04b9 Fix #6373, second try
* make BDADDR_* macros refer to value types instead of addresses
* adjust all interfaces using bdaddr_t* to use (mostly const) refs instead,
  which IMHO makes the interface & code clearer
* that got rid of a couple of const incorrectness casts
* some cleanup along the way


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38265 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-08-19 15:29:02 +00:00
Oliver Tappe 32a2294fdc * revert r38213, as it introduces initialization problems
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38263 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-08-19 14:40:17 +00:00
Oliver Tappe e0ef64750f * fix #6373 by switching the BD... macros to take the address of corresponding
constants, which had to be defined in several places in order to be available
  in the kernel addons, network protocols and the server/kit.
* enable -Werror for all servers

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38213 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-08-17 21:46:32 +00:00
Oliver Ruiz Dorantes a5bf12376d *Incorrect endianess handling from bdaddr at parsing from string.
*Remove bluetooth_util deprecated header
*Issue conn_req for socket connect() call



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37132 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-06-14 20:04:10 +00:00
Artur Wyszynski 49a0c7942f Fixed build with GCC4
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36454 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-24 17:51:39 +00:00
Oliver Ruiz Dorantes 40c666a5ab - Introduce template methods for single or non parameter commands
- Remove some old legacy command creation functions



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36444 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-24 11:16:49 +00:00
Oliver Ruiz Dorantes 4d291edb32 Â- Use given macro for system team, thanks Jerome
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36028 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-02 13:37:16 +00:00
Oliver Ruiz Dorantes 2e26da485a - In the case the port is created in Kernel context force it to stay in kernel team,
as the creation can be initated by a UL thread



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36025 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-02 11:31:39 +00:00
Oliver Ruiz Dorantes 9760dcae20 - Move bluetooth net_device module to a independent module HCI, remake API interfaces
- Move functionality for assembling ACL/events packets of the driver to this module
- Move h2generic driver to c++ (not style)
- Pass checkstyle.py to all commited files.
Fixes:
- Wrong condition for finishing l2cap packet segmentation.
- Place NetBuffersPrependers in a inner scope to avoid Sycing twice in destructor.
- Avoid keeping trace of l2cap responses of any other kind of thread.
- Do not free net_buffers of for Frame containers.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35117 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 15:46:36 +00:00
Oliver Ruiz Dorantes ee01456254 - Add macros to distingish between requests and responses
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34999 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-10 23:02:21 +00:00
Oliver Ruiz Dorantes deac8b50fa - sizeof(TYPE) would cause problems to instantiations of the class with void type
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34883 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-03 22:35:18 +00:00
Oliver Ruiz Dorantes 23992a691c - Port & Thread string's name allocation was messed and used in InitCheck.
- Style, spacing binary operator



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34881 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-03 21:30:26 +00:00
Oliver Ruiz Dorantes d923116745 Fix mask and endline style
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34880 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-03 21:19:47 +00:00
Oliver Ruiz Dorantes 31f8763031 - Proper implementation of accept/bind l2cap socket interface
- Add more debug info for the KDL debug command
- Request channel pointer also for non l2cap signal frames
- Add locks for packet queues



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34333 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-28 20:03:15 +00:00
Oliver Ruiz Dorantes b2ebb71755 File not yet ready, revert
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34025 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-13 22:09:00 +00:00
Oliver Ruiz Dorantes 02d67528b5 Add class to handle all code values to be sent in the ports
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34024 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-13 22:03:33 +00:00
Oliver Ruiz Dorantes 515209e338 Merge view class in the window object
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33471 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-06 20:03:36 +00:00
Adrien Destugues 875e7244d7 Patch by Michael Weirauch to fix bluetooth apps signatures.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33270 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-09-24 21:07:18 +00:00
Oliver Ruiz Dorantes a53e31dde4 - Use Layout manager
- Styling


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32870 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-31 19:21:50 +00:00
Oliver Ruiz Dorantes d1966ec2c2 - Implement Trigger method to allow buffers
- Identation, 80/90, tabs & whitespaces



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32788 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-28 17:17:52 +00:00
Oliver Ruiz Dorantes 111d946099 - Patch by Michael Weirauch, Finally a deskbar addon for bluetooth
- Functionality to stop services, start preferences, and show debug console
- Cleanups in signatures

-This line, and those below, will be ignored--

M    headers/private/bluetooth/bluetoothserver_p.h
M    src/servers/bluetooth/BluetoothServer.h
A    src/servers/bluetooth/DeskbarReplicant.cpp
A    src/servers/bluetooth/DeskbarReplicant.h
M    src/servers/bluetooth/Jamfile
M    src/servers/bluetooth/BluetoothServer.cpp
M    src/preferences/bluetooth/BluetoothMain.cpp
M    src/preferences/bluetooth/Jamfile
M    src/preferences/bluetooth/defs.h
M    src/preferences/bluetooth/BluetoothWindow.cpp


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31508 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-10 15:12:51 +00:00
Oliver Ruiz Dorantes ddac407426 - Add initial code to unregister devices from server
- Handle Hardware error event
- Add function to retrieve an string from a bluetooth error
- Styling



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31376 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-02 20:07:26 +00:00
Jérôme Duval 581708b997 * fix the build by moving a typedef to public scope, and avoid returning a value in the destructor
* some clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31025 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-13 10:42:11 +00:00
Oliver Ruiz Dorantes 80ee40e10c License header & style
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31016 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-12 18:25:57 +00:00
Oliver Ruiz Dorantes c6083519e7 Make a bit more elegant the processing of bluetooth events
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31015 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-12 18:14:51 +00:00
Oliver Ruiz Dorantes dd5df90570 - Remove size output parameter creating commands
- Add support for reading the size of internals buffers of the bt chips
- Add support for Resetting the Device
- Add broadcom vendor command fro writting the bdaddr
- clean up the debug output



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29669 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-23 23:07:07 +00:00
Oliver Ruiz Dorantes 3fdaa5bf72 - Drop R5 compatibility by removing first 4 bytes in the IOCTLs containing the size of the command.
- Implement mechanism GetProperty to retrieve detailed information about the LocalDevice
- Generic BluetoothDevice interface changed and adapted
- Implement ReadLocalVersion to be aware of the bluetooth specification supported by our localdevice



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29639 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-21 21:38:00 +00:00
Oliver Ruiz Dorantes bd88ac9707 - Move and implement some helper functions to a non private header(revision version etc)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29637 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-21 21:18:51 +00:00
Oliver Ruiz Dorantes a7c3c46562 - Created an experimental(more c++ & templatized) way to create bluetooth commands
- Add strings for all bluetooth manufacturers
- Add a bunch of strings for each command
- Add methods to get string given a manufacturer code or a command code



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29526 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-14 17:54:42 +00:00
Oliver Ruiz Dorantes b44ee58331 Add creation of local version infomation command
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29475 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-11 21:43:01 +00:00
Michael Lotz 7ac433fc8c Fix deprecated include.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29110 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-01 17:29:42 +00:00
Oliver Ruiz Dorantes a2f8edf787 Add HCI command for retieving Local Device Class
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28808 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-12-13 23:24:11 +00:00
Oliver Ruiz Dorantes fbbf64a410 Remove dedicated implementation of GetAddress and GetName in server side.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28784 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-12-08 22:49:20 +00:00
Oliver Ruiz Dorantes b3256174a6 Change module name
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28727 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-11-25 18:22:25 +00:00
Oliver Ruiz Dorantes 25f31b227e - Allow the header being used from C code
- Minor Styling



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28717 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-11-22 10:49:40 +00:00
Oliver Ruiz Dorantes 7a3a199ad5 Add flags to handle the status of the configuration of the channel
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28716 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-11-22 10:30:38 +00:00
Oliver Ruiz Dorantes 9e6975723d Header for a common kernel module to handle all BT Stack data structures. Its sources can wait...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28108 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-14 20:50:44 +00:00
Oliver Ruiz Dorantes 2c6619e446 Styling and define module path outside the driver
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28105 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-14 20:28:22 +00:00
Oliver Ruiz Dorantes 696b8e46f3 Move header to private, is meant to be used by acl component as well
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26903 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-08-09 20:47:30 +00:00
Oliver Ruiz Dorantes 3205e523cd Implement pairing with a remote bluetooth device
- Fix PincodeWindow to send the pincode commands dissapear after clicking 
- Improve the debug output of bluetooth_server
- Handle all needed events for the pairing
- Simple request could send and receive the event before adding the request to the events wanted list. Inverted the order of this sequence.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26614 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 20:50:49 +00:00
Oliver Ruiz Dorantes 6e82afcc18 -Update copyright
-whitespaces cleanups 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26452 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:30:45 +00:00
Oliver Ruiz Dorantes 7434b76048 Add to the command manager the connection accept and reject commands
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26451 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:25:44 +00:00