BlueToe
an alternative GATT/BLE implementation
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
bluetoe::link_layer::address Class Reference

a 48-bit universal LAN MAC address More...

#include <bluetoe/utility/include/bluetoe/address.hpp>

Inheritance diagram for bluetoe::link_layer::address:
bluetoe::link_layer::device_address bluetoe::link_layer::public_device_address bluetoe::link_layer::random_device_address

Public Types

typedef std::uint8_t const * const_iterator
 random access iterator
 

Public Member Functions

 address ()
 creates the address with all octes beeing zero (00:00:00:00:00:00)
 
 address (const std::initializer_list< std::uint8_t > &initial_values)
 initialize an address by a initializer list with exactly 6 elements
 
 address (const std::uint8_t *initial_values)
 initializing an address by taking 6 bytes from the given start of an array
 
std::ostream & print (std::ostream &) const
 prints this in a human readable manner
 
std::uint8_t msb () const
 returns the most significant byte of the address
 
bool operator== (const address &rhs) const
 returns true, if this address is the same as the rhs address
 
bool operator!= (const address &rhs) const
 returns false, if this address is the same as the rhs address
 
const_iterator begin () const
 returns an iterator to the first byte (LSB) of the address
 
const_iterator end () const
 returns an iterator one behind the last byte of the address
 

Static Public Member Functions

static random_device_address generate_static_random_address (std::uint32_t seed)
 generates a valid static random address out of a given seed value
 
template<typename HashFunc >
static random_device_address generate_resolvable_private_address (const std::uint8_t *irk, std::uint32_t random, HashFunc hash_func)
 generates a resolvable private address
 

Detailed Description

a 48-bit universal LAN MAC address

Member Function Documentation

◆ generate_static_random_address()

static random_device_address bluetoe::link_layer::address::generate_static_random_address ( std::uint32_t  seed)
static

generates a valid static random address out of a given seed value

The function generates a random device address that is valid and that has always the same value for the same seed.


The documentation for this class was generated from the following file: