03.01.2013 Views

Chapter 1

Chapter 1

Chapter 1

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

As with GDP-SMS, the SendL() function is called when the client code calls the<br />

corresponding function in CGdpBTComms.<br />

void CGdpBTSender::SendL(const TDesC8& aAddress, const TDesC8&<br />

aData)<br />

{<br />

TLex8 lex(aAddress);<br />

lex.Mark();<br />

if (!(lex.Get() == "0" && lex.Get() == "x"))<br />

lex.UnGetToMark();<br />

TInt64 addr;<br />

User::LeaveIfError(lex.Val(addr, EHex));<br />

iAddr.SetBTAddr(TBTDevAddr(addr));<br />

// Check the size of the data we're trying to send:<br />

// - if it's bigger than the maximum we can store in our<br />

member<br />

// variable then call GdpUtil::Fault()<br />

__ASSERT_ALWAYS(aData.Size()

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!