WO2001061936A2 - Bluetooth baseband solution with reduced processor requirements and integrated host controller - Google Patents

Bluetooth baseband solution with reduced processor requirements and integrated host controller Download PDF

Info

Publication number
WO2001061936A2
WO2001061936A2 PCT/US2001/005064 US0105064W WO0161936A2 WO 2001061936 A2 WO2001061936 A2 WO 2001061936A2 US 0105064 W US0105064 W US 0105064W WO 0161936 A2 WO0161936 A2 WO 0161936A2
Authority
WO
WIPO (PCT)
Prior art keywords
packet
bluetooth
fragment
packets
l2cap
Prior art date
Application number
PCT/US2001/005064
Other languages
French (fr)
Other versions
WO2001061936A9 (en
WO2001061936A3 (en
Inventor
Theodore Trost
Brima Ibrahim
Alan Mikhak
Original Assignee
Broadcom Corporation
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Broadcom Corporation filed Critical Broadcom Corporation
Priority to DE60138456T priority Critical patent/DE60138456D1/en
Priority to EP01910848A priority patent/EP1257919B1/en
Priority to AU2001238411A priority patent/AU2001238411A1/en
Priority to AT01910848T priority patent/ATE429677T1/en
Publication of WO2001061936A2 publication Critical patent/WO2001061936A2/en
Publication of WO2001061936A3 publication Critical patent/WO2001061936A3/en
Publication of WO2001061936A9 publication Critical patent/WO2001061936A9/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W28/00Network traffic management; Network resource management
    • H04W28/02Traffic management, e.g. flow control or congestion control
    • H04W28/06Optimizing the usage of the radio link, e.g. header compression, information sizing, discarding information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/40Network security protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72409User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories
    • H04M1/72412User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories using two-way short-range wireless interfaces
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/725Cordless telephones
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/12Protocol engines
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/30Definitions, standards or architectural aspects of layered protocol stacks
    • H04L69/32Architecture of open systems interconnection [OSI] 7-layer type protocol stacks, e.g. the interfaces between the data link level and the physical level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/02Details of telephonic subscriber devices including a Bluetooth interface
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/18Self-organising networks, e.g. ad-hoc networks or sensor networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/02Terminal devices

Definitions

  • the present invention relates to Bluetooth wireless communication circuits, and in particular embodiments to reducing Bluetooth processor requirements by incorporating common processor functions within dedicated hardware circuitry.
  • Bluetooth refers to an open specification describing a technology which enables short range wireless data and voice communication.
  • Bluetooth is an open specification produced by the Bluetooth special interest Group (SIG) and is available from Bluetooth.com. This specification is incorporated by reference as though set forth in full.
  • SIG Bluetooth special interest Group
  • a wireless communication device comprising a wireless transceiver and a processor coupled to the wireless transceiver.
  • the processor has a memory comprising a plurality of fragments and an array configured to control the sequence of memory fragments from which the data is read.
  • a processor having memory which is comprised of a variety of fragments is disclosed. Additionally, the processor includes an array configured to control the sequence of memory fragments from which the data is read.
  • Figure 1 is a graphical representation of an example Bluetooth environment.
  • Figure 2A is a graphical illustration of the high-level functional composition of a
  • Figure 2B is a graphical illustration of protocols within the Bluetooth system illustrated in Figure 2A.
  • Figure 2C is a generalized graphical representation of a Bluetooth device having a host interface.
  • Figure 3 is a graphical representation of the topology of a basic Bluetooth network.
  • Figure 4 is a graphical illustration of a scatternet Bluetooth network.
  • Figure 5 is a graphical illustration of Bluetooth clock timing.
  • Figure 6 is a graphical illustration of the slot timing of SCO data packets.
  • Figure 7 is a graphical illustration representing pathways for various data packets within the layering of the Bluetooth protocol.
  • Figure 8 is a graphical illustration of a protocol layering diagram of a Bluetooth device coupled to a computer via a USB (Universal Serial Bus).
  • USB Universal Serial Bus
  • Figure 9 is a graphical illustration of the six transmit and receive FIFO (First In First Out) structures within the physical layer, according to an embodiment of the invention.
  • FIFO First In First Out
  • Figure 10 is a graphical representation of a transmit FIFO and ancillary structures according to an embodiment of the invention.
  • Figure 11 is a graphical illustration of the organization of data within a fragment.
  • Figure 12 is a graphical illustration of a firmware packet comprising multiple fragments.
  • Figure 13 is a graphical illustration showing the layering and packets within a host and
  • Bluetooth device illustrating layers added according to the embodiment of the invention.
  • Figure 14 is a graphical illustration of the packet structure of the added layers below the HCl layer, according to an embodiment of the invention.
  • Figure 15 is a graphical illustration of an embodiment of the invention.
  • Figure 16 is a block diagram of an exemplary baseband implementation, according to an embodiment of the invention.
  • Figure 17 is a block diagram of a Bluetooth integrated circuit, according to an embodiment of the invention.
  • Figure 18 is a graphical illustration of piconet traffic on a single piconet, which has an
  • Figure 19A a is graphical illustration of unsynchronized piconets.
  • Figure 19B is a graphical illustration of the timing of the "Slot Gauge.”
  • Figure 20 is a table relating the number of bytes to be transmitted to the packet type priority.
  • Figure 21 is a schematic diagram of a fragment chooser circuit that accepts protect bits and produces the index of the lowest unoccupied fragment.
  • Figure 22 is a schematic diagram used to provide a modulo divide of the 27 bit Bluetooth clock by "T", an 8 bit number, according to an embodiment of the invention.
  • Figure 23 is a graphical illustration of the computational values generated in an exemplary 115,307,261 mod 135.
  • Figure 24 is a graphical illustration of the operation of an automatic transmit FIFO according to an embodiment of the invention.
  • Figure 25 is a flow diagram of the Byte Gauge process.
  • Figure 16 is a flow diagram illustrating the L2CAP packet flush state machine, according to an embodiment of the invention.
  • FIG. 27 is a flow diagram of an L2CAP packet transmit state machine, according to an embodiment of the invention.
  • embodiments of the present invention relate, generally, to wireless communication systems.
  • the embodiments are described herein with relation to Bluetooth networks .
  • the described exemplary embodiments disclosed herein are directed to Bluetooth networks, there is no intent to limit the invention to the example embodiments.
  • the exemplary embodiments are intended to illustrate inventive aspects of the present invention, which are applicable to a wide variety of electronic systems.
  • Figure 1 is a graphical representation of an exemplary Bluetooth environment.
  • a Personal Digital Assistant (PDA) 103 is coupled to a Bluetooth wireless transceiver 105 A.
  • a fax machine 107 is coupled to a Bluetooth wireless transceiver 105B.
  • Atelephone 109 is coupled to a Bluetooth wireless transceiver 105C.
  • a telephone network, represented by telephone wall plug 111 is coupled to a Bluetooth wireless transceiver 105D.
  • a printer 113 is coupled to a Bluetooth wireless transceiver 105E.
  • a computer is coupled to a Bluetooth transceiver 105F.
  • a keyboard is coupled to a Bluetooth transceiver 105G.
  • Figure 2 A is a graphical illustration of the high-level functional composition of a
  • the Bluetooth device 203 may communicate with a Bluetooth device 203.
  • a host I/O (input/output) and link manager functions 209 communicate with a application 207, which is running in the host.
  • the host I/O and link manager 209 communicates the higher layers and applications 207 within the host.
  • the host I/O and link manager 209 communicates with the link controller 211 which controls the flow of data between the applications 207 and a Bluetooth radio 213.
  • the link controller 211 accepts data from the Bluetooth radio 213 and provides'the data to the host I/O and link manager for communication across the host I/O to the higher layers and application module
  • the link controller 211 controls the data flow to the Bluetooth radio module 213.
  • the Bluetooth radio module accepts communications from and provides communications to an antenna 215, which in turn provides an over the air RF (Radio Frequency) link.
  • FIG. 2B is a graphical illustration of protocols within the Bluetooth system of Figure 2A.
  • L2CAP Logical Link Control and Adaptation Protocol
  • the L2CAP layer 229 is a software component that provides a standard interface for the transfer and reception of control and application data to and from a Bluetooth device 235.
  • the L2CAP layer 229 in turn communicates with a HCl (host controller interface), which forms the interface between the L2CAP layer 229 and various physical interfaces 233.
  • the various physical interfaces 223 may comprise, for example, RS-232 ports, USB (universal serial bus) ports, a UART (Universal Asynchronous Receiver Transmitter), or other physical interfaces.
  • the HCl (Host Communications Interface) layer 231 comprises an HCl communications protocol from the host controller 237 within the Bluetooth module 235 to the host.
  • the host controller 237 and link manager 239 are a further illustration of the functions within the host I/O and link manager 209 of Figure 2A.
  • the link controller 241 is the functional equivalent of the link controller 211 of Figure 2A.
  • the Bluetooth radio 243 as well as the Bluetooth antenna 223 are also functionally equivalent to the corresponding modules of Figure 2 A.
  • FIG. 2C is a more detailed graphical representation of an example Bluetooth device having a host interface.
  • the applications 253 communicate to an HCl (host controller interface) driver 261 through protocols 255 and 257.
  • Protocol 257 is the previously mentioned L2CAP protocol layer.
  • the L2CAP protocol layer deals with the transport of L2CAP data packets.
  • the SCO (synchronous connection) layer 255 manages the transport of isochronous data, such as voice communications, between applications 253 and the HCl driver 261.
  • Each of the protocol layers, the SCO layer 255 and the L2CAP layer 257 provide layers for the purpose of communicating with applications 253 in a standardized way.
  • the HCl driver 261 provides a standard interface between the SCO layer 255 and the L2CAP layer 257 and the HCl driver layer 261.
  • the HCl driver 261 communicates data to the HCl transport layer 263.
  • the HCl transport layer 263 provides for the transport of data across whatever physical interface 251 is present.
  • the physical interface 251 may comprise a variety of interfaces for example USB, UART (Universal Asynchronous Receiver/Transmitter) or RS- 232.
  • the host controller 265 provides HCl transport layer services the host controller and link manager interface with the baseband link controller 267.
  • Baseband link controller 267 controls the flow of data to and from the Bluetooth Radio 269.
  • Figure 3 is a graphical representation of the topography of a basic Bluetooth network.
  • a master device 303 may have up to 7 slaves, for example slave devices 305, 307 and 309. Each slave can have at most one master at any given time but may have different masters at different times. Each master can have up to seven slaves at any given time.
  • An anangement of Bluetooth devices 301 such as depicted in Figure 3 is called a piconet.
  • a characteristic of a piconet is that all of the devices in a piconet are synchronized to the master' s clock.
  • a master 303 establishes a connection to a slave, for example slave 305, 307 or 309, the slave device synchronizes to the master clock.
  • the master device itself can be a slave to another master as illustrated in Figure 4.
  • Figure 4 is a graphical illustration of a scatternet type Bluetooth type network.
  • a scatternet has more than one master device and accordingly more than one master clock.
  • master device 405 is the master device for slave devices 409, 411 and 413.
  • master 405 is a slave device to master 403.
  • a master may share slaves on a time division basis. For example, a master 405 may control a slave 413 for a first time period. During a second time period master 407 may control slave 413, as well as controlling slave 415.
  • master 405 may have to have several clocks running concurrently. For example, master 405 may establish connection with slave devices 409 and 411 thus causing the clocks within slaves devices 409 and 41 1 to synchronize with master 405. Master 403 may then establish a connection to device 405.
  • Device 405 is a slave device to master 403 and hence must synchronize a clock to the master clock in master device 403 , for the purposes of communicating with master device 403.
  • device 405 will have a master clock, which will be used to communicate with slaves 409 and 411.
  • Device 405 must also synchronize, as a slave, to master device 403 and so must also have a copy of device 403 's clock.
  • a shared slave device 413 when communicating with master 405 slave 413 will synchronize to master 405's clock.
  • slave 413 When slave 413 is communicating with master device 407 it will synchronize to master device 407's clock.
  • FIG. 5 is a graphical illustration of Bluetooth clock timing. Every Bluetooth device has a native free-running 28-bit Bluetooth clock. The native Bluetooth clock ticks once every 312.5 microseconds. Two ticks of a native Bluetooth 312.5 microsecond clock form a transmission unit known as a slot, which is the basic Bluetooth transmission unit. Each transmission slot is 625 microseconds wide; accordingly the slot clock has aperiod of 625 microseconds.
  • Bluetooth networks are set up such that at any given time one device is transmitting and one device is listening. Generally when a transmission is directed to a device, the device must reply to the transmitting device in the next slot after the transmission. Master devices, however, also have a broadcast mode, which enables a master to transmit to all of its slaves.
  • All of the master' s slaves will listen to decode such a transmission. In the case of a broadcast to all slaves, no reply from the slaves is required. A master device will start transmission only during even slots. The slave, receiving the master's transmission will then reply during the next odd slot after the master's transmission. This arrangement is illustrated in Figure 5.
  • master transmission 503 occurs during even slot 501.
  • the slave listening to the transmission will then reply in slot 502.
  • Each transmission comprises a data packet.
  • a data packet can be 1 , 3 or 5 slots in length.
  • a master's transmission must always begin and end on an even slot thereby enabling the slave to answer during an odd slot.
  • a transmission packet broadcast, such as 505 occupies 3 slots and a transmission packet broadcast such as 507 occupies 5 slots.
  • Bluetooth networks are frequency hopping systems. That is the broadcast frequency changes after every packet transmission. So for example if a master broadcast on slot 503 using frequency F n then the slave would reply on slot 502 using frequency F n+1 . If the master subsequently broadcasts a three slot packet 505, the broadcast would be on frequency F n+2 . Frequency F n+2 would be maintained for all three slots of the broadcast 505. In multi-slot packets the broadcast frequency does not change. Accordingly in a five slot packet 507 the frequency of broadcast would remain consistent during all five slots.
  • Each packet transmission has an address within it so that each slave knows when it is being addressed.
  • Each packet has, in addition to an address, some flow control information as well as information designating what type of packet is being sent.
  • the address includes 3 bits thus allowing an individual address for each one of the seven slaves and a separate address for broadcast mode to all the slaves. Slaves may be allowed to us one, three or five slots in responding to the master.
  • Bluetooth packets There are several classifications for Bluetooth packets.
  • a first classification distinguishes between uncoded and coded packet types. Coded packet types have forward error correction (FEC) included whereas uncoded packets types do not. Packets may also be classified by length as one slot, three slot and five slot packets.
  • FEC forward error correction
  • Packets may also be classified by length as one slot, three slot and five slot packets.
  • ACL asynchronous connection link
  • ACL asynchronous connection link
  • Bluetooth uses a repeat request scheme in which ACL packets are transmitted and retransmitted until the destination indicates successful reception by returning an acknowledgment.
  • An unnumbered acknowledgment scheme is used, in which the previously received packet is acl ⁇ io wledged or not. Acknowledgment is indicated when the ARQN bit in the Bluetooth packet header is set to " 1 " (ACK). When the ARQN bit in the Bluetooth packet header is set to "0", a NAK (Not Acknowledged) is indicated.
  • SCO synchronous connection oriented
  • SCO packets are used, for example, for voice data transfer between two devices.
  • SCO packets are characterized in that they reserve periodic transmission (and reception) slots on a Bluetooth communication channel.
  • Such a connection is known as a isochronous connection.
  • SCO packet links can be established only after an ACL link has first been established.
  • FIG. 6 is a graphical illustration of the slot timing of different versions of SCO packets.
  • Two different parameters generally define the SCO packet type.
  • the first SCO parameter, T describes the periodicity of SCO transmissions many slots a packet will encompass. T may be 2, 4 or 6.
  • a second SCO parameter D is used to define the offset of the SCO transmission within period T. If T equals 2 a transmission occurs every second slot. If T equals 4 a transmission occurs every fourth slot and if T is 6 a transmission occurs every sixth slot.
  • a first transmission 603 is followed by a receive 605 in a successive slot.
  • the receive 605 is then followed by a transmit 607 in a successive slot and the transmit 607 is followed by a receive in a successive 609.
  • This version of SCO packet is known as a HV1 packet.
  • HV1 packets have forward enor correction added, such that the packets are rate 1/3. That is 3 bits are transmitted to send 1 bit of data.
  • the additional 2 bits transmitted comprise forward error correcting (FEC) coding.
  • FEC forward error correcting
  • HV2 packets are illustrated at 611 in Figure 6.
  • a first transmit packet 613 is followed by a receive packet 615.
  • Two slots are then skipped and the second HV2 is transmitted at 617 followed by a receive at 619.
  • Two packets are then skipped and another transmission begins.
  • HV2 packets have forward error conection coding such that the rate of the code is 2/3. That is each 3 bits transmitted comprise 2 bits of data.
  • HN3 packets are illustrated at 621 in Figure 6. A first transmission 623 occurs followed by a reply 625. Four packets are then skipped and then a second transmission 627 occurs followed by reply 629.
  • HV3 type packets contain no forward error correcting codes so that each bit transmitted represents one bit of data. All three packets HV1, HV2 and HV3 transmit at the same data rate. The amount of forward error conecting and coding within each packet varies, and hence the total number of bits transmitted varies.
  • a third category of packet is the LMP (link manager protocol) packet.
  • LMP packets are ACL type packets, which are sent to manage the connection link between devices rather than transfer data. LMP packets are always one slot packets. ACL packets are given Bluetooth designations according to their length and the enor coding present.
  • a DM1 packet is a one slot ACL packet having forward error conecting coding.
  • a DH1 packet is a one slot ACL packet having no error correcting coding.
  • a DM3 packet is a three slot ACL packet having error correcting coding.
  • a DH3 packet is a three slot ACL packet having no enor correcting coding.
  • a DM5 packet is a five slot ACL packet having error correcting coding.
  • a DH5 packet is a five slot ACL packet having no error correcting coding. LMP packets are always sent using DM1 packets.
  • FIG. 7 is a graphical illustration representing the path of various data packets within the layering of the Bluetooth protocol.
  • the L2CAP layer 703 is generally considered the highest layer within the Bluetooth protocol.
  • the L2CAP layer is typically implemented within a host 715.
  • the HCl layer 709 which communicates with the L2CAP layer 703 through a HCl layer
  • the HCl layer 709 is usually implemented within the Bluetooth device and in the host. Part of the HCl layer 709 within the Bluetooth device is commonly implemented within firmware. The HCl layer 709 is coupled to the physical layer 707. ACL type packets travel back and forth between the L2CAP layer 703, the HCl 709 and the physical layer 707. The physical layer 707 forms the various packet types such as DM1, DH1, HV1, etc. The physical layer 707 provides functions such as encryption, whitening, and encoding. L2CAP packets, which may be up to 64 KB (kilobytes) in length, are communicated to the HCl 709 layer, along which then reformats the L2CAP packets into HCl packets.
  • the HCl layer 709 takes the HCl packets and puts them into a form that is compatible with the physical layer 707.
  • the SCO packets typically have their own path between the physical layer 707 and a transmission mechanism such as a codec 713. SCO packets, however, may also go from the physical layer through the HCl layer 709, tlirough the L2CAP layer 703, and subsequently to the host 715.
  • LMP packets are coupled between a link manager 705 and the physical layer 707.
  • the link manager 705 is used to negotiate packet types between Bluetooth devices, as well as to setup encryption.
  • the link manager 705 is also used for setting up SCO links and for other link management functions
  • Figure 8 is a graphical illustration representing protocol layering, as might be found within a Bluetooth device coupled to a personal computer (PC) via a USB (Universal Serial Bus).
  • the L2CAP protocol 803 will is executing in the PC.
  • the L2CAP protocol 803 communicates with a host controller interface (HCl) 805.
  • Host controller interface 805 will then communicate with a USB module 807.
  • Bluetooth device is then coupled via USB layer 809 to the USB layer 807 within the computer.
  • the USB within the Bluetooth device 809 then communicates with the host controller interface (HCl) 811, which in turn communicates with the physical layer 813 in the Bluetooth device.
  • the HCl layer which typically exists in a firmware implementation
  • the burden on the processor which ordinarily executes the HCl firmware in the HCl layer, is thereby lessened by converting the typical firmware implementation into a hardware implementation,.
  • the data packet flow between the L2CAP layer 803 and the physical layer 813 will be converted from a typical firmware implementation into a hardware implementation.
  • FIFO structures within the physical layer which accommodate the transmission of data packets
  • three FIFOs within the physical layer which accommodate the reception of data packets.
  • Figure 9 is a graphical illustration of six transmit and receive FIFO structures within the physical layer.
  • three FIFO structures accommodate the transmission of packets.
  • the L2CAP transmit FIFO structure 903 accommodates the transmission of L2CAP type packets.
  • the SCO transmit FIFO structure 907 accommodates the transmission of SCO type packets.
  • the LMP transmit FIFO structure 911 accommodates the transmission of LMP type packets.
  • L2CAP receive FIFO sfructure 905 accommodates the reception of L2CAP type packets.
  • the SCO receive FIFO structure 909 accommodates the reception of SCO type packets.
  • the LMP receive FIFO structure 913 accommodates the reception of LMP type packets.
  • firmware will no longer be used to access the L2CAP transmit FIFO. Instead the L2CAP transmit FIFO will be controlled by HCl hardware. By removing the FIFO management functions from the HCl firmware a significant burden is removed from the HCl firmware processor thus enabling the HCl firmware processor to accomplish other tasks, or alternatively allowing a less powerful HCl firmware processor to be used.
  • the term L2CAP FIFO is somewhat misleading.
  • the L2CAP transmit memory will be refened to as the L2CAP FIFO. Additionally, examples which apply to any of the transmit FIFOs will be refened to simply as transmit FIFOs.
  • the SCO FIFO like the L2CAP FIFO may be implemented as a fragmented memory.
  • the SCO packets may be accommodated by the same FIFO as the L2CAP packets, or the SCO packets may be accommodated by a different FIFO also with a fragmented structure.
  • the present embodiment includes an L2CAP transmit FIFO. Details of the transmit FIFO are the same whether the transmit FIFO is used to transmit S CO packets, L2C AP packets or both.
  • transmit FIFOs may manage multiple connections.
  • implementations may split their transmit FIFO into multiple FIFOs. For Example one for each device. This expedient of splitting the transmit FIFO into multiple FIFOs can make it easier to manage the individual
  • the drawback occurs because the physical layer and the L2CAP layer have a high level data flow control mechanism.
  • the L2CAP layer communicates to be physical layer how much memory is available in the host device.
  • the physical layer in turn communicates in turn to the L2CAP layer how much memory is available in the physical layer.
  • the L2CAP layer can also moderate the data flow from the physical layer depending on how much memory is available in the L2CAP layer.
  • Total memory may not be representative of what level of data flow the physical layer can accommodate because one or more of the transmit FIFOs may be nearly full and the other FIFOs may be nearly empty.
  • the amount of memory does not reflect the moderation of data flow needed to accommodate the nearly full transmit FIFO. Therefore, if one transmit FIFO is used per connection, the transmit FIFO management is simplified but the data flow management between the physical layer and the L2CAP layer is made substantially more complicated. Accordingly, pooling the memory in a memory management type fashion has significant advantages when used in concert with the Bluetooth messaging mechanism that reports the amount of memory available between the physical and L2CAP layers.
  • FIG 10 is a graphical representation of a transmit FIFO and ancillary structures according to an embodiment of the invention.
  • the transmit FIFO 1001 is ananged in a series of fragments.
  • 128 fragments of 64 bytes each are used.
  • the size of the fragments, as well as the number of fragments are dictated by the requirements of individual implementations.
  • the present embodiment utilizes 128 fragments of 64 bytes each, other implementations might find other fragment sizes and number of fragments convenient.
  • Protect bit anay 1011 is used to indicate whether a corresponding fragment is in use or empty. Accordingly, there are 128 bits within the protect bit anay 1011, each corresponding to a fragment within the transmit FIFO. So for example if fragment 0 is in use protect bit anay bit 1013 is set to 1. If fragment 5 is not in use then protect bit anay bit 1015 is set to 0 indicating that fragment 5 is empty. Additionally, a read and write pointer, which points into the transmit array, is used with each connection. Therefore, 10 sets of read pointers and write pointers indicate the points where reading and writing from the transmit FIFO are taking place. Seven sets for slave devices 1 set for a connection to another master 1 set for broadcasts to active slaves and 1 set for broadcast to all slaves.
  • the linked list comprises an 128 element array of 7 bit values. Within each element of the array is the number of the next sequential fragment to be transmitted. Therefore, if a single connection used fragment 0, fragment 2, fragment 4 and fragment 7 of the transmit array, the linked list would have a value of 2 in the 0 field. The 2 in the 0'th field of the linked list indicates that the next fragment to be transmitted after fragment 0 would be fragment 2.
  • linked list element 2 will have a value of 4 written into its second element indicating that the next fragment to be transmitted after fragment 2 is fragment 4.
  • Array element 4 will have written a value of 7 into that anay element indicating that after fragment 4, fragment 7 is to be transmitted.
  • 1005 is an anay of 10 base pointers and 1006 is an array of 10 forward pointers, both of which are used to read data from the transmit FIFO 1001.
  • 1007 is an anay of 10 write pointers used to write data into the transmit FIFO 1007.
  • Figure 11 is a graphical illustration of the format of data within a fragment.
  • Each fragment 1101 has a header at byte 0 of the fragment.
  • the fragment header are three fields.
  • the first field 1103 is a 1 bit field designated FF for first fragment.
  • the first fragment field indicates whether the fragment is the first fragment of a firmware packet (Illustrated in Figure 12).
  • the second field within the fragment header is the LF or last fragment field 1105.
  • the last fragment field 1105 indicates whether the cunent fragment is the last fragment within a firmware packet.
  • the remaining field, within byte 0 of the fragment header, is the length field 1107.
  • the length field 1107 is 6 bits in length and indicates the number of bytes used within the fragment.
  • the first fragment of a transition packet also has two more fields located within byte 1 of that fragment.
  • the first field is the L_CH field 1109 indicating if the present packet, coincides with the beginning of an L2CAP packet.
  • the L_CH field is 2 bits in length with a " 10" indicating that the data within the fragment is actually the beginning of an L2CAP packet.
  • a L_CH value of 01 indicates that the present fragment is a continuation of an L2C AP packet. This identification of the timing of the L2CAP packet is important because it is desirable that the packets going out over the air never straddle an L2CAP boundaiy.
  • a flow bit, illustrated at 1111 is used to control the data flow to the L2C AP layer.
  • the hardware will choose the type of Bluetooth packet to sent.
  • the hardware uses the L_CH field to select a segment of data, to transmit in a Bluetooth packet, that does not straddle an L2CAP boundary.
  • FIG 12 is a graphical illustration of a firmware packet.
  • the firmware packet 1201 comprises a first packet 1209 having a header in byte 0 with a " 1 " bit in the first position 1203 designating that this is the first fragment of a firmware packet and a "0" in header position 1205 indicating that it is not the last fragment of the firmware packet.
  • the remainder of byte 0 comprises a length field which gives the number of bytes used in a fragment.
  • Byte 1 of the first fragment 1209 also has a 2 bit field because it is the first packet of a firmware packet. In the illustrated example the 2 bit field of byte 1 is set to a "10" indicating that this fragment is the beginning of a L2CAP packet.
  • An intermediate fragment 1215 is also illustrated.
  • the intermediate fragment 1215 has a "0" in the first field of the header 1211 and a "0" in the second field of the header 1213 signifying that the present packet 1215 is neither the first or last fragment of the firmware packet 1201.
  • the last fragment of firmware packet 1201 has the first bit of the header 1217 set to a "0" indicating that this is not the first fragment of a packet.
  • the next bit of the header 1219 is set to a " 1 " indicating that fragment 1221 is the last fragment within firmware packet 1201.
  • Figure 13 is a graphical illustration of the layering and packets within the host and embedded software of a Bluetooth device.
  • the upper most layer is the L2CAP layer 1301.
  • An L2CAP packet produced by the L2CAP layer comprises a length field 1303, a channel ID 1305 and a payload 1307.
  • the L2CAP packets are broken down into HCl packets in the HCl layer 1309.
  • the HCl packets have flags to indicate whether they are the beginning of an L2CAP packet 1311 or a continuation of an L2CAP packet 1313.
  • An HCl data payload 1315 will always end concunently with an L2CAP payload 1307 in order to insure that the HCl packet does not straddle an L2CAP boundary.
  • a L2CAP packet always translates into an integer number of HCl packets.
  • the next lower layer 1317 is indicated as a HCI-USB layer in the host.
  • Layer 1317 transfers HCl packets to the USB driver 1321.
  • the USB Driver layer 1321 then converts the HCl packets to USB packets and then transmits the USB packets, e.g. 1323 A and 1325 A, across a physical connection.
  • the physical connection in the present examples indicated as a USB hardware bus, coupled to the Bluetooth device.
  • the USB packets are received in a USB Driver layer.
  • the USB packets are then reassembled into HCl packets 1319B within the Bluetooth device.
  • the HCl packets 1319B will then be formed into the over-the-air packets 1331 which will then be sent out over the Bluetooth radio 1333.
  • An embodiment of the present invention inserts two more layers between the HCl packet 1319B and the over the air packet 1331.
  • the first layer inserted is the layer that takes the HCl packet and forms firmware packet 1327.
  • the second layer is a layer that maps the firmware packets 1327 into fragments 1329 within the transmit FIFO.
  • the hardware will then automatically choose the over-the-air packets 1331 from the transmit FIFO.
  • the fragments belonging to each comiection are treated as contiguous segments except for the marker which shows where the L2CAP boundary is. When an L2CAP boundary is encountered an optimally sized over-the-air packet that does not straddle an L2CAP boundary is selected and sent.
  • Figure 14 is a graphical illustration of the packet structure of the added layers below the HCl layers, according to an embodiment of the invention.
  • the packets from the HCl layer 1403 are formed into firmware packets 1405.
  • the firmware packets are further formed into 64 byte fragments 1407 and 1409 in the transmit FIFO.
  • the fragments such as 1407 and 1409 are then concatenated by the hardware to form the over-the-air packet pay loads 1411.
  • the over-the-air packet payloads 1411 are then incorporated into over-the-air packets 1413.
  • FIG 15 is a graphical illustration of an embodiment of the invention.
  • Bluetooth host 1501 comprises three layers.
  • the first layer 1503 is a higher layer such as the L2CAP layer.
  • the physical bus may be a variety of different type buses such as a USB, PCI bus, or another type of bus.
  • the physical driver 1507 in the Bluetooth host then interfaces with the actual physical bus 1509.
  • the physical bus 1509 is then coupled to the HCl firmware in the Bluetooth baseband device.
  • much of the HCl firmware functionality has been transferred into HCl hardware 1511, different embodiments may choose to keep different functions within the HCl firmware 1513.
  • some residual HCl firmware 1513 may continue to run to interface with the link manager firmware 1515.
  • another aspect of an embodiment of the invention is the ability to switch between hardware and firmware modes of operation.
  • L2CAP data travels from the physical bus hardware 1509 through coupling 1519 into the HCl hardware 1511.
  • the baseband controller block 1517 represents the physical layer.
  • the physical layer couples the data into the Bluetooth RF (radio frequency) 1523, which in turn provides the data to an antenna 1525, which transmits the data over the air.
  • Figure 16 is a high level block diagram of an exemplary baseband implementation.
  • 1603 and 1611 comprise the link manager, which is in firmware.
  • UART and USB 1605 may be firmware drivers handling the USB and UART functions. In certain embodiments of the invention the USB and UART may be done in hardware, UART/USB 1605 might go directly to a UART or USB port without first going through firmware drivers.
  • UART/USB 1605 would comprise physical UART/USB transmit and receive FIFOs.
  • the 1607 is a PCM (Pulse Code Modulation) interface.
  • the PCM interface 1607 may be an interface to a codec for example in order to handle SCO traffic.
  • Paths 1613 and 1623 are used for LMP packet traffic, paths 1615 and 1621 are for L2CAP traffic and paths 1617 and 1619 are for the SCO traffic.
  • the LMP transmit FIFO is illustrated at 1625.
  • the L2CAP transmit FIFO is illustrated at 1627, and the SCO transmit FIFO is illustrated at 1629.
  • the SCO controller 1631 controls the SCO receive and transmit, FIFOs. As well as SCO receive and transmit timing.
  • the SCO receive FIFO is illustrated at 1633
  • the L2C AP receive FIFO is illustrated at 1635 , and the
  • LMP receive FIFO is illustrated at 1637.
  • Audio processor block 1641 handles PCM, Mu-Law and A-Law voice algorithms.
  • the segmented/packet composer/retransmit controllers/flusher block 1639 chooses the packet types to transmit over the air.
  • the SCRF block also segments the data that's in FIFOs 1625, 1627 and 1629.
  • the SCRF block 1639 also handles retransmission in case a transmission is not received properly.
  • the retransmission function is an asynchronous scheme where the receiver will send back an ACK (Acknowledgment) if a transmission has been received properly.
  • ACK Acknowledgment
  • the hardware will automatically flush the data from the transmit FIFO. If a NAK is received in response to a transmission, signifying transmission was not received properly, then the SCRF hardware will automatically handle a . retransmission.
  • the flusher is the portion fo the SCRF module that flushes the data from the TX FIFO.
  • the flushing of data from the transmit module is automatic (discussed in reference to Figure 25), additionally, a firmware function may flush data form the TX (transmit) FIFO.
  • the transmit data path 1645 and receive data path 1649 modules contain DSP functions, such as forward error correction, encoding, decoding, data whitening, and an encryption engine.
  • link control unit 1647 is a state machine which an implementation of the
  • the frequency hopper 1653 - controls the Bluetooth specified frequency hopping sequence.
  • the timing control block 1655 controls the Bluetooth clock.
  • the power manager 1657 shuts off functions when they are not being used.
  • a BlueRF Interface 1651 handles the overall system/radio interface.
  • the flow control 1643 handles the Bluetooth data flow control automatically, which is another hardware function that can be removed from the firmware.
  • FIG. 17 is a block diagram of an integrated circuit according to an embodiment of the invention.
  • the embodiments of the invention are generally contained in the blocks labeled TX (transmit) FIFO 1703 , RX (rece ve) FIFO 1705 and HCl PCM block 1707 within the Bluetooth baseband core 1709.
  • Some embodiments of the present invention relate, in general, to the fact that HCl functionality that is usually handled in firmware will be done in hardware.
  • the data comes from a host and is formatted in HCl packets.
  • the data comes from a host and is formatted in HCl packets.
  • HCl firmware will take the HCl packets and then form firmware packets and then form 64 byte fragments and write them into the appropriate FIFO.
  • the forming of HCl packets into fragments is done in hardware.
  • Hardware receives the HCl packets and then forms the firmware packets and the 64 byte fragment formats itself automatically.
  • a second embodiment of the invention is similar to the first embodiment except that the data flow is in the opposite direction. Instead of taking HCl packets from the host, in the second embodiment, over-the-air packets are received and then HCl packets that will go to the host are formed.
  • hardware automatically transmits HCI_Number_Of_Completed_Packets to the host, these events indicate how much buffer space in the Bluetooth device has been made available by data in the buffer having been transmitted and acknowledged, or otherwise flushed.
  • hardware automatically receives the
  • HCI_Host_Number_Of_Completed_Packets command from the host telling the Bluetooth device how much buffer space in the host has been freed since the last such command, so that the Bluetooth device doesn't send too much data to the host.
  • the first tlirough fourth embodiments are present.
  • the firmware counterparts are present.
  • the functions present in the first through fourth embodiments can be switch between hardware and firmware. Such switching ability may be used by Bluetooth system designers to save power, increase speed or a variety of other reasons.
  • the hardware has the ability to automatically set or clear the standard Bluetooth control flow bits of FLOW, ARQN and SEQN of transmitted Bluetooth packets based on the flow control bits of received packets, on RX FIFO status, and on various error checks in the physical data path such as FEC (Forward Error Correction)and CRC (cyclic redundancy check).
  • FEC Forward Error Correction
  • CRC cyclic redundancy check
  • a seventh embodiment of the invention the ability to automatically choose the Bluetooth packet type and length for transmission is incorporated in the hardware.
  • An advantage of the seventh embodiment is that by pooling the fragments in the memory, if there are less than seven slaves, then the slaves that are present are free to use the whole memory.
  • memory space may be dynamically allocated to each connection according to Bluetooth specified quality of service. For example, a connection may have a parameter indicating the maximum amount of quiet time that is allowed before more data must be sent. Each connection might have a different value for quality of service and accordingly, the proposed FIFO structure allows for variable memory allocation to each connection.
  • the eighth embodiment of the invention the
  • SCO frame are automatically scheduled in hardware.
  • Another advantage of embodiments of the invention is that it makes the calculation of the HCI_Number_Of_Completed_Packet events easier to calculate.
  • the HCl layer tells the host how many HCl packets have been completed (flushed from the transmit FIFO).
  • An embodiment of the invention maps HCl packets to firmware packets one to one. The number of completed HCl packet is equal to the number of flushed firmware packets. Therefore the embodiment need only count firmware packets. As it is flushing fragments from the FIFO to determine the number of completed HCl packets. So now its easy for hardware to inform the HCl layer what free buffer space is available to send packets to the host.
  • the L2CAP and LMP buffers are separated.
  • the LMP buffer is accessed by firmware.
  • the LMP buffer is generally not accessed by hardware.
  • the L2CAP FIFO accesses may be by firmware or hardware depending on which mode the system is operating in. If the HCl is being done in firmware then the firmware will be accessing the L2CAP FIFO and if the HCl function is implemented in hardware, then hardware will be accessing it the L2CAP FIFO. Since LMP lies in firmware, by separating the LMP and L2CAP functions firmware never has to access the L2CAP FIFO. Firmware can access the LMP FIFO whenever necessary.
  • Another advantage in embodiments of the invention is that sometimes it is necessary to flush data from a FIFO. If it was desired to flush an L2CAP packet out of the FIFO but not and LMP packet it would be difficult if both packets were in the same FIFO. In essence, L2CAP packets can be flushed without touching the LMP packets.
  • a slot counter counts in sync with the Bluetooth slot clock.
  • the Bluetooth specification indicates that in order to initialize the slot counter the Bluetooth counter is taken modulo T. Accordingly, whatever the Bluetooth clock is equal, that number is taken modulo 6 and the result is the initial counter value. In the present case if the period is 6 then the Bluetooth clock modulo 6 yields the slot counter value. If the period of the periodic transmission is N, then the Bluetooth clock modulo N is equal to the slot counter.
  • a hardware circuit for computing the value of the Bluetooth clock (or any number) modulo N is described.
  • Bluetooth clock MSB is 0, the modulo calculation proceeds as is and the result is then the slot counter value. So ultimately, a 27 bit value which is the Bluetooth clock with the MSB either inverted or not is taken modulo the period (in the present example 6) and the result is the initial slot counter value.
  • a further embodiment of the invention comprises a circuit and method for providing a modulo divide operation, exemplarily of the Bluetooth clock.
  • Figure 22 is a schematic diagram used to provide a modulo divide of the 27 bit Bluetooth clock by "T", an 8 bit number.
  • the 27 bit T value of the Bluetooth clock is serially shifted into flip-flop 2220 one bit at a time MSB (most significant bit) first.
  • the output of flip flops 2220 through 2128 form a 9 bit bus 2219, with flip flop 2228 comprising the MSB and flip flop 2220 comprising the LSB.
  • the 9 bit value of bus 2219 is provided to the "B" input of comparator 2211.
  • the modulo divisor is provided to the circuit on 8 bit bus 2203.
  • the 8 bit value provided by bus 2203 represents the modulo divide value "T".
  • Figure 23 is a graphical illustration fo the computational values to do an exemplary 115,307,261 mod 135.
  • Value 2303 represents 115,207,261 in binary.
  • Value 2305 represents the value of the dividend 135.
  • the intermediate values represent the outputs of flip flops 2220 tlirough 2228 in Figure 22, the answer is produced at 2311.
  • the modulo divide may be used by Slot Gauge for SCO transmissions or for any other types of periodic transmissions, such as Beacons and Sniffs.
  • Bluetooth mechanism which require regular periodic transmissions. Such as SCOs.
  • Bluetooth has a Beacon which is used when a slave is temporarily put out of action. This mode is called park mode. The master periodically broadcasts a beacon to the parked slaves. The slaves can use the beacon to determine when to wake up.
  • the beacon is analogous to an SCO channel because it broadcasts with a fixed period. Sniff slots are also periodic. So SCO, beacon and sniff are three Bluetooth functions that may use a Slot Gauge circuit having a modulo divide.
  • Beacon and sniff would require 16 bit divisor quantities instead of just 8, which could be accommodated in the circuit of Figure 22 by adding flip flops to the flip flop chain 2220 tlirough 2228 and enlarging the bus paths and circuit elements by 8 bits.
  • the description of the hardware circuits may be implemented in a variety of ways in the present embodiment they were written into Verilog RTL and then the Verilog synthesizer maps them into gates.
  • Ninth embodiment of the invention comprises an auto segmenter.
  • the first piece of the information needed is how many slots are available. For • example, if there is any SCO connection with a period of six, it uses two slots out of every 6 for SCO transmission. Accordingly, to auto segment data the number of free slots must be determined.
  • the second piece of information is what types of packets are allowed.
  • the third piece of information that must be determined is how much data there is in a transmit buffer to send.
  • the hardware needs to know all three pieces of information in order to choose a packet type. Those skilled in the art will require that the described auto-segmenter may be realized in other technologies such as firmware or a combination of hardware and firmware.
  • the function of the "Slot Gauge" mechanism is to tell the hardware how many slots are available to transmit or receive packets between periodic transmissions, such as an SCO transmission.
  • the Slot Gauge informs the hardware how many contiguous slots are currently available in the active piconet.
  • the computation of available slots is complicated by the fact that if two piconets are active you might have Bluetooth clocks that are skewed from one another. In the case that the Bluetooth clocks from the two piconets are not in phase synchronization, the phase relationship of the two piconets needs to be accounted for in order to figure out how many slots are available.
  • Figure 19A a is graphical illustration of unsynchronized piconets. In Figure 19A three separate piconets 1903, 1905, and 1907 are illustrated.
  • Piconet 1907 represents the active piconet.
  • the phase of piconet 1907 is different from the phase of piconet 1903 and piconet 1905.
  • Piconet 1903 has a slot 1909 which is scheduled, and piconet 1905 has a slot 1911 that is scheduled.
  • Figure 19B is a graphical illustration of the timing of the "Slot Gauge.”
  • the following description of " Slot Gauge" describes a hardware implementation. Those skilled in the art will recognize the other implementations may be accomplished in software, firmware, or can comprise a combination of tecliniques.
  • the Slot Gauge output updates on the rising edge of Bluetooth clock bit 0, for example 1947, of the currently active piconet, and is stable for 625 ⁇ sec, which is equal to one slot period.
  • S M TX represents the number of slots available for transmission for a master.
  • the value for S M ⁇ x will be used by a hardware packet segmenter to decide which type of data packet to use for transmission. For example, if all packet types are allowed and S M ⁇ x is 5 or greater then any packet type may be used. If S M>TX is less than 5, DM5 and DH5 packets may not be used. If S M TX is less than 3, neither DM5, DH5, DM3, nor DH3 packets will be allowed.
  • the second value, S M RX represents the number of slots available for reception by a master.
  • S M RX is equal to the number of available slots, including the current slot, available for packet reception.
  • S M RX is used by the receive hardware.
  • the receiver hardware decoders the TYPE field in the received packet header, and if the packet requires more than S M RX slots, packet reception is aborted.
  • the third value, S s ⁇ x represents the number of slots available for transmission by a slave type device.
  • S s ⁇ x has the same use as S M ⁇ x . Since a device may be both a master and a slave both S M ⁇ x and S s ⁇ x values may be needed by a device.
  • the fourth value, S S RX represents the number of packets available for reception by a slave.
  • S s RX has the same us as S M RX . Since a device may be both a master and a slave both S M,RX an d S SjRX may be needed by a device.
  • Bluetooth clock bit 0 (every whole slot boundary). Slot Gauge computations are performed on a snapshot of the state of the inputs at the rising edge of Bluetooth clock bit 0. The following steps describe the Slot Gauge algorithm.
  • S (i) can be computed other ways if C(i) is not available. For example, it could be calculated by subtracting the current Bluetooth clock in P(i) from the Bluetooth clock value where periodic transmission will occur (e.g., 1909 and 1911). Alternative, C(i) could be replaced with a down-counter. This down- counter would effectively be equal to S](i).
  • S j (i) is the number of whole slots in the piconet clock with which C(i) is aligned.
  • phase [P(C(i))J, of the piconet clock with which C(i) is aligned, and the 1 MHz phase of the active piconet 1907, phase [P acllv J.
  • the number of slots available in P act j ve is the minimum ofSj ) for all values of
  • the Slot Gauge value is modified according to whether the device is a master or a slave, and whether availability for RX or TX packets is needed. If the device is a transmitting master, one slot is subtracted from the Slot Gauge output to allow for a one slot 5 reply from the slave. If the device is a receiving slave, one slot is subtracted from the Slot Gauge output to again allow for at least a one slot reply. If the subtraction of one from the Slot Gauge value results in a negative number, 0 is used instead of the negative number. All negative results are set to zero. Master:
  • the second piece of information that the transmit hardware auto segmenter needs in order to choose the packet type and length is the number of bytes of data available in the transmit FIFO to be transmitted.
  • the number of bytes of data available to be transmitted may be determined by counting the bytes in the transmit FIFO.
  • the Byte Gauge will determine how many bytes are in the transmit FIFO for a particular connection transmission. Byte Gauge determines the number of bytes using a pointer which sequences tlirough the fragments for the particular connection transmission. Byte Gauge assumes one connection is active and Byte Gauge takes the cunent read pointer for that connection and sequences through the fragments until it hits the write pointer, all the while
  • the Byte Gauge will stop totaling at a L2CAP boundary, it won't try to got any further because the transmission cannot straddle a L2CAP boundary. Additionally the Byte Gauge will stop counting once it counts 339 bytes because the largest possible packet that can be transmitted is 339 bytes, the there is no reason to count any further than 339. So the Byte
  • step 2507 a flag, telling Byte Gauge whether at least 1 byte has been written in the transmit FIFO. Assuming there has been a byte written Byte Gauge checks in step 2505 to see if Tptr is residing at the beginning of a fragment. If Tptr is at the beginning of a fragment control is transfened to step 2519. If
  • control is transfened to 2511 where the write pointer bits MSB tlirough 6 are checked to see if they are equal to the temporary pointer. This checking is to see if the write pointer is in the cunent fragment. If the write pointer is in the current fragment then control is transfened to 2513 and the process terminates in block 2537. If the Wptr is not in the cunent fragment then the dent is added to
  • Control then passes to 2517 where the Tptr is loaded with the value of the Lptr.
  • the FF, LF and then the length field is read from the header fragment.
  • the L_CH field is checked.
  • system firmware may mask off certain packet types any way it wants to. For example, perhaps because of the quality of service desired it may be necessary to transmit only packets having error correction.
  • the transmit packet type an length may be selected using the following packet type/length selection rules.
  • the first priority is to transmit as many bytes in the buffer as possible. If there are more bytes than the largest allowed type, then the allowed type that can hold the most bytes is chosen, regardless of whether it has encoding or not.
  • Figure 20 is a table relating the number of bytes to be transmitted to the packet type priority. For example, if there is between 1 and 17 bytes in the buffer, the first choice is a DM1 type packet. The second choice is a DH1 type packet. The reason is these packets are chose is that the DM1 packet may hold up to 17 bytes, the DH1 packet type may hold up to 27. The DM1 packet also contains forward enor conection so it holds less data but both are one slot.
  • the least DM1 and DH1 bandwidth is used. Because one slot is used instead of three, the remaining 2 slots are free for other uses.
  • the first choice is the DM1 because that is the one that has the forward error conection and so is more robust than DHL
  • the third choice would be a DM3, which occupies three slots, but if for some reason
  • DM1 and DH1 are not allowed a DM3 and then DH3 will be chosen. If nether DM1, DH1, DH3 or DM3 is allowed then DM5 and DH5 are chose according to the table of Figure 20.
  • packets are chose for other ranges of number of bytes to be transmitted.
  • the packet type is chosen by selecting the first type of packet that is allowed from the choices in the table.
  • packet types may be automatically selected from the table of Figure 20.
  • the packet type is chosen by selecting the packet type that takes the least amount of space as a first criteria, and then selecting the packet that gives the most error correction. Since packet size is the first criteria for selecting packet types, the packet type selected may or may not have error correction. (using the table to select packet type for transmitting in a Bluetooth network is one of the claim areas).
  • An important aspect of the present embodiment is that the segmenter's type and length selection for a given connection is not changed until that packet has been actually or otherwise flushed.
  • Another embodiment of the invention comprises a method by which unprotected fragments are selected to form a transmit FIFO.
  • This embodiment is a way of choosing the lowest fragment to incorporate into a transmit FIFO.
  • a transmit FIFO is formed for a connection by stringing together fragments to hold the data to be transmitted to a particular connection.
  • Each fragment is associated with a bit in the bit protect array 1011 (See Figure 10).
  • the present embodiment of the invention selects the lowest number fragment which has a protect array value of 0, that is it selects the first unprotected (unused) fragment.
  • Figure 21 is a schematic diagram of a fragment chooser circuit that accepts protect bits and produces the index of the lowest unoccupied fragment. So, for example, if fragments 0, 1, 2, 4, and 5 are occupied and the rest of the fragments are unoccupied, the fragment chooser will choose fragment 3 next.
  • the fragment chooser illustrated in Figure 21 is simplified one having only 16 fragments instead of 128. So if fragments 0, 1 and 3 were protected, the fragment chooser would output a value of 2.
  • the fragment chooser is composed of a number of identical blocks 2111. The blocks are repeated multiple times (2103 A through 2103H, 2105 A through 2105D, 2017A and 2017B, and 2109 A).
  • the example of Figure 21 is an Implementation of a 16 packet chooser which will select the lowest value of fragment, of 16 fragments, which is unprotected.
  • the translation of the illustration of Figure 21 to handle 128 fragments is straight forward.
  • the first level would have 64 blocks instead of 8 blocks (2103 A through 2103F) of the exemplary circuit.
  • the blocks 2111 would have a 7 bit input at X3 and X4 and a 7 bit output at Y2.
  • Circuit 2113 is an OR circuit which accepts XI and X2 as its input and puts out a 1 if either or both inputs are 1 (unprotected).
  • Figure 24 is a graphical illustration of the operation of an automatic transmit FIFO according to an embodiment of the invention. For example suppose a Bluetooth transmission
  • the transmit FIFO may remove the protection on the fragments used to make up the transmission 2403. For example, consider a portion fo the transmit FIFO illustrated at 2400. Fragments N tlirough N+5 are visible in the illustrated portion ofthe transmit FIFO 2400. Fragments 2409, 2413 and 2415 are being used by another connection not related to transmission 2403.
  • the transmission 2403 will comprise portions of fragment 2407, 2411, and 2417.
  • the base pointer 2425 represents the beginning of the transmission 2403.
  • the base pointer 2425 and a forward pointer 2427 are initially pointed to the same location.
  • the transmission 2403 sent and the forward pointer 2427 is pointing as shown in Figure 24.
  • the write pointer 2429 is pointing to the end of fragment 2417 indicating that more data has been placed in the transmit queue.
  • base pointer 2425 can be advanced forward pointer 2427.
  • base pointer 2425 has advanced tlirough fragment 2407, the protection of fragment 2407 may be removed.
  • the base pointer may then be advanced through fragment 2411 and then the protection on fragment 2411 can be removed, making that fragment available for general use.
  • the base pointer 2425 will then be advanced to the position of the forward pointer 2427.
  • the base pointer will then end up pointing at the same byte as the forward pointer 2427.
  • the memory protection on fragment 2417 cannot be released because, as read pointer 2429 indicates, data remains in fragment 2417.
  • FIG. 25 is a flow diagram of the Byte Gauge process. (TED this description may require some work also) Several definitions are helpful in understanding flow diagram 2501.
  • ACL X represents the data in the ACL RAM (transmit FIFO) address location X.
  • ACC is an accumulator amount.
  • Bptr is the base pointer, such as the base pointer 2425 of Figure 24.
  • the dent is the fragment based down-count. That is the number of bytes (to transmit) left in the current fragment to which the base pointer is pointing.
  • FF is the first fragment bit, FF is contained in the fragment.
  • FLEN is the amount of data contained in a fragment. FLEN is in the header also.
  • Lptr is a link pointer.
  • L_CH is the L2CAP field that is indicating start or continuation. A value "10" means start, a value of "01" means continuation.
  • LF is the ast fragment bit. And then Tptr is the temporary pointer.
  • the variable "Past First Pass " PFP is included for the following reason.
  • the initial L2CAP boundary is the "First Pass”; initially, “Past First Pass” is set to zero so that when the "First Pass” is encountered, the algorithm does not stop.
  • Figure 26 is a flow diagram illustrating the L2CAP packet flush state machine, according to an embodiment ofthe invention.
  • the flow diagram starts with block 2601 , which waits for the acknowledgment of a packet conectly received. When the acknowledgment comes, control is transferred to 2603.
  • the base pointer is checked to see if the forward pointer is in the same fragment. If the base pointer is not in the same fragment as the forward pointer control is transfened to block 2605.
  • the write protection ofthe current block is reset (unprotected).
  • the base pointer (bp) is then moved to the next fragment, that is the linked list is followed to the next fragment.
  • Control is then transfened back to block 2603 where the forward pointer is checked to see if it is in the same fragment as the base pointer (bp). If the base pointer is in the same fragment as the forward pointer (the forward pointer currently is pointing to the end ofthe packet) the result of block 2603 will be yes and then in block 2609 the base pointer is set equal to the forward pointer, the base counter is set equal to the forward counter, and control transfers to block 2601.
  • FIG. 27 is a flow diagram of an L2CAP packet transmit state machine, according to an embodiment of the invention.
  • the initial state 2731 of the L2CAP packet transmit state machine is a wait for a request state.
  • the request comes from the physical layer hardware, for example from the hardware doing forward enor conection, encryption and whitening, which will be done prior to transmission of data.
  • the forward pointer 1006 is set equal to the base pointer 1005. If the previously sent packet was not acknowledged, the forward pointer would be pointing to the end ofthe unacknowledged packet. In that case the unacknowledged packet would need to be resent and the forward pointer 1006 would need to be set equal to the base pointer 1005.
  • variable pb is set equal to the packet length in bytes.
  • the variable pb will be used as a down counter to count the bytes as they are sent.
  • data-out is set equal to the first byte ofthe Bluetooth header, BBHl.
  • BBHl is determined entirely by the segmenter, so that at step 2733 nothing has been taken out of the transmit FIFO e.g. 903.
  • the state machine then waits for another request at 2735 from the physical layer hardware. Once the request is received flow control bits for the Bluetooth packet header are provided. The state machine then waits for another request at 2739. When the next request anives data-out is set equalto PLH1 which is the payload header.
  • the payload header is either one or two bytes depending on whether its packet being sent is a multi-slot packet or a single slot packet. Data-out is determined by the segmenter. The state machine then waits for another request at 2701. Little has been read for the transmit FIFO yet. Once the next request anives control transfers to 2705. In 2705, if the segmenter has chosen a multi-slot packet then the physical layer would be provided with the second byte of the payload header, as indicated in 2703, and then the state machine awaits the next request in 2707. Once the next request anives control transfers from block 2707 to block 2709. If, in block 2705 , the segmenter had not indicated that a multi-slot slot packet was being sent, control would also transfer to block 2709.
  • a forward count (FC) down counter is examined.
  • the forward count down counter counts down from the fragment length.
  • Control then transfers to block 2717 where FC is loaded with the length field of the fragment header.
  • the FC down count is going to count down from the length ofthe fragment.
  • Control is then transfened to 2719, which asks if the cunent fragment is a first fragment? In other words is the FF bit equal to 1? If it is then it is necessary to read out one extra byte because the first fragment has one extra byte indicated by the L_CH field. If there is one extra byte, the forward count is decremented and the forward pointer is incremented, and then control is transferred to a block 2723 where the forward pointer is incremented, the forward count is decremented, and the packet byte count is decremented.
  • Control is then transfened to 2725.
  • the data_out is set equal to the value of the memory anay at the address location indicated by the forward pointer from the memory.
  • the data_put is, once again, the byte that is being provided to the physical layer and control transfers to 2729.
  • Block 2729 the packet byte, is examined to see if the PB count has counted down to zero. If the PB count has not counted down to zero then control is transfened to block 2707, otherwise control is transferred to block.2731 at the begimiing and waits for a request which will be the next packet. Now if the next packet is going to be a retransmission then what will have happened is the base pointer would have not moved up to the forward pointer.
  • PB packet length. That packet length is chosen by the segmenter. In a retransmission a packet length will not have changed so exactly the same bytes will be read from the FIFO. Therefore the packet will be exactly the same as the previous one.

Abstract

Methods for removing complexity from a Bluetooth processor's fimware and placing them in hardware in order to use a simpler processor or to do other tasks in the Bluetooth processor. Assembling and managing communication packets and transmission, providing modulo divides, and allocating memory are typical firmware tasks for a Bluetooth device. By creating circuits that assemble and manage communications packets and transmits, provide modulo divides, and manage Bluetooth device memory a processing burden can be removed from the Bluetooth processor. This lessened processing requirement allows less expensive, e.g. slower, processors to be used, or other functions to be incorporated into the processor's firmware.

Description

BLUETOOTH BASEBAND SOLUTION WITH REDUCED PROCESSOR
REQUIREMENTS AND INTEGRATED HOST CONTROLLER
FIELD OF THE INVENTION The present invention relates to Bluetooth wireless communication circuits, and in particular embodiments to reducing Bluetooth processor requirements by incorporating common processor functions within dedicated hardware circuitry.
BACKGROUND OF THE INVENTION Bluetooth refers to an open specification describing a technology which enables short range wireless data and voice communication.
There are many examples of short range communications within the field of computing and communications. A great variety of cables are commonly used for interconnecting personal computers, monitors, keyboards, fax machines, networks, etc. so that they may communicate with each other. Much of this communication now takes place over cables. Such cables connect a plethora of different devices. These cables are of various lengths and have a wide variety of connectors. Some cables are standardized, but many come with connectors having a variety of shapes, sizes, number of pins and wiring. Coping with such a great variety of cables can be burdensome to users. By using Bluetooth technology, instead of communicating over cables, devices can communicate in a wireless fashion over an air interface using the 2.4 gigahertz ISM (Industrial Scientific and Medical) frequency band.
SUMMARY OF THE INVENTION
Bluetooth is an open specification produced by the Bluetooth special interest Group (SIG) and is available from Bluetooth.com. This specification is incorporated by reference as though set forth in full.
In a first example of the invention a wireless communication device is disclosed. The wireless communications device comprises a wireless transceiver and a processor coupled to the wireless transceiver. The processor has a memory comprising a plurality of fragments and an array configured to control the sequence of memory fragments from which the data is read.
In a second example of the invention a processor having memory which is comprised of a variety of fragments is disclosed. Additionally, the processor includes an array configured to control the sequence of memory fragments from which the data is read.
It is understood that other embodiments of the present invention will become readily apparent to those skilled in the art from the following detailed description, wherein it is shown and described only embodiments of the invention by way of illustration of the best modes contemplated for carrying out the invention. As will be realized, the invention is capable of other and different embodiments and its several details are capable of modification in various other respects, all without departing from the spirit and scope of the present invention. Accordingly, the drawings and detailed description are to be regarded as illustrative in nature and not as restrictive.
BRIEF DESCRIPTION OF THE DRAWINGS
The above summarized aspects, as well as other aspects, features, and advantages of the present invention will become better understood with regard to the following description, appended claims, and accompanying drawings where:
Figure 1 is a graphical representation of an example Bluetooth environment. Figure 2A is a graphical illustration of the high-level functional composition of a
Bluetooth module.
Figure 2B is a graphical illustration of protocols within the Bluetooth system illustrated in Figure 2A.
Figure 2C is a generalized graphical representation of a Bluetooth device having a host interface. <
Figure 3 is a graphical representation of the topology of a basic Bluetooth network. Figure 4 is a graphical illustration of a scatternet Bluetooth network. Figure 5 is a graphical illustration of Bluetooth clock timing. Figure 6 is a graphical illustration of the slot timing of SCO data packets. Figure 7 is a graphical illustration representing pathways for various data packets within the layering of the Bluetooth protocol.
Figure 8 is a graphical illustration of a protocol layering diagram of a Bluetooth device coupled to a computer via a USB (Universal Serial Bus).
Figure 9 is a graphical illustration of the six transmit and receive FIFO (First In First Out) structures within the physical layer, according to an embodiment of the invention.
Figure 10 is a graphical representation of a transmit FIFO and ancillary structures according to an embodiment of the invention.
Figure 11 is a graphical illustration of the organization of data within a fragment. Figure 12 is a graphical illustration of a firmware packet comprising multiple fragments. Figure 13 is a graphical illustration showing the layering and packets within a host and
Bluetooth device, illustrating layers added according to the embodiment of the invention.
Figure 14 is a graphical illustration of the packet structure of the added layers below the HCl layer, according to an embodiment of the invention.
Figure 15 is a graphical illustration of an embodiment of the invention. Figure 16 is a block diagram of an exemplary baseband implementation, according to an embodiment of the invention.
Figure 17 is a block diagram of a Bluetooth integrated circuit, according to an embodiment of the invention. Figure 18 is a graphical illustration of piconet traffic on a single piconet, which has an
SCO connection with a period of 6.
Figure 19A a is graphical illustration of unsynchronized piconets. Figure 19B is a graphical illustration of the timing of the "Slot Gauge." Figure 20 is a table relating the number of bytes to be transmitted to the packet type priority.
Figure 21 is a schematic diagram of a fragment chooser circuit that accepts protect bits and produces the index of the lowest unoccupied fragment.
Figure 22 is a schematic diagram used to provide a modulo divide of the 27 bit Bluetooth clock by "T", an 8 bit number, according to an embodiment of the invention.
Figure 23 is a graphical illustration of the computational values generated in an exemplary 115,307,261 mod 135.
Figure 24 is a graphical illustration of the operation of an automatic transmit FIFO according to an embodiment of the invention. Figure 25 is a flow diagram of the Byte Gauge process.
Figure 16 is a flow diagram illustrating the L2CAP packet flush state machine, according to an embodiment of the invention.
Figure 27 is a flow diagram of an L2CAP packet transmit state machine, according to an embodiment of the invention.
DETAILED DESCRIPTION OF EMBODIMENTS OF THE INVENTION
In the following description, reference is made to the accompanying drawings, which form a part hereof, and in which is shown, by way of illustration, specific embodiments illustrating ways in which the invention may be practiced. It is to be understood that other embodiments may be realized, as the inventive concepts disclosed herein may be used in the design and fabrication of other embodiments, without departing from the scope and spirit of the inventive concepts disclosed herein.
Accordingly, embodiments of the present invention relate, generally, to wireless communication systems. However, for the purposes of simplifying this disclosure, the embodiments are described herein with relation to Bluetooth networks . Although the described exemplary embodiments disclosed herein are directed to Bluetooth networks, there is no intent to limit the invention to the example embodiments. The exemplary embodiments are intended to illustrate inventive aspects of the present invention, which are applicable to a wide variety of electronic systems. Figure 1 is a graphical representation of an exemplary Bluetooth environment. In Figure
1 the following Bluetooth systems are illustrated. A Personal Digital Assistant (PDA) 103 is coupled to a Bluetooth wireless transceiver 105 A. A fax machine 107 is coupled to a Bluetooth wireless transceiver 105B. Atelephone 109 is coupled to a Bluetooth wireless transceiver 105C. A telephone network, represented by telephone wall plug 111 , is coupled to a Bluetooth wireless transceiver 105D. A printer 113 is coupled to a Bluetooth wireless transceiver 105E. A computer is coupled to a Bluetooth transceiver 105F. A keyboard is coupled to a Bluetooth transceiver 105G. By using Bluetooth technology all of the devices of Figure 1 can communicate with each using Bluetooth radio frequency (RF) connections without interconnecting cables.
Figure 2 A is a graphical illustration of the high-level functional composition of a
Bluetooth module. In Figure 2A an application 207, within a host 205 communicates with
Bluetooth device 203. The application 207 may communicate with a Bluetooth device 203. In the Bluetooth device 203 a host I/O (input/output) and link manager functions 209 communicate with a application 207, which is running in the host. The host I/O and link manager 209 communicates the higher layers and applications 207 within the host.
The host I/O and link manager 209 communicates with the link controller 211 which controls the flow of data between the applications 207 and a Bluetooth radio 213. The link controller 211 accepts data from the Bluetooth radio 213 and provides'the data to the host I/O and link manager for communication across the host I/O to the higher layers and application module
207. Data coupled into the host I/O and link manager 209, from the higher layers and applications 207, are provided to the link controller 211. The link controller 211 controls the data flow to the Bluetooth radio module 213. The Bluetooth radio module accepts communications from and provides communications to an antenna 215, which in turn provides an over the air RF (Radio Frequency) link.
Figure 2B is a graphical illustration of protocols within the Bluetooth system of Figure 2A. In Figure 2B higher layers and applications 227 communicate with a L2CAP (Logical Link Control and Adaptation Protocol) layer. The L2CAP layer 229 is a software component that provides a standard interface for the transfer and reception of control and application data to and from a Bluetooth device 235. The L2CAP layer 229 in turn communicates with a HCl (host controller interface), which forms the interface between the L2CAP layer 229 and various physical interfaces 233. The various physical interfaces 223 may comprise, for example, RS-232 ports, USB (universal serial bus) ports, a UART (Universal Asynchronous Receiver Transmitter), or other physical interfaces. The HCl (Host Communications Interface) layer 231 comprises an HCl communications protocol from the host controller 237 within the Bluetooth module 235 to the host. The host controller 237 and link manager 239 are a further illustration of the functions within the host I/O and link manager 209 of Figure 2A. The link controller 241 is the functional equivalent of the link controller 211 of Figure 2A. The Bluetooth radio 243 as well as the Bluetooth antenna 223 are also functionally equivalent to the corresponding modules of Figure 2 A.
Figure 2C is a more detailed graphical representation of an example Bluetooth device having a host interface. The applications 253 communicate to an HCl (host controller interface) driver 261 through protocols 255 and 257. Protocol 257 is the previously mentioned L2CAP protocol layer. The L2CAP protocol layer deals with the transport of L2CAP data packets.
The SCO (synchronous connection) layer 255 manages the transport of isochronous data, such as voice communications, between applications 253 and the HCl driver 261. Each of the protocol layers, the SCO layer 255 and the L2CAP layer 257 provide layers for the purpose of communicating with applications 253 in a standardized way.
The HCl driver 261 provides a standard interface between the SCO layer 255 and the L2CAP layer 257 and the HCl driver layer 261. The HCl driver 261 communicates data to the HCl transport layer 263. The HCl transport layer 263 provides for the transport of data across whatever physical interface 251 is present. The physical interface 251 may comprise a variety of interfaces for example USB, UART (Universal Asynchronous Receiver/Transmitter) or RS- 232. Within the Bluetooth device 275, the host controller 265, provides HCl transport layer services the host controller and link manager interface with the baseband link controller 267. Baseband link controller 267 controls the flow of data to and from the Bluetooth Radio 269. Figure 3 is a graphical representation of the topography of a basic Bluetooth network. The basic entities of a Bluetooth network are the master and slave devices. A master device 303 may have up to 7 slaves, for example slave devices 305, 307 and 309. Each slave can have at most one master at any given time but may have different masters at different times. Each master can have up to seven slaves at any given time. An anangement of Bluetooth devices 301 such as depicted in Figure 3 is called a piconet.
A characteristic of a piconet is that all of the devices in a piconet are synchronized to the master' s clock. When a master 303 establishes a connection to a slave, for example slave 305, 307 or 309, the slave device synchronizes to the master clock. The master device itself can be a slave to another master as illustrated in Figure 4. Figure 4 is a graphical illustration of a scatternet type Bluetooth type network. A scatternet has more than one master device and accordingly more than one master clock. In Figure 4, master device 405 is the master device for slave devices 409, 411 and 413. However, master 405 is a slave device to master 403. Additionally, a master may share slaves on a time division basis. For example, a master 405 may control a slave 413 for a first time period. During a second time period master 407 may control slave 413, as well as controlling slave 415.
In a scatternet, such as 401, master 405 may have to have several clocks running concurrently. For example, master 405 may establish connection with slave devices 409 and 411 thus causing the clocks within slaves devices 409 and 41 1 to synchronize with master 405. Master 403 may then establish a connection to device 405. Device 405 is a slave device to master 403 and hence must synchronize a clock to the master clock in master device 403 , for the purposes of communicating with master device 403. Thus, device 405 will have a master clock, which will be used to communicate with slaves 409 and 411. Device 405 must also synchronize, as a slave, to master device 403 and so must also have a copy of device 403 's clock. In the case of a shared slave device 413 when communicating with master 405 slave 413 will synchronize to master 405's clock. When slave 413 is communicating with master device 407 it will synchronize to master device 407's clock.
Figure 5 is a graphical illustration of Bluetooth clock timing. Every Bluetooth device has a native free-running 28-bit Bluetooth clock. The native Bluetooth clock ticks once every 312.5 microseconds. Two ticks of a native Bluetooth 312.5 microsecond clock form a transmission unit known as a slot, which is the basic Bluetooth transmission unit. Each transmission slot is 625 microseconds wide; accordingly the slot clock has aperiod of 625 microseconds. Generally, Bluetooth networks are set up such that at any given time one device is transmitting and one device is listening. Generally when a transmission is directed to a device, the device must reply to the transmitting device in the next slot after the transmission. Master devices, however, also have a broadcast mode, which enables a master to transmit to all of its slaves. All of the master' s slaves will listen to decode such a transmission. In the case of a broadcast to all slaves, no reply from the slaves is required. A master device will start transmission only during even slots. The slave, receiving the master's transmission will then reply during the next odd slot after the master's transmission. This arrangement is illustrated in Figure 5.
In Figure 5 master transmission 503 occurs during even slot 501. The slave listening to the transmission will then reply in slot 502. Each transmission comprises a data packet. A data packet can be 1 , 3 or 5 slots in length. A master's transmission, however, must always begin and end on an even slot thereby enabling the slave to answer during an odd slot. A transmission packet broadcast, such as 505, occupies 3 slots and a transmission packet broadcast such as 507 occupies 5 slots.
Bluetooth networks are frequency hopping systems. That is the broadcast frequency changes after every packet transmission. So for example if a master broadcast on slot 503 using frequency Fn then the slave would reply on slot 502 using frequency Fn+1. If the master subsequently broadcasts a three slot packet 505, the broadcast would be on frequency Fn+2. Frequency Fn+2 would be maintained for all three slots of the broadcast 505. In multi-slot packets the broadcast frequency does not change. Accordingly in a five slot packet 507 the frequency of broadcast would remain consistent during all five slots.
When a master address a slave, the slave must reply in the next available odd slot. Each packet transmission has an address within it so that each slave knows when it is being addressed. Each packet has, in addition to an address, some flow control information as well as information designating what type of packet is being sent. The address includes 3 bits thus allowing an individual address for each one of the seven slaves and a separate address for broadcast mode to all the slaves. Slaves may be allowed to us one, three or five slots in responding to the master.
There are several classifications for Bluetooth packets. A first classification distinguishes between uncoded and coded packet types. Coded packet types have forward error correction (FEC) included whereas uncoded packets types do not. Packets may also be classified by length as one slot, three slot and five slot packets. There are in general 2 types of Bluetooth packets ACL and SCO. ACL (asynchronous connection link) may be one, two or three slots long and can be coded or uncoded. In general, all packet exchanges can be initiated by the master on even slot. Bluetooth uses a repeat request scheme in which ACL packets are transmitted and retransmitted until the destination indicates successful reception by returning an acknowledgment. An unnumbered acknowledgment scheme is used, in which the previously received packet is aclαio wledged or not. Acknowledgment is indicated when the ARQN bit in the Bluetooth packet header is set to " 1 " (ACK). When the ARQN bit in the Bluetooth packet header is set to "0", a NAK (Not Acknowledged) is indicated.
Additionally, there is a type of packet known as SCO (synchronous connection oriented) which are used for reserved bandwidth communications. SCO packets are used, for example, for voice data transfer between two devices. SCO packets are characterized in that they reserve periodic transmission (and reception) slots on a Bluetooth communication channel. Such a connection is known as a isochronous connection. SCO packet links can be established only after an ACL link has first been established.
Figure 6 is a graphical illustration of the slot timing of different versions of SCO packets. Two different parameters generally define the SCO packet type. The first SCO parameter, T, describes the periodicity of SCO transmissions many slots a packet will encompass. T may be 2, 4 or 6. A second SCO parameter D is used to define the offset of the SCO transmission within period T. If T equals 2 a transmission occurs every second slot. If T equals 4 a transmission occurs every fourth slot and if T is 6 a transmission occurs every sixth slot.
A characteristic of SCO packet transmission is that the data rate is 64 kilobytes per second regardless of the T or D parameters. Therefore, if D equals four then the packets will contain twice as much data as packets whose D is equal to 2. If D equals 6 the packets will contain three times as much data as packets in which D equals 2. SCO packets T = 2, 4, and 6 are illustrated in Figure 6. At 601 in Figure 3 HV1 packets where Y = 2 are illustrated. A first transmission 603 is followed by a receive 605 in a successive slot. The receive 605 is then followed by a transmit 607 in a successive slot and the transmit 607 is followed by a receive in a successive 609. This version of SCO packet is known as a HV1 packet. HV1 packets have forward enor correction added, such that the packets are rate 1/3. That is 3 bits are transmitted to send 1 bit of data. The additional 2 bits transmitted comprise forward error correcting (FEC) coding.
HV2 packets are illustrated at 611 in Figure 6. A first transmit packet 613 is followed by a receive packet 615. Two slots are then skipped and the second HV2 is transmitted at 617 followed by a receive at 619. Two packets are then skipped and another transmission begins.
HV2 packets have forward error conection coding such that the rate of the code is 2/3. That is each 3 bits transmitted comprise 2 bits of data. HN3 packets are illustrated at 621 in Figure 6. A first transmission 623 occurs followed by a reply 625. Four packets are then skipped and then a second transmission 627 occurs followed by reply 629. HV3 type packets contain no forward error correcting codes so that each bit transmitted represents one bit of data. All three packets HV1, HV2 and HV3 transmit at the same data rate. The amount of forward error conecting and coding within each packet varies, and hence the total number of bits transmitted varies.
A third category of packet is the LMP (link manager protocol) packet. LMP packets are ACL type packets, which are sent to manage the connection link between devices rather than transfer data. LMP packets are always one slot packets. ACL packets are given Bluetooth designations according to their length and the enor coding present. A DM1 packet is a one slot ACL packet having forward error conecting coding. A DH1 packet is a one slot ACL packet having no error correcting coding. A DM3 packet is a three slot ACL packet having error correcting coding. A DH3 packet is a three slot ACL packet having no enor correcting coding. A DM5 packet is a five slot ACL packet having error correcting coding. A DH5 packet is a five slot ACL packet having no error correcting coding. LMP packets are always sent using DM1 packets.
Figure 7 is a graphical illustration representing the path of various data packets within the layering of the Bluetooth protocol. The L2CAP layer 703 is generally considered the highest layer within the Bluetooth protocol. The L2CAP layer is typically implemented within a host 715. The HCl layer 709, which communicates with the L2CAP layer 703 through a HCl layer
702, is usually implemented within the Bluetooth device and in the host. Part of the HCl layer 709 within the Bluetooth device is commonly implemented within firmware. The HCl layer 709 is coupled to the physical layer 707. ACL type packets travel back and forth between the L2CAP layer 703, the HCl 709 and the physical layer 707. The physical layer 707 forms the various packet types such as DM1, DH1, HV1, etc. The physical layer 707 provides functions such as encryption, whitening, and encoding. L2CAP packets, which may be up to 64 KB (kilobytes) in length, are communicated to the HCl 709 layer, along which then reformats the L2CAP packets into HCl packets. The HCl layer 709 takes the HCl packets and puts them into a form that is compatible with the physical layer 707. The SCO packets typically have their own path between the physical layer 707 and a transmission mechanism such as a codec 713. SCO packets, however, may also go from the physical layer through the HCl layer 709, tlirough the L2CAP layer 703, and subsequently to the host 715.
LMP packets are coupled between a link manager 705 and the physical layer 707. The link manager 705 is used to negotiate packet types between Bluetooth devices, as well as to setup encryption. The link manager 705 is also used for setting up SCO links and for other link management functions Figure 8 is a graphical illustration representing protocol layering, as might be found within a Bluetooth device coupled to a personal computer (PC) via a USB (Universal Serial Bus). The L2CAP protocol 803 will is executing in the PC. The L2CAP protocol 803 communicates with a host controller interface (HCl) 805. Host controller interface 805 will then communicate with a USB module 807. Bluetooth device is then coupled via USB layer 809 to the USB layer 807 within the computer. The USB within the Bluetooth device 809 then communicates with the host controller interface (HCl) 811, which in turn communicates with the physical layer 813 in the Bluetooth device.
So, for example, something is typed on a keyboard. The input from the keyboard would be then converted into L2CAP packets in L2CAP layer 803. The L2CAP packets would be then communicated to the HCl layer 805 which would convert the L2CAP packets into HCl packets. The HCl packets would then be converted into USB packets in the USB layer 807 and coupled across the USB bus to the USB layer 809 within the Bluetooth device. The USB packets would then be reassembled into HCl packets in HCl layer 811, and then further coupled into the physical layer 813. Commonly the USB layer 809 and HCl layer 811 are implemented in firmware within the Bluetooth device.
One of the features of the present invention is that the HCl layer, which typically exists in a firmware implementation, is converted into a hardware implementation. The burden on the processor, which ordinarily executes the HCl firmware in the HCl layer, is thereby lessened by converting the typical firmware implementation into a hardware implementation,. In other words, in one embodiment of the invention, the data packet flow between the L2CAP layer 803 and the physical layer 813 will be converted from a typical firmware implementation into a hardware implementation.
Various embodiments of the invention will describe functions, ordinarily programmed within a typical firmware implementation, that will be accomplished in hardware. These approaches allow either less expensive (e.g. 8 bit instead of 16 bit) processors to be used, or for additional functions to be run in the unburdened processor, or both.
According to embodiment of the invention there are three FIFO structures within the physical layer, which accommodate the transmission of data packets, and three FIFOs within the physical layer, which accommodate the reception of data packets.
Figure 9 is a graphical illustration of six transmit and receive FIFO structures within the physical layer. In Figure 9 three FIFO structures accommodate the transmission of packets. The L2CAP transmit FIFO structure 903 accommodates the transmission of L2CAP type packets. The SCO transmit FIFO structure 907 accommodates the transmission of SCO type packets. The LMP transmit FIFO structure 911 accommodates the transmission of LMP type packets. The
L2CAP receive FIFO sfructure 905 accommodates the reception of L2CAP type packets. The SCO receive FIFO structure 909 accommodates the reception of SCO type packets. The LMP receive FIFO structure 913 accommodates the reception of LMP type packets. In an embodiment of the invention, firmware will no longer be used to access the L2CAP transmit FIFO. Instead the L2CAP transmit FIFO will be controlled by HCl hardware. By removing the FIFO management functions from the HCl firmware a significant burden is removed from the HCl firmware processor thus enabling the HCl firmware processor to accomplish other tasks, or alternatively allowing a less powerful HCl firmware processor to be used. The term L2CAP FIFO is somewhat misleading. In actuality several logical FIFOs are created within the fragmented memory, which comprises the L2CAP transmit memory. For the sake of simplicity of nomenclature, however, the L2CAP transmit memory will be refened to as the L2CAP FIFO. Additionally, examples which apply to any of the transmit FIFOs will be refened to simply as transmit FIFOs.
The SCO FIFO, like the L2CAP FIFO may be implemented as a fragmented memory. In such a case the SCO packets may be accommodated by the same FIFO as the L2CAP packets, or the SCO packets may be accommodated by a different FIFO also with a fragmented structure.
The present embodiment includes an L2CAP transmit FIFO. Details of the transmit FIFO are the same whether the transmit FIFO is used to transmit S CO packets, L2C AP packets or both.
Because transmit FIFOs may manage multiple connections implementations may split their transmit FIFO into multiple FIFOs. For Example one for each device. This expedient of splitting the transmit FIFO into multiple FIFOs can make it easier to manage the individual
FIFOs, but has a serious drawback. The drawback occurs because the physical layer and the L2CAP layer have a high level data flow control mechanism. The L2CAP layer communicates to be physical layer how much memory is available in the host device. The physical layer in turn communicates in turn to the L2CAP layer how much memory is available in the physical layer. In this manner the physical layer can moderate the data flow from the L2CAP layer depending on how much memory is available in the physical layer. The L2CAP layer can also moderate the data flow from the physical layer depending on how much memory is available in the L2CAP layer. When each connection has a transmit FIFO, within the physical layer the amount of memory remaining within the physical layer does not necessarily indicate what level of data flow the physical layer can accommodate. Total memory may not be representative of what level of data flow the physical layer can accommodate because one or more of the transmit FIFOs may be nearly full and the other FIFOs may be nearly empty. The amount of memory does not reflect the moderation of data flow needed to accommodate the nearly full transmit FIFO. Therefore, if one transmit FIFO is used per connection, the transmit FIFO management is simplified but the data flow management between the physical layer and the L2CAP layer is made substantially more complicated. Accordingly, pooling the memory in a memory management type fashion has significant advantages when used in concert with the Bluetooth messaging mechanism that reports the amount of memory available between the physical and L2CAP layers.
Figure 10 is a graphical representation of a transmit FIFO and ancillary structures according to an embodiment of the invention. The transmit FIFO 1001 is ananged in a series of fragments. In the present implementation 128 fragments of 64 bytes each are used. Those skilled in the art will recognize that the size of the fragments, as well as the number of fragments are dictated by the requirements of individual implementations. Although the present embodiment utilizes 128 fragments of 64 bytes each, other implementations might find other fragment sizes and number of fragments convenient.
Accompanying the transmit FIFO is a protect bit array 1011. Protect bit anay 1011 is used to indicate whether a corresponding fragment is in use or empty. Accordingly, there are 128 bits within the protect bit anay 1011, each corresponding to a fragment within the transmit FIFO. So for example if fragment 0 is in use protect bit anay bit 1013 is set to 1. If fragment 5 is not in use then protect bit anay bit 1015 is set to 0 indicating that fragment 5 is empty. Additionally, a read and write pointer, which points into the transmit array, is used with each connection. Therefore, 10 sets of read pointers and write pointers indicate the points where reading and writing from the transmit FIFO are taking place. Seven sets for slave devices 1 set for a connection to another master 1 set for broadcasts to active slaves and 1 set for broadcast to all slaves.
Because there are 8 possible connections, the data for each connection may be scattered in a variety of non-contiguous fragments. To string the fragments back into a contiguous transmit sequence a linked list 1003 is used. The linked list comprises an 128 element array of 7 bit values. Within each element of the array is the number of the next sequential fragment to be transmitted. Therefore, if a single connection used fragment 0, fragment 2, fragment 4 and fragment 7 of the transmit array, the linked list would have a value of 2 in the 0 field. The 2 in the 0'th field of the linked list indicates that the next fragment to be transmitted after fragment 0 would be fragment 2. linked list element 2 will have a value of 4 written into its second element indicating that the next fragment to be transmitted after fragment 2 is fragment 4. Array element 4 will have written a value of 7 into that anay element indicating that after fragment 4, fragment 7 is to be transmitted. By using this 7 bit 128 element array threads linking the transmissions for each connection can be established through the transmit FIFO.
1005 is an anay of 10 base pointers and 1006 is an array of 10 forward pointers, both of which are used to read data from the transmit FIFO 1001. 1007 is an anay of 10 write pointers used to write data into the transmit FIFO 1007.
Figure 11 is a graphical illustration of the format of data within a fragment. Each fragment 1101 has a header at byte 0 of the fragment. Within the fragment header are three fields. The first field 1103 is a 1 bit field designated FF for first fragment. The first fragment field indicates whether the fragment is the first fragment of a firmware packet (Illustrated in Figure 12). The second field within the fragment header is the LF or last fragment field 1105. The last fragment field 1105 indicates whether the cunent fragment is the last fragment within a firmware packet. The remaining field, within byte 0 of the fragment header, is the length field 1107. The length field 1107 is 6 bits in length and indicates the number of bytes used within the fragment. The first fragment of a transition packet also has two more fields located within byte 1 of that fragment. The first field is the L_CH field 1109 indicating if the present packet, coincides with the beginning of an L2CAP packet. The L_CH field is 2 bits in length with a " 10" indicating that the data within the fragment is actually the beginning of an L2CAP packet. A L_CH value of 01 indicates that the present fragment is a continuation of an L2C AP packet. This identification of the timing of the L2CAP packet is important because it is desirable that the packets going out over the air never straddle an L2CAP boundaiy. Additionally, in the second single bit field of byte 1 is a flow bit, illustrated at 1111 , which is used to control the data flow to the L2C AP layer. The hardware will choose the type of Bluetooth packet to sent. The hardware uses the L_CH field to select a segment of data, to transmit in a Bluetooth packet, that does not straddle an L2CAP boundary.
Figure 12 is a graphical illustration of a firmware packet. The firmware packet 1201 comprises a first packet 1209 having a header in byte 0 with a " 1 " bit in the first position 1203 designating that this is the first fragment of a firmware packet and a "0" in header position 1205 indicating that it is not the last fragment of the firmware packet. The remainder of byte 0 comprises a length field which gives the number of bytes used in a fragment. Byte 1 of the first fragment 1209 also has a 2 bit field because it is the first packet of a firmware packet. In the illustrated example the 2 bit field of byte 1 is set to a "10" indicating that this fragment is the beginning of a L2CAP packet. An intermediate fragment 1215 is also illustrated. The intermediate fragment 1215 has a "0" in the first field of the header 1211 and a "0" in the second field of the header 1213 signifying that the present packet 1215 is neither the first or last fragment of the firmware packet 1201. The last fragment of firmware packet 1201 has the first bit of the header 1217 set to a "0" indicating that this is not the first fragment of a packet. The next bit of the header 1219 is set to a " 1 " indicating that fragment 1221 is the last fragment within firmware packet 1201.
Figure 13 is a graphical illustration of the layering and packets within the host and embedded software of a Bluetooth device. The upper most layer is the L2CAP layer 1301. An L2CAP packet produced by the L2CAP layer comprises a length field 1303, a channel ID 1305 and a payload 1307. The L2CAP packets are broken down into HCl packets in the HCl layer 1309. The HCl packets have flags to indicate whether they are the beginning of an L2CAP packet 1311 or a continuation of an L2CAP packet 1313. An HCl data payload 1315 will always end concunently with an L2CAP payload 1307 in order to insure that the HCl packet does not straddle an L2CAP boundary. Accordingly a L2CAP packet always translates into an integer number of HCl packets. The next lower layer 1317 is indicated as a HCI-USB layer in the host. Layer 1317 transfers HCl packets to the USB driver 1321. The USB Driver layer 1321 then converts the HCl packets to USB packets and then transmits the USB packets, e.g. 1323 A and 1325 A, across a physical connection. The physical connection in the present examples indicated as a USB hardware bus, coupled to the Bluetooth device. The USB packets are received in a USB Driver layer. The USB packets are then reassembled into HCl packets 1319B within the Bluetooth device. The HCl packets 1319B will then be formed into the over-the-air packets 1331 which will then be sent out over the Bluetooth radio 1333. An embodiment of the present invention inserts two more layers between the HCl packet 1319B and the over the air packet 1331. The first layer inserted is the layer that takes the HCl packet and forms firmware packet 1327. The second layer is a layer that maps the firmware packets 1327 into fragments 1329 within the transmit FIFO. The hardware will then automatically choose the over-the-air packets 1331 from the transmit FIFO. The fragments belonging to each comiection are treated as contiguous segments except for the marker which shows where the L2CAP boundary is. When an L2CAP boundary is encountered an optimally sized over-the-air packet that does not straddle an L2CAP boundary is selected and sent.
Figure 14 is a graphical illustration of the packet structure of the added layers below the HCl layers, according to an embodiment of the invention. The packets from the HCl layer 1403 are formed into firmware packets 1405. The firmware packets are further formed into 64 byte fragments 1407 and 1409 in the transmit FIFO. The fragments such as 1407 and 1409 are then concatenated by the hardware to form the over-the-air packet pay loads 1411. The over-the-air packet payloads 1411 are then incorporated into over-the-air packets 1413.
Figure 15 is a graphical illustration of an embodiment of the invention. In Figure 15 Bluetooth host 1501 comprises three layers. The first layer 1503 is a higher layer such as the L2CAP layer. Just below the L2CAP layer 1503 is the HCl Driver layer 1505. Just below the HCl Driver layer 1505 is the physical bus 1507. The physical bus may be a variety of different type buses such as a USB, PCI bus, or another type of bus. The physical driver 1507 in the Bluetooth host then interfaces with the actual physical bus 1509. The physical bus 1509 is then coupled to the HCl firmware in the Bluetooth baseband device. Although much of the HCl firmware functionality has been transferred into HCl hardware 1511, different embodiments may choose to keep different functions within the HCl firmware 1513. In addition, some residual HCl firmware 1513 may continue to run to interface with the link manager firmware 1515. Additionally another aspect of an embodiment of the invention is the ability to switch between hardware and firmware modes of operation.
L2CAP data travels from the physical bus hardware 1509 through coupling 1519 into the HCl hardware 1511. The baseband controller block 1517 represents the physical layer. The physical layer couples the data into the Bluetooth RF (radio frequency) 1523, which in turn provides the data to an antenna 1525, which transmits the data over the air. Figure 16 is a high level block diagram of an exemplary baseband implementation. 1603 and 1611 comprise the link manager, which is in firmware. UART and USB 1605 may be firmware drivers handling the USB and UART functions. In certain embodiments of the invention the USB and UART may be done in hardware, UART/USB 1605 might go directly to a UART or USB port without first going through firmware drivers. In the case where the L2CAP packets are handled in hardware UART/USB 1605 would comprise physical UART/USB transmit and receive FIFOs.
1607 is a PCM (Pulse Code Modulation) interface. The PCM interface 1607 may be an interface to a codec for example in order to handle SCO traffic. Paths 1613 and 1623 are used for LMP packet traffic, paths 1615 and 1621 are for L2CAP traffic and paths 1617 and 1619 are for the SCO traffic. The LMP transmit FIFO is illustrated at 1625. The L2CAP transmit FIFO is illustrated at 1627, and the SCO transmit FIFO is illustrated at 1629. The SCO controller 1631 controls the SCO receive and transmit, FIFOs. As well as SCO receive and transmit timing. The SCO receive FIFO is illustrated at 1633 , the L2C AP receive FIFO is illustrated at 1635 , and the
LMP receive FIFO is illustrated at 1637. Audio processor block 1641 handles PCM, Mu-Law and A-Law voice algorithms.
The segmented/packet composer/retransmit controllers/flusher block 1639 (SCRF block) chooses the packet types to transmit over the air. The SCRF block also segments the data that's in FIFOs 1625, 1627 and 1629. The SCRF block 1639 also handles retransmission in case a transmission is not received properly. The retransmission function is an asynchronous scheme where the receiver will send back an ACK (Acknowledgment) if a transmission has been received properly. When the SCRF block gets an ACK the hardware will automatically flush the data from the transmit FIFO. If a NAK is received in response to a transmission, signifying transmission was not received properly, then the SCRF hardware will automatically handle a . retransmission. The flusher is the portion fo the SCRF module that flushes the data from the TX FIFO. The flushing of data from the transmit module is automatic (discussed in reference to Figure 25), additionally, a firmware function may flush data form the TX (transmit) FIFO.
The transmit data path 1645 and receive data path 1649 modules contain DSP functions, such as forward error correction, encoding, decoding, data whitening, and an encryption engine.
Then the link control unit 1647 is a state machine which an implementation of the
Bluetooth specification. The frequency hopper 1653 - controls the Bluetooth specified frequency hopping sequence. The timing control block 1655 controls the Bluetooth clock. The power manager 1657 shuts off functions when they are not being used. A BlueRF Interface 1651 handles the overall system/radio interface. The flow control 1643 handles the Bluetooth data flow control automatically, which is another hardware function that can be removed from the firmware.
Figure 17 is a block diagram of an integrated circuit according to an embodiment of the invention. The embodiments of the invention are generally contained in the blocks labeled TX (transmit) FIFO 1703 , RX (rece ve) FIFO 1705 and HCl PCM block 1707 within the Bluetooth baseband core 1709.
Some embodiments of the present invention relate, in general, to the fact that HCl functionality that is usually handled in firmware will be done in hardware. In a first embodiment of the invention, the data comes from a host and is formatted in HCl packets. Commonly, the
HCl firmware will take the HCl packets and then form firmware packets and then form 64 byte fragments and write them into the appropriate FIFO.
In the first embodiment of the current invention the forming of HCl packets into fragments is done in hardware. Hardware receives the HCl packets and then forms the firmware packets and the 64 byte fragment formats itself automatically.
A second embodiment of the invention is similar to the first embodiment except that the data flow is in the opposite direction. Instead of taking HCl packets from the host, in the second embodiment, over-the-air packets are received and then HCl packets that will go to the host are formed.
In a third embodiment of the invention, hardware automatically transmits HCI_Number_Of_Completed_Packets to the host, these events indicate how much buffer space in the Bluetooth device has been made available by data in the buffer having been transmitted and acknowledged, or otherwise flushed. In a fourth embodiment of the invention, hardware automatically receives the
HCI_Host_Number_Of_Completed_Packets command from the host telling the Bluetooth device how much buffer space in the host has been freed since the last such command, so that the Bluetooth device doesn't send too much data to the host.
An important aspect of embodiments 1 through 4 is that no intervention from firmware is required.
In a fifth embodiment of the invention, the first tlirough fourth embodiments are present. In addition, the firmware counterparts are present. The functions present in the first through fourth embodiments can be switch between hardware and firmware. Such switching ability may be used by Bluetooth system designers to save power, increase speed or a variety of other reasons.
In a sixth embodiment of the invention, the hardware has the ability to automatically set or clear the standard Bluetooth control flow bits of FLOW, ARQN and SEQN of transmitted Bluetooth packets based on the flow control bits of received packets, on RX FIFO status, and on various error checks in the physical data path such as FEC (Forward Error Correction)and CRC (cyclic redundancy check).
In a seventh embodiment of the invention the ability to automatically choose the Bluetooth packet type and length for transmission is incorporated in the hardware. An advantage of the seventh embodiment is that by pooling the fragments in the memory, if there are less than seven slaves, then the slaves that are present are free to use the whole memory. In addition, memory space may be dynamically allocated to each connection according to Bluetooth specified quality of service. For example, a connection may have a parameter indicating the maximum amount of quiet time that is allowed before more data must be sent. Each connection might have a different value for quality of service and accordingly, the proposed FIFO structure allows for variable memory allocation to each connection. In an eighth embodiment of the invention, the
SCO frame are automatically scheduled in hardware. Another advantage of embodiments of the invention is that it makes the calculation of the HCI_Number_Of_Completed_Packet events easier to calculate. The HCl layer tells the host how many HCl packets have been completed (flushed from the transmit FIFO). An embodiment of the invention maps HCl packets to firmware packets one to one. The number of completed HCl packet is equal to the number of flushed firmware packets. Therefore the embodiment need only count firmware packets. As it is flushing fragments from the FIFO to determine the number of completed HCl packets. So now its easy for hardware to inform the HCl layer what free buffer space is available to send packets to the host. An additional advantage is that the L2CAP and LMP buffers are separated. The LMP buffer is accessed by firmware. The LMP buffer is generally not accessed by hardware. The L2CAP FIFO accesses may be by firmware or hardware depending on which mode the system is operating in. If the HCl is being done in firmware then the firmware will be accessing the L2CAP FIFO and if the HCl function is implemented in hardware, then hardware will be accessing it the L2CAP FIFO. Since LMP lies in firmware, by separating the LMP and L2CAP functions firmware never has to access the L2CAP FIFO. Firmware can access the LMP FIFO whenever necessary.
Another advantage in embodiments of the invention is that sometimes it is necessary to flush data from a FIFO. If it was desired to flush an L2CAP packet out of the FIFO but not and LMP packet it would be difficult if both packets were in the same FIFO. In essence, L2CAP packets can be flushed without touching the LMP packets.
Figure 18 is a graphical illustration of packet traffic on a piconet, which has an SCO connection with a period of six (T=6). In addition to SCO transmissions certain types of ACL transmissions may also have periodic behavior, and as such the following discussion is pertinent to them as well as to SCO transmissions. A slot counter counts in sync with the Bluetooth slot clock. In the present example, Figure 18 illustrates a counter for an SCO connection with the T=6 and 0=2. Figure 18 illustrates a slot clock with a period of 6 slots (e.g. 1809), which are numbered from 0 to 5 conesponding to the slot counter. For example, slot 1803 is numbered 5 and slot 1805 is numbered 0. The slot counter will count from 0 to T-l(=5). The SCO slots occur when the slot counter = 2 and 3 since D=2. The counter then counts 4, 5, 0, 1 and 2.
The Bluetooth specification indicates that in order to initialize the slot counter the Bluetooth counter is taken modulo T. Accordingly, whatever the Bluetooth clock is equal, that number is taken modulo 6 and the result is the initial counter value. In the present case if the period is 6 then the Bluetooth clock modulo 6 yields the slot counter value. If the period of the periodic transmission is N, then the Bluetooth clock modulo N is equal to the slot counter.
In a eighth embodiment of the invention, a hardware circuit for computing the value of the Bluetooth clock (or any number) modulo N is described. The Bluetooth specification is somewhat more specific. There are actually two cases. In the first case, if the most significant bit (MSB) of the Bluetooth clock is 1 it is inverted prior to doing the modulo calculation. If the
Bluetooth clock MSB is 0, the modulo calculation proceeds as is and the result is then the slot counter value. So ultimately, a 27 bit value which is the Bluetooth clock with the MSB either inverted or not is taken modulo the period (in the present example 6) and the result is the initial slot counter value.
When the slot counter, which is used for Slot Gauge, is initialized, a modulo divide operation is performed. The Bluetooth clock is modulo divided by a number T, which represents the period of a scheduled periodic transmission, which forms the bounds for the transmission of other packets. There are other functions within a Bluetooth system that may use a similar modulo divide of the Bluetooth clock. A further embodiment of the invention comprises a circuit and method for providing a modulo divide operation, exemplarily of the Bluetooth clock.
Figure 22 is a schematic diagram used to provide a modulo divide of the 27 bit Bluetooth clock by "T", an 8 bit number. In Figure 22 the 27 bit T value of the Bluetooth clock is serially shifted into flip-flop 2220 one bit at a time MSB (most significant bit) first. The output of flip flops 2220 through 2128 form a 9 bit bus 2219, with flip flop 2228 comprising the MSB and flip flop 2220 comprising the LSB. The 9 bit value of bus 2219 is provided to the "B" input of comparator 2211. The modulo divisor is provided to the circuit on 8 bit bus 2203. The 8 bit value provided by bus 2203 represents the modulo divide value "T". An additional "0" bit is concatenated to the MSB of the value of "T" appearing on bus 2203, producing a 9 bit value of "T" . The 9 bit value of "T" is coupled into the "A" input of comparator 2211. If the value of the
9 bit value of "T" is greater than or equal to the value on the 9 bit bus 2219 then the output of comparator 2211 controls a multiplexer 2209. If the multiplexor's 2209) control signal i.e., the comparator 2211 output, is a "1" then a two's compliment (2205) value of "T" is provided to summation unit 2213. If the output of comparator 2209 is a "0" then the 8 bit value of "T" is provided to summation unit 2213. Summation unit 2213 is also provided an input from the output of flip flops 2220 through 2227. The output of the summation unit 2213 is then coupled into the inputs of flip flops 2221 through 2228. Once the circuit has run for 27 clock cycles the answer for the modulo divide appears at that output of flip flops 2220 tlirough 2228. This method may be extended to any modulo calculation. This method will produce an answer in a number of clock cycles equal to the number of bits in the dividend of the modulo divide.
Figure 23 is a graphical illustration fo the computational values to do an exemplary 115,307,261 mod 135. Value 2303 represents 115,207,261 in binary. Value 2305 represents the value of the dividend 135. The intermediate values produced at the different clock times is represented for clock time (t) = 9 tlirough 27. The intermediate values represent the outputs of flip flops 2220 tlirough 2228 in Figure 22, the answer is produced at 2311.
The modulo divide may be used by Slot Gauge for SCO transmissions or for any other types of periodic transmissions, such as Beacons and Sniffs. Bluetooth mechanism which require regular periodic transmissions. Such as SCOs. Bluetooth has a Beacon which is used when a slave is temporarily put out of action. This mode is called park mode. The master periodically broadcasts a beacon to the parked slaves. The slaves can use the beacon to determine when to wake up. The beacon is analogous to an SCO channel because it broadcasts with a fixed period. Sniff slots are also periodic. So SCO, beacon and sniff are three Bluetooth functions that may use a Slot Gauge circuit having a modulo divide. Beacon and sniff would require 16 bit divisor quantities instead of just 8, which could be accommodated in the circuit of Figure 22 by adding flip flops to the flip flop chain 2220 tlirough 2228 and enlarging the bus paths and circuit elements by 8 bits.
The description of the hardware circuits may be implemented in a variety of ways in the present embodiment they were written into Verilog RTL and then the Verilog synthesizer maps them into gates.
Ninth embodiment of the invention comprises an auto segmenter. There are three pieces of information that the hardware needs in order to automatically segment the data into the over- the-air packets. The first piece of the information needed is how many slots are available. For • example, if there is any SCO connection with a period of six, it uses two slots out of every 6 for SCO transmission. Accordingly, to auto segment data the number of free slots must be determined. The second piece of information is what types of packets are allowed. The third piece of information that must be determined is how much data there is in a transmit buffer to send. The hardware needs to know all three pieces of information in order to choose a packet type. Those skilled in the art will require that the described auto-segmenter may be realized in other technologies such as firmware or a combination of hardware and firmware.
The function of the "Slot Gauge" mechanism is to tell the hardware how many slots are available to transmit or receive packets between periodic transmissions, such as an SCO transmission. The Slot Gauge informs the hardware how many contiguous slots are currently available in the active piconet. The computation of available slots is complicated by the fact that if two piconets are active you might have Bluetooth clocks that are skewed from one another. In the case that the Bluetooth clocks from the two piconets are not in phase synchronization, the phase relationship of the two piconets needs to be accounted for in order to figure out how many slots are available. Figure 19A a is graphical illustration of unsynchronized piconets. In Figure 19A three separate piconets 1903, 1905, and 1907 are illustrated. Each piconet has its own timing. Piconet 1907 represents the active piconet. The phase of piconet 1907 is different from the phase of piconet 1903 and piconet 1905. Piconet 1903 has a slot 1909 which is scheduled, and piconet 1905 has a slot 1911 that is scheduled. Figure 19B is a graphical illustration of the timing of the "Slot Gauge." The following description of " Slot Gauge" describes a hardware implementation. Those skilled in the art will recognize the other implementations may be accomplished in software, firmware, or can comprise a combination of tecliniques. The Slot Gauge output updates on the rising edge of Bluetooth clock bit 0, for example 1947, of the currently active piconet, and is stable for 625 μ sec, which is equal to one slot period. There are four values provided by Slot Gauge that are required in order to determine how many slots are available for transmission or reception of data. The first value, SM TX, represents the number of slots available for transmission for a master. The value for SM τx will be used by a hardware packet segmenter to decide which type of data packet to use for transmission. For example, if all packet types are allowed and SM τx is 5 or greater then any packet type may be used. If SM>TX is less than 5, DM5 and DH5 packets may not be used. If SM TX is less than 3, neither DM5, DH5, DM3, nor DH3 packets will be allowed.
The second value, SM RX, represents the number of slots available for reception by a master. SM RX is equal to the number of available slots, including the current slot, available for packet reception. SM RX is used by the receive hardware. The receiver hardware decoders the TYPE field in the received packet header, and if the packet requires more than SM RX slots, packet reception is aborted.
The third value, Ss τx, represents the number of slots available for transmission by a slave type device. Ss τx has the same use as SM τx. Since a device may be both a master and a slave both SM τx and Ss τx values may be needed by a device.
The fourth value, SS RX, represents the number of packets available for reception by a slave. Ss RX has the same us as SM RX. Since a device may be both a master and a slave both SM,RX and SSjRX may be needed by a device.
The Slot Gauge algorithm assumes that each isochronous channel (SCO, sniff, or beacon) is controlled by a dedicated counter called C, that counts from 0 to Trl is the period in slot clocks, with the frame beginning when C;=D;. Furthermore, is aligned with the piconet clock for the piconet using this counter in the sense that increments on every falling edge of
Bluetooth clock bit 0 (every whole slot boundary). Slot Gauge computations are performed on a snapshot of the state of the inputs at the rising edge of Bluetooth clock bit 0. The following steps describe the Slot Gauge algorithm. It should be noted that S (i) can be computed other ways if C(i) is not available. For example, it could be calculated by subtracting the current Bluetooth clock in P(i) from the Bluetooth clock value where periodic transmission will occur (e.g., 1909 and 1911). Alternative, C(i) could be replaced with a down-counter. This down- counter would effectively be equal to S](i).
1. Determine how many whole slots, S] (i)} there are before C(i) reaches D(i) . Sj (i) is the number of whole slots in the piconet clock with which C(i) is aligned.
Sl(i) = D(i) - C(i) + T(i - 1 if C(i) > = D(i)
S (i) = Dp) - C(i) - 1 if C(i) < = D(i) 1 2. Determine the 1 MHz phase (with respect to the beginning of a slot) phase
[P(C(i))J, of the piconet clock with which C(i) is aligned, and the 1 MHz phase of the active piconet 1907, phase [PacllvJ. The phase has a resolution of 1 μ sec, 0<=P<=624.
5 3. Put S] (V (e.g. 1955) in terms of slots on piconet Puctιva 1907.
Sβ (e.g. 1953) = Sj ) - (phase [Pacli )
where (phase [P(C(i))J > (phase [PacllvJ) is an element of {0,1} where 0=false, i=trae. If phase [P(C(i))J > phase [PactivJ, then Sj ), takes values in the range [-1, T(i)-lJ. I o Otherwise it will take values in the rant [0, T(i)-lJ.
4. Negative numbers are set to zero as shown below. S3(i) = 0 ifS ^ < 0
S ) = S2(^ otherwise
15
The number of slots available in Pactjve is the minimum ofSj ) for all values of
S = min (Sj3) for all i S = min (S3(i)) for all i. 0 Accordingly in 1903 S3(i) = S2(i) and in 1905 S3(l) = S2(2) = 1 then S2(2) = 0
6. The Slot Gauge value is modified according to whether the device is a master or a slave, and whether availability for RX or TX packets is needed. If the device is a transmitting master, one slot is subtracted from the Slot Gauge output to allow for a one slot 5 reply from the slave. If the device is a receiving slave, one slot is subtracted from the Slot Gauge output to again allow for at least a one slot reply. If the subtraction of one from the Slot Gauge value results in a negative number, 0 is used instead of the negative number. All negative results are set to zero. Master:
30 SM.TX = 0 ifS - l < 0
SM,TX = S-1 otherwise
SM.RX =s
Slave: ,s;rx = S
35 >S,RX = 0 ifS - i < 0
Ss.nx = S-1 otherwise 1 The second piece of information that the transmit hardware auto segmenter needs in order to choose the packet type and length is the number of bytes of data available in the transmit FIFO to be transmitted. The number of bytes of data available to be transmitted may be determined by counting the bytes in the transmit FIFO.
5 The Byte Gauge will determine how many bytes are in the transmit FIFO for a particular connection transmission. Byte Gauge determines the number of bytes using a pointer which sequences tlirough the fragments for the particular connection transmission. Byte Gauge assumes one connection is active and Byte Gauge takes the cunent read pointer for that connection and sequences through the fragments until it hits the write pointer, all the while
10 totaling up the bytes encountered. In other words the Byte Gauge is going to take where the read pointer is at and figure out how many bytes there are. The totaling process stops when it hits the write pointer, but other events may stop the totaling of the bytes also. There are other events that may stop the totaling of bytes by the Byte Gauge. For example Byte Gauge will terminate the totaling if it hits an L2CAP boundary. L2CAP boundaries are marked within the
15 fragments as discussed earlier.
The Byte Gauge will stop totaling at a L2CAP boundary, it won't try to got any further because the transmission cannot straddle a L2CAP boundary. Additionally the Byte Gauge will stop counting once it counts 339 bytes because the largest possible packet that can be transmitted is 339 bytes, the there is no reason to count any further than 339. So the Byte
20 Gauge stops counting when it encounters the write pointer, an L2CAP boundary, or when it counts 339 bytes, whichever comes first. The Byte Gauge is a quick algorithm because each of the fragments has a length field. So assuming Byte Gauge knows where the read pointer is, and knows the length of the fragment it can very easily jump, in few clock cycles, from fragment to fragment and add the number of bytes.
25 So the Byte Gauge process starts out at 2503 when the base pointer Bptr is loaded into the temporary pointer Tptr and the accumulator ACC is set to 0. In step 2507 a flag, telling Byte Gauge whether at least 1 byte has been written in the transmit FIFO. Assuming there has been a byte written Byte Gauge checks in step 2505 to see if Tptr is residing at the beginning of a fragment. If Tptr is at the beginning of a fragment control is transfened to step 2519. If
30. the temporary pointer is not pointing to the beginning of a fragment control is transfened to 2511 where the write pointer bits MSB tlirough 6 are checked to see if they are equal to the temporary pointer. This checking is to see if the write pointer is in the cunent fragment. If the write pointer is in the current fragment then control is transfened to 2513 and the process terminates in block 2537. If the Wptr is not in the cunent fragment then the dent is added to
35 the accumulator. The down-count is the number of bytes left in that fragment. Control then passes to 2517 where the Tptr is loaded with the value of the Lptr. Next in 2519, the FF, LF and then the length field is read from the header fragment. And then in block 2521, FF is checked to see if FF=1. If FF=1 , then in 2523 the write pointer is check to see if its equal to the temporary pointer. If the Wptr is not, equal to the temporary pointer then in 2525 subtract one from the length because if this is the first fragment. If FLEN equals 1 then that means that are actually two header bytes instead of just one. In 2531 , the L_CH field is checked. If the L CH field is "10" we are going to stop in 2531 because "10 means the starting the L2CAP otherwise control is transferred to 2533 to check again to see if the Wptr is in the current fragment. If it is in the current fragment, then the Wptr minus the Tptr will be added to the accumulator and then the process stops in 2537. Otherwise if Wptr does not equal Tptr then FLEN is added to the accumulator and control is transferred to 2541 to check to see if the accumulator is 339. If the ACC is not equal to 339 control is transferred to block 2517, otherwise if the ACC does not equal 339 the process stops .
Another facet of embodiments of the invention is that the system firmware may mask off certain packet types any way it wants to. For example, perhaps because of the quality of service desired it may be necessary to transmit only packets having error correction.
Once the 3 necessary pieces of information are determined, the transmit packet type an length may be selected using the following packet type/length selection rules.
Packet Type/Length Selection a) The first priority is to transmit as many bytes in the buffer as possible. If there are more bytes than the largest allowed type, then the allowed type that can hold the most bytes is chosen, regardless of whether it has encoding or not.
Example: DM1, DM3, DH1, DH3 allowed, bytes available = 122. DH3 is chosen. b) The smallest packet that is big enough for the number of bytes available is chosen. Example: DH1, DH3, DH5 allowed, bytes available = 128. DH3 is chosen. c) If packet types with encoding and types without encoding are both allowed, and either kind is big enough to hold the number of bytes available for transmission, the type with encoding is chosen, as long as it is the smallest possible packet in terms of number of slots. If the smallest possible packet type is not a type with encoding, a type without encoding is chosen.
Example 1: DM1, DM3, DH1, DH3 allowed, bytes available = 64. DM3 is chosen
Example 2: DM1, DM3, DH1, DH3 allowed, bytes available = 15. DH1 is chosen. Figure 20 is a table relating the number of bytes to be transmitted to the packet type priority. For example, if there is between 1 and 17 bytes in the buffer, the first choice is a DM1 type packet. The second choice is a DH1 type packet. The reason is these packets are chose is that the DM1 packet may hold up to 17 bytes, the DH1 packet type may hold up to 27. The DM1 packet also contains forward enor conection so it holds less data but both are one slot.
So by choosing a DM1 or DH1 the least DM1 and DH1 bandwidth is used. Because one slot is used instead of three, the remaining 2 slots are free for other uses. The first choice is the DM1 because that is the one that has the forward error conection and so is more robust than DHL The third choice would be a DM3, which occupies three slots, but if for some reason
DM1 and DH1 are not allowed a DM3 and then DH3 will be chosen. If nether DM1, DH1, DH3 or DM3 is allowed then DM5 and DH5 are chose according to the table of Figure 20.
Similarly packets are chose for other ranges of number of bytes to be transmitted. First the number of bytes is fitted into a range. Then the packet type is chosen by selecting the first type of packet that is allowed from the choices in the table. By using the table in Figure 20 packet types may be automatically selected from the table of Figure 20. The packet type is chosen by selecting the packet type that takes the least amount of space as a first criteria, and then selecting the packet that gives the most error correction. Since packet size is the first criteria for selecting packet types, the packet type selected may or may not have error correction. (using the table to select packet type for transmitting in a Bluetooth network is one of the claim areas). An important aspect of the present embodiment is that the segmenter's type and length selection for a given connection is not changed until that packet has been actually or otherwise flushed.
Another embodiment of the invention comprises a method by which unprotected fragments are selected to form a transmit FIFO. This embodiment is a way of choosing the lowest fragment to incorporate into a transmit FIFO. As discussed previously, a transmit FIFO is formed for a connection by stringing together fragments to hold the data to be transmitted to a particular connection. Each fragment is associated with a bit in the bit protect array 1011 (See Figure 10). The present embodiment of the invention selects the lowest number fragment which has a protect array value of 0, that is it selects the first unprotected (unused) fragment.
Figure 21 is a schematic diagram of a fragment chooser circuit that accepts protect bits and produces the index of the lowest unoccupied fragment. So, for example, if fragments 0, 1, 2, 4, and 5 are occupied and the rest of the fragments are unoccupied, the fragment chooser will choose fragment 3 next. The fragment chooser illustrated in Figure 21 is simplified one having only 16 fragments instead of 128. So if fragments 0, 1 and 3 were protected, the fragment chooser would output a value of 2. The fragment chooser is composed of a number of identical blocks 2111. The blocks are repeated multiple times (2103 A through 2103H, 2105 A through 2105D, 2017A and 2017B, and 2109 A). The example of Figure 21 is an Implementation of a 16 packet chooser which will select the lowest value of fragment, of 16 fragments, which is unprotected. The translation of the illustration of Figure 21 to handle 128 fragments is straight forward. In a fragment chooser choosing from 128 fragments, the first level would have 64 blocks instead of 8 blocks (2103 A through 2103F) of the exemplary circuit. Additionally, in „ the one of 128 fragment chooser the blocks 2111 would have a 7 bit input at X3 and X4 and a 7 bit output at Y2.
The blocks of the selector circuit (i.e., 2103A tlirough 2103H, 2105A through 2105D, 2107 A, 2107B and 2109 A) are identical. That is the multiplexor 2119 switches between input X3 and input depending on the output of 2115 circuit. An if the output of circuit 2115 is a 1 if X1>X2, that is if Xl=l and X3=0. If the output of circuit 2115 is a 1 then multiplexer 2119 couples the value on X4 into circuit 2117. If the output of circuit 2115 is a 0 then multiplexer circuit couples the value of X3 into circuit 2117. Circuit 2117 is a shifter/concatenator circuit. It is going to take the value coupled to its B input shift it to the right by one and then insert the bit from the output of circuit 2115 to the MSB and then put the shifted and concatenated value at output Y2.
Circuit 2113 is an OR circuit which accepts XI and X2 as its input and puts out a 1 if either or both inputs are 1 (unprotected).
Figure 24 is a graphical illustration of the operation of an automatic transmit FIFO according to an embodiment of the invention. For example suppose a Bluetooth transmission
2403 is followed by the reception of an acknowledgment of the transmission 2405. Since transmission 2403 has been acknowledged the transmit FIFO may remove the protection on the fragments used to make up the transmission 2403. For example, consider a portion fo the transmit FIFO illustrated at 2400. Fragments N tlirough N+5 are visible in the illustrated portion ofthe transmit FIFO 2400. Fragments 2409, 2413 and 2415 are being used by another connection not related to transmission 2403.
In the example illustrated in Figure 24 the transmission 2403 will comprise portions of fragment 2407, 2411, and 2417. The base pointer 2425 represents the beginning of the transmission 2403. The base pointer 2425 and a forward pointer 2427 are initially pointed to the same location. The transmission 2403 sent and the forward pointer 2427 is pointing as shown in Figure 24. The write pointer 2429 is pointing to the end of fragment 2417 indicating that more data has been placed in the transmit queue. Once transmission 2403 has been acknowledged base pointer 2425 can be advanced forward pointer 2427. Once base pointer 2425 has advanced tlirough fragment 2407, the protection of fragment 2407 may be removed. The base pointer may then be advanced through fragment 2411 and then the protection on fragment 2411 can be removed, making that fragment available for general use. The base pointer 2425 will then be advanced to the position of the forward pointer 2427. The base pointer will then end up pointing at the same byte as the forward pointer 2427. The memory protection on fragment 2417 cannot be released because, as read pointer 2429 indicates, data remains in fragment 2417.
If the response 2405 of the transmission 2403 is an NAK (not acknowledged) the transmission must be repeated, and the forward pointer is set to point at the position ofthe base pointer 2425, and the transmission 2403 is then set to be repeated. The forward pointer will trace a path through fragments ofthe transmit queue until the value of Byte Gauge says all bytes have been transmitted, or until 339 bytes have been transmitted or until an L2CAP boundary (for example if 2421 were an L2CAP boundary) is encountered. Figure 25 is a flow diagram of the Byte Gauge process. (TED this description may require some work also) Several definitions are helpful in understanding flow diagram 2501. ACLX represents the data in the ACL RAM (transmit FIFO) address location X. ACC is an accumulator amount. Bptr is the base pointer, such as the base pointer 2425 of Figure 24. The dent is the fragment based down-count. That is the number of bytes (to transmit) left in the current fragment to which the base pointer is pointing. FF is the first fragment bit, FF is contained in the fragment. FLEN is the amount of data contained in a fragment. FLEN is in the header also. Lptr is a link pointer. L_CH is the L2CAP field that is indicating start or continuation. A value "10" means start, a value of "01" means continuation. LF is the ast fragment bit. And then Tptr is the temporary pointer. The variable "Past First Pass " PFP is included for the following reason. The Byte Gauge algorithm stops when it encounters an L2C AP boundary, indicated by a fragment with FF= 1 and L_CH=10. However, just before any data belonging to a new L2CAP packet has been transmitted, the read address is already pointing to the first byte of a fragment with FF=T and L_CH=10! Without the "Past First Pass" variable, the algorithm would stop right there, before it had even started, because it encountered that L2CAP boundary immediately! The "Past First Pass" variable prevents the algorithm from stopping when it immediately encounters an L2CAP boundary. The initial L2CAP boundary is the "First Pass"; initially, "Past First Pass" is set to zero so that when the "First Pass" is encountered, the algorithm does not stop. Once the Byte Gauge has encountered "First Pass" once, it is "past the First Pass", so it sets the "Past First
Pass" variable to one, indicating that the algorithm should stop on any subsequent L2CAP boundaries.
Figure 26 is a flow diagram illustrating the L2CAP packet flush state machine, according to an embodiment ofthe invention. The flow diagram starts with block 2601 , which waits for the acknowledgment of a packet conectly received. When the acknowledgment comes, control is transferred to 2603. In 2603, the base pointer is checked to see if the forward pointer is in the same fragment. If the base pointer is not in the same fragment as the forward pointer control is transfened to block 2605. In 2605 the write protection ofthe current block is reset (unprotected). The base pointer (bp) is then moved to the next fragment, that is the linked list is followed to the next fragment. Control is then transfened back to block 2603 where the forward pointer is checked to see if it is in the same fragment as the base pointer (bp). If the base pointer is in the same fragment as the forward pointer (the forward pointer currently is pointing to the end ofthe packet) the result of block 2603 will be yes and then in block 2609 the base pointer is set equal to the forward pointer, the base counter is set equal to the forward counter, and control transfers to block 2601.
Figure 27 is a flow diagram of an L2CAP packet transmit state machine, according to an embodiment of the invention. The initial state 2731 of the L2CAP packet transmit state machine is a wait for a request state. The request comes from the physical layer hardware, for example from the hardware doing forward enor conection, encryption and whitening, which will be done prior to transmission of data. Once the request is made, in block 2733 the forward pointer 1006 is set equal to the base pointer 1005. If the previously sent packet was not acknowledged, the forward pointer would be pointing to the end ofthe unacknowledged packet. In that case the unacknowledged packet would need to be resent and the forward pointer 1006 would need to be set equal to the base pointer 1005. Then the variable pb is set equal to the packet length in bytes. The variable pb will be used as a down counter to count the bytes as they are sent. Also in step 2733 data-out is set equal to the first byte ofthe Bluetooth header, BBHl. BBHl is determined entirely by the segmenter, so that at step 2733 nothing has been taken out of the transmit FIFO e.g. 903. The state machine then waits for another request at 2735 from the physical layer hardware. Once the request is received flow control bits for the Bluetooth packet header are provided. The state machine then waits for another request at 2739. When the next request anives data-out is set equalto PLH1 which is the payload header. The payload header is either one or two bytes depending on whether its packet being sent is a multi-slot packet or a single slot packet. Data-out is determined by the segmenter. The state machine then waits for another request at 2701. Nothing has been read for the transmit FIFO yet. Once the next request anives control transfers to 2705. In 2705, if the segmenter has chosen a multi-slot packet then the physical layer would be provided with the second byte of the payload header, as indicated in 2703, and then the state machine awaits the next request in 2707. Once the next request anives control transfers from block 2707 to block 2709. If, in block 2705 , the segmenter had not indicated that a multi-slot slot packet was being sent, control would also transfer to block 2709.
In block 2707 a forward count (FC) down counter, is examined. The forward count down counter counts down from the fragment length. The FC as well as BC, a base down counter, start out with the value ofthe fragment length and then count down. These counters are needed because the state machine needs to know when one fragment is finished, in order to jump to another fragment. So if FC = 1, the end ofthe fragment has not been reached yet and control transfers to block 2723, where the forward pointer is incremented, the forward count is decremented, and the payload byte down-count is decremented. If FC = 0, the end of a fragment has been reached and control transfers to 2711, which asks is the base pointer bits 5 though 0 equal to 0? If yes, then the end of a fragment has actually not been reached; rather, the forward count has not been loaded yet. Control transfers to block 2715, where the fragment header is read from the memory location indicated by the base pointer. If the answer to block 2711 is no, then the end ofthe fragment has truly been reached and control transfers to block
2713, where the base pointer is moved to the beginning ofthe fragment indicated by the link list. Control then transfers to block 2717 where FC is loaded with the length field of the fragment header. The FC down count is going to count down from the length ofthe fragment. Control is then transfened to 2719, which asks if the cunent fragment is a first fragment? In other words is the FF bit equal to 1? If it is then it is necessary to read out one extra byte because the first fragment has one extra byte indicated by the L_CH field. If there is one extra byte, the forward count is decremented and the forward pointer is incremented, and then control is transferred to a block 2723 where the forward pointer is incremented, the forward count is decremented, and the packet byte count is decremented. Control is then transfened to 2725. In 2725 the data_out is set equal to the value of the memory anay at the address location indicated by the forward pointer from the memory. The data_put is, once again, the byte that is being provided to the physical layer and control transfers to 2729. In Block 2729, the packet byte, is examined to see if the PB count has counted down to zero. If the PB count has not counted down to zero then control is transfened to block 2707, otherwise control is transferred to block.2731 at the begimiing and waits for a request which will be the next packet. Now if the next packet is going to be a retransmission then what will have happened is the base pointer would have not moved up to the forward pointer. In other words, after the current packet the base pointer will stay where it is the forward pointer will be pointing to the end ofthe packet. But then when the packet is retransmitted the forward pointer will be reloaded with the value ofthe base pointer, in other words it will rewind back to the beginning ofthe packet. In block 2733, PB equals packet length. That packet length is chosen by the segmenter. In a retransmission a packet length will not have changed so exactly the same bytes will be read from the FIFO. Therefore the packet will be exactly the same as the previous one. Although a preferred embodiment ofthe present invention has been described, it should not be construed to limit the scope of the appended claims. Those skilled in the art will understand that various modifications may be made to the described embodiment. Moreover, to those skilled in the various arts, the invention itself herein will suggest solutions to other tasks and adaptations for other applications. It is therefore desired that the present embodiments be considered in all respects as illustrative and not restrictive, reference being made to the appended claims rather than the foregoing description to indicate the scope ofthe invention.

Claims

WHAT IS CLAIMED IS:
1. A wireless communications device, comprising: a wireless transceiver; and a processor coupled to the wireless transceiver, the processor having a memory comprising a plurality of fragments and an anay configured to control the sequence of memory fragments from which data is read.
2. The wireless communications device of claim 1 wherein the processor further comprises a second anay configured to indicate a status of each ofthe memory fragments.
3. The wireless communications device of claim 2 wherein the status indicated by the second array for each of the memory fragments comprises a bit to indicate whether its respective memory fragment is empty.
4. The wireless communications device of claim 1 wherein the processor further comprises a read pointer configured to indicate the memory fragment from which the data is being read.
5. The wireless communications device of claim 1 wherein each ofthe memory fragments comprises 64 bytes.
6. The wireless communications device of claim 1 wherein the memory fragments comprises 128 memory fragments.
7. The wireless communications device of claim 6 wherein the anay comprises a 128 element array.
8. A processor comprising a memory having a plurality of fragments and an anay configured to control the sequence of memory fragments from which data is read.
9. The processor of claim 8 further comprising a second array configured to indicate a status of each ofthe memory fragments.
10. The processor of claim 9 wherein the status indicated by the second array for each of the memory fragments comprises a bit to indicate whether its respective memory fragment is empty.
11. The processor of claim 8 further comprising a read pointer configured to indicate the memory fragment from which the data is being read.
12. The processor of claim 8 wherein each ofthe memory fragments comprises 64 bytes.
13. The processor of claim 8 wherein the memory fragments comprises 128 memory fragments.
14. The processor of claim 13 wherein the array comprises a 128 element array.
PCT/US2001/005064 2000-02-16 2001-02-16 Bluetooth baseband solution with reduced processor requirements and integrated host controller WO2001061936A2 (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
DE60138456T DE60138456D1 (en) 2000-02-16 2001-02-16 BLUETOOTH BASEBAND SOLUTION WITH REDUCED PROCESSOR REQUIREMENTS AND INTEGRATED HOST CONTROL
EP01910848A EP1257919B1 (en) 2000-02-16 2001-02-16 Bluetooth baseband solution with reduced processor requirements and integrated host controller
AU2001238411A AU2001238411A1 (en) 2000-02-16 2001-02-16 Bluetooth baseband solution with reduced processor requirements and integrated host controller
AT01910848T ATE429677T1 (en) 2000-02-16 2001-02-16 BLUETOOTH BASEBAND SOLUTION WITH REDUCED PROCESSOR REQUIREMENTS AND INTEGRATED HOST CONTROL

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US18307600P 2000-02-16 2000-02-16
US60/183,076 2000-02-16

Publications (3)

Publication Number Publication Date
WO2001061936A2 true WO2001061936A2 (en) 2001-08-23
WO2001061936A3 WO2001061936A3 (en) 2002-07-18
WO2001061936A9 WO2001061936A9 (en) 2003-10-23

Family

ID=22671343

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/US2001/005064 WO2001061936A2 (en) 2000-02-16 2001-02-16 Bluetooth baseband solution with reduced processor requirements and integrated host controller

Country Status (6)

Country Link
US (1) US7546099B2 (en)
EP (1) EP1257919B1 (en)
AT (1) ATE429677T1 (en)
AU (1) AU2001238411A1 (en)
DE (1) DE60138456D1 (en)
WO (1) WO2001061936A2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2002058330A2 (en) * 2001-01-17 2002-07-25 International Business Machines Corporation Digital baseband system
WO2003025759A1 (en) 2001-09-19 2003-03-27 Intel Corporation Increasing code separation between applications
EP1309134A1 (en) * 2001-10-31 2003-05-07 Samsung Electronics Co., Ltd. Master for bluetooth communication and method for establishing beacon channel thereof
US7031270B2 (en) 2000-10-30 2006-04-18 Samsung Electronics Co., Ltd. Master for bluetooth communication and method for establishing beacon channel thereof
EP2603033A3 (en) * 2007-06-26 2013-12-18 Nokia Corporation Apparatus, method and computer program product providing distribution of segmented system information

Families Citing this family (32)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB0009250D0 (en) * 2000-04-15 2000-05-31 Koninkl Philips Electronics Nv Communications system
JP2002252617A (en) * 2001-02-22 2002-09-06 Sony Corp Wireless communication device and its method
US6973071B1 (en) * 2001-03-06 2005-12-06 Rfmd Wpan, Inc. Method and apparatus for controlling the flow of data in a wireless communication system
US7209470B2 (en) * 2001-03-16 2007-04-24 Intel Corporation Method and apparatus for encapsulating universal serial bus messaging over link layer communication protocol
US7120390B2 (en) * 2001-03-21 2006-10-10 Agere Systems Inc. BLUETOOTH smart offset compensation
GB2374767B (en) * 2001-03-21 2005-04-13 Agere Syst Guardian Corp Bluetooth smart offset compensation
DE10141815A1 (en) * 2001-08-27 2003-04-03 Siemens Ag Process for packet data transmission
EP1425883A1 (en) * 2001-09-10 2004-06-09 Nokia Corporation Method of transmitting time-critical scheduling information between single network devices in a wireless network using slotted point-to point links
US7123877B2 (en) * 2001-11-08 2006-10-17 Broadcom Corporation Baseband controller in a wireless local area network
US20030087658A1 (en) * 2001-11-08 2003-05-08 Jane Dashevsky Partitioning responsibility between link manager and host controller interface firmware modules in wireless systems
US7414991B2 (en) * 2001-11-14 2008-08-19 Intel Corporation Computing system and method to select data packet
US7496065B2 (en) * 2001-11-29 2009-02-24 Telcordia Technologies, Inc. Efficient piconet formation and maintenance in a Bluetooth wireless network
US20030112975A1 (en) * 2001-12-14 2003-06-19 Inventec Corporation, Taipe, Taiwan Transmission-reception method for a wireless device of an electronic equipment
US7505781B2 (en) * 2002-01-02 2009-03-17 Sierra Wireless, Inc. Core wireless engine
US20030162556A1 (en) * 2002-02-28 2003-08-28 Libes Michael A. Method and system for communication between two wireless-enabled devices
DE60324149D1 (en) * 2002-07-31 2008-11-27 Thomson Licensing PACKET PROCESSING ARCHITECTURE
JP2004186932A (en) * 2002-12-03 2004-07-02 Fujitsu Ltd Optical access system
JP4483271B2 (en) * 2003-11-19 2010-06-16 ソニー株式会社 Wireless communication apparatus and response data processing method for wireless communication apparatus
DE102004006510A1 (en) * 2004-02-10 2005-09-08 Infineon Technologies Ag Method and circuit for differential clock compensation between two clock systems
US7660611B1 (en) * 2004-03-25 2010-02-09 Cypress Semiconductor Corporation Wireless human interface device packet compression system and method for reducing power consumption
KR101244857B1 (en) * 2005-02-25 2013-03-19 톰슨 라이센싱 Radio communication device and radio communication system comprising same
JP5372499B2 (en) * 2005-06-16 2013-12-18 クゥアルコム・インコーポレイテッド Handoff in mesh wireless systems
US20090305634A1 (en) * 2006-05-25 2009-12-10 Duc Hai Dong Nguyen Device, Method, Computer Program and Chipset for Facilitating Data Exchange Between Two Piconets
EP2039070A2 (en) * 2006-06-27 2009-03-25 Nxp B.V. Scheduled coexistence
FR2906953B1 (en) * 2006-10-06 2008-12-05 Thales Sa SECURE SYSTEM FOR TRANSFERRING DATA BETWEEN TWO EQUIPMENTS.
US20080233892A1 (en) * 2007-03-19 2008-09-25 Bojko Marholev Method and system for an integrated vco and local oscillator architecture for an integrated fm transmitter and fm receiver
US8190716B2 (en) * 2007-08-24 2012-05-29 Broadcom Corporation Method and system for managing bluetooth communication using software or firmware filtering
US20130034061A1 (en) * 2011-08-02 2013-02-07 Broadcom Corporation Reverse direction protocol implementation
US9398490B2 (en) * 2013-03-15 2016-07-19 Trane International Inc. Method of fragmenting a message in a network
TWI519087B (en) * 2014-01-16 2016-01-21 曜鵬科技股份有限公司 Wireless bluetooth apparatus with intercom function and operating method thereof
US10051450B1 (en) 2017-09-06 2018-08-14 Texas Instruments Incorporated Bluetooth data forwarding
US11469783B2 (en) 2019-05-14 2022-10-11 Cypress Semiconductor Corporation Apparatus, systems, and methods for selecting a wireless device antenna for communication

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5426424A (en) 1992-05-08 1995-06-20 Motorola, Inc. Selective call receiver with database capability

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5680582A (en) * 1991-12-20 1997-10-21 Microsoft Corporation Method for heap coalescing where blocks do not cross page of segment boundaries
WO1995001020A1 (en) * 1993-06-25 1995-01-05 Xircom, Incorporated Virtual carrier detection for wireless local area network with distributed control
US6038636A (en) * 1998-04-27 2000-03-14 Lexmark International, Inc. Method and apparatus for reclaiming and defragmenting a flash memory device
US6223290B1 (en) * 1998-05-07 2001-04-24 Intel Corporation Method and apparatus for preventing the fraudulent use of a cellular telephone
US6026016A (en) * 1998-05-11 2000-02-15 Intel Corporation Methods and apparatus for hardware block locking in a nonvolatile memory

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5426424A (en) 1992-05-08 1995-06-20 Motorola, Inc. Selective call receiver with database capability

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7031270B2 (en) 2000-10-30 2006-04-18 Samsung Electronics Co., Ltd. Master for bluetooth communication and method for establishing beacon channel thereof
WO2002058330A2 (en) * 2001-01-17 2002-07-25 International Business Machines Corporation Digital baseband system
WO2002058330A3 (en) * 2001-01-17 2004-02-05 Ibm Digital baseband system
WO2003025759A1 (en) 2001-09-19 2003-03-27 Intel Corporation Increasing code separation between applications
SG111960A1 (en) * 2001-09-19 2005-06-29 Intel Corp Increasing code separation between applications
US7290104B2 (en) 2001-09-19 2007-10-30 Intel Corporation Increasing code separation between applications
EP1309134A1 (en) * 2001-10-31 2003-05-07 Samsung Electronics Co., Ltd. Master for bluetooth communication and method for establishing beacon channel thereof
EP2603033A3 (en) * 2007-06-26 2013-12-18 Nokia Corporation Apparatus, method and computer program product providing distribution of segmented system information
EP2790438A3 (en) * 2007-06-26 2014-11-26 Nokia Corporation Apparatus, method and computer program product providing distribution of segmented system information

Also Published As

Publication number Publication date
AU2001238411A1 (en) 2001-08-27
WO2001061936A9 (en) 2003-10-23
ATE429677T1 (en) 2009-05-15
DE60138456D1 (en) 2009-06-04
US20020151275A1 (en) 2002-10-17
EP1257919A2 (en) 2002-11-20
EP1257919B1 (en) 2009-04-22
US7546099B2 (en) 2009-06-09
WO2001061936A3 (en) 2002-07-18

Similar Documents

Publication Publication Date Title
US7546099B2 (en) Bluetooth baseband solution with reduced processor requirements and integrated host controller
US5495482A (en) Packet transmission system and method utilizing both a data bus and dedicated control lines
US5477541A (en) Addressing technique for storing and referencing packet data
US7756100B2 (en) Scalable synchronous packet transmit scheduler
CN1027209C (en) Data transfer apparatus
JP2562791B2 (en) Priority data transfer method and apparatus for wireless telephone peripherals
AU598917B2 (en) Improvements in or relating to data transmission systems and methods of transmitting data
US20030021262A1 (en) Bluetooth baseband controller
CN1333603A (en) Earphone with short distance mobile system
JP3828873B2 (en) Wireless communication system and wireless communication method thereof
US6631431B1 (en) Semaphore coding method to ensure data integrity in a can microcontroller and a can microcontroller that implements this method
US7161941B1 (en) Wireless packet communications with extended addressing capability
US20040198223A1 (en) Flow control in a bluetooth wireless communication system
CN1538703A (en) Hybrid-type data transmission appartus andmethod for high performance wireless LAN
US7457635B2 (en) Modem sharing device of PDA phone and method thereof
US20030086485A1 (en) Master to multi-slave asynchronous transmit fifo
EP1700501B1 (en) Manifold in a radio base station and method of using such a radio base station
CN214278936U (en) MCBSP and USB conversion control board card
JP2646852B2 (en) Packet handling method
KR20040065324A (en) Method and system of multi- downloading file by using plural handsets
US7266134B2 (en) Transmission circuit for a digital communication system
WO2009083027A1 (en) Method and system for managing data in a memory
EP0905949A1 (en) Priority-scheduled parallel message delivery method and apparatus
Kirkeby Mono Audio Link Using Frequency Hopping
JPH04227353A (en) Communication system and communication equipment

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A2

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BY BZ CA CH CN CR CU CZ DE DK DM DZ EE ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NO NZ PL PT RO RU SD SE SG SI SK SL TJ TM TR TT TZ UA UG US UZ VN YU ZA ZW

AL Designated countries for regional patents

Kind code of ref document: A2

Designated state(s): GH GM KE LS MW MZ SD SL SZ TZ UG ZW AM AZ BY KG KZ MD RU TJ TM AT BE CH CY DE DK ES FI FR GB GR IE IT LU MC NL PT SE TR BF BJ CF CG CI CM GA GN GW ML MR NE SN TD TG

121 Ep: the epo has been informed by wipo that ep was designated in this application
DFPE Request for preliminary examination filed prior to expiration of 19th month from priority date (pct application filed before 20040101)
AK Designated states

Kind code of ref document: A3

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BY BZ CA CH CN CR CU CZ DE DK DM DZ EE ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NO NZ PL PT RO RU SD SE SG SI SK SL TJ TM TR TT TZ UA UG US UZ VN YU ZA ZW

AL Designated countries for regional patents

Kind code of ref document: A3

Designated state(s): GH GM KE LS MW MZ SD SL SZ TZ UG ZW AM AZ BY KG KZ MD RU TJ TM AT BE CH CY DE DK ES FI FR GB GR IE IT LU MC NL PT SE TR BF BJ CF CG CI CM GA GN GW ML MR NE SN TD TG

WWE Wipo information: entry into national phase

Ref document number: 2001910848

Country of ref document: EP

WWP Wipo information: published in national office

Ref document number: 2001910848

Country of ref document: EP

REG Reference to national code

Ref country code: DE

Ref legal event code: 8642

Ref country code: DE

Ref legal event code: 8642

COP Corrected version of pamphlet

Free format text: PAGES 1/29-29/29, DRAWINGS, REPLACED BY NEW PAGES 1/24-24/24; DUE TO LATE TRANSMITTAL BY THE RECEIVING OFFICE

NENP Non-entry into the national phase

Ref country code: JP