function packet = helperBLEPrependAccessAddress(pdu, accessAddress)
%helperBLEPrependAccessAddress prepends the PDU with the ACCESSADDRESS
%   PACKET = helperBLEPrependAccessAddress(PDU, ACCESSADDRESS) prepends the
%   PDU with the ACCESSADDRESS and outputs the resulting packet into PACKET.
%
%   PACKET is the generated PDU prepended with ACCESSADDRESS, returned as a
%   binary column vector.
%
%   PDU is Link Layer PDU, specified as a binary column vector.
%
%   ACCESSADDRESS specified as 4-octet hexadecimal value.

%   Copyright 2018 The MathWorks, Inc.

accessAddr = de2bi(hex2dec(accessAddress), 32)';
packet = [accessAddr; pdu];
end