<s>
In	O
mobile-telephone	O
technology	O
,	O
the	O
UniPro	B-Protocol
protocol	I-Protocol
stack	I-Protocol
follows	O
the	O
architecture	O
of	O
the	O
classical	O
OSI	O
Reference	O
Model	O
.	O
</s>
<s>
In	O
UniPro	B-Application
,	O
the	O
OSI	O
Physical	O
Layer	O
is	O
split	O
into	O
two	O
sublayers	O
:	O
Layer	O
1	O
(	O
the	O
actual	O
physical	O
layer	O
)	O
and	O
Layer	O
1.5	O
(	O
the	O
PHY	O
Adapter	O
layer	O
)	O
which	O
abstracts	O
from	O
differences	O
between	O
alternative	O
Layer	O
1	O
technologies	O
.	O
</s>
<s>
The	O
UniPro	B-Application
specification	O
itself	O
covers	O
Layers	O
1.5	O
,	O
2	O
,	O
3	O
,	O
4	O
and	O
the	O
DME	O
(	O
Device	O
Management	O
Entity	O
)	O
.	O
</s>
<s>
The	O
Application	O
Layer	O
(	O
LA	O
)	O
is	O
out	O
of	O
scope	O
because	O
different	O
uses	O
of	O
UniPro	B-Application
will	O
require	O
different	O
LA	O
protocols	O
.	O
</s>
<s>
Versions	O
1.0	O
and	O
1.1	O
of	O
UniPro	B-Application
use	O
MIPI	O
's	O
D-PHY	O
technology	O
for	O
the	O
off-chip	O
Physical	O
Layer	O
.	O
</s>
<s>
In	O
UniPro	B-Application
,	O
the	O
D-PHY	O
is	O
used	O
in	O
a	O
mode	O
(	O
called	O
"	O
8b9b	O
"	O
encoding	O
)	O
which	O
conveys	O
8-bit	O
bytes	O
as	O
9-bit	O
symbols	O
.	O
</s>
<s>
The	O
UniPro	B-Application
protocol	O
uses	O
this	O
to	O
represent	O
special	O
control	O
symbols	O
(	O
outside	O
the	O
usual	O
0	O
to	O
255	O
values	O
)	O
.	O
</s>
<s>
Note	O
that	O
the	O
ratio	O
8:9	O
can	O
cause	O
some	O
confusion	O
when	O
specifying	O
the	O
data	O
rate	O
of	O
the	O
D-PHY	O
:	O
a	O
PHY	O
implementation	O
running	O
with	O
a	O
450MHz	O
clock	O
frequency	O
is	O
often	O
rated	O
as	O
a	O
900	O
Mbit/s	O
PHY	O
,	O
while	O
only	O
800	O
Mbit/s	O
is	O
then	O
available	O
for	O
the	O
UniPro	B-Application
stack	O
.	O
</s>
<s>
Versions	O
1.4	O
and	O
beyond	O
of	O
UniPro	B-Application
support	O
both	O
the	O
D-PHY	O
as	O
well	O
as	O
M-PHY	B-Protocol
technology	O
.	O
</s>
<s>
The	O
M-PHY	B-Protocol
technology	O
is	O
still	O
in	O
draft	O
status	O
,	O
but	O
supports	O
high-speed	O
data	O
rates	O
starting	O
at	O
about	O
1000	O
Mbit/s	O
(	O
the	O
M-PHY	B-Protocol
was	O
named	O
after	O
the	O
Roman	O
number	O
for	O
1000	O
)	O
.	O
</s>
<s>
In	O
addition	O
to	O
higher	O
speeds	O
,	O
the	O
M-PHY	B-Protocol
will	O
use	O
fewer	O
signal	O
wires	O
because	O
the	O
clock	O
signal	O
is	O
embedded	O
with	O
the	O
data	O
through	O
the	O
use	O
of	O
industry-standard	O
8b10b	B-Protocol
encoding	I-Protocol
.	O
</s>
<s>
Again	O
,	O
a	O
PHY	O
capable	O
of	O
transmitting	O
user	O
data	O
at	O
1000	O
Mbit/s	O
is	O
typically	O
specified	O
as	O
being	O
in	O
1250	O
Mbit/s	O
mode	O
due	O
to	O
the	O
8b10b	B-Protocol
encoding	I-Protocol
.	O
</s>
<s>
+	O
Physical	O
layer	O
technologies	O
supported	O
by	O
UniPro	B-Application
PHY	O
technology	O
Version	O
/	O
Released	O
Symbol	O
encoding	O
Gbit/s	O
(	O
payload	O
)	O
lanes	O
Supported	O
in	O
D-PHY	O
1.2/September	O
2014	O
8b/9b	O
4.5	O
Gbit/s/lane	O
4	O
lane	O
port	B-Protocol
M-PHY	B-Protocol
3.1/June	O
2014	O
8b/10b	B-Protocol
11.6	O
Gbit/s/lane	O
4+1	O
lane	O
port	B-Protocol
C-PHY	O
1.00.00	O
/	O
October	O
2014	O
?	O
</s>
<s>
The	O
D	O
-	O
and	O
M-PHY	B-Protocol
are	O
expected	O
to	O
co-exist	O
for	O
several	O
years	O
.	O
</s>
<s>
D-PHY	O
is	O
a	O
less	O
complex	O
technology	O
,	O
M-PHY	B-Protocol
provides	O
higher	O
bandwidths	O
with	O
fewer	O
signal	O
wires	O
,	O
and	O
C-PHY	O
provides	O
low-power	O
.	O
</s>
<s>
It	O
is	O
worth	O
noting	O
that	O
UniPro	B-Application
supports	O
the	O
power	O
efficient	O
low	O
speed	O
communication	O
modes	O
provided	O
by	O
both	O
the	O
D-PHY	O
(	O
10	O
Mbit/s	O
)	O
and	O
M-PHY	B-Protocol
(	O
3	O
Mbit/sec	O
up	O
to	O
500	O
Mbit/s	O
)	O
.	O
</s>
<s>
Architecturally	O
,	O
the	O
PHY	O
Adapter	O
layer	O
serves	O
to	O
hide	O
the	O
differences	O
between	O
the	O
different	O
PHY	O
options	O
(	O
D	O
-	O
and	O
M-PHY	B-Protocol
)	O
.	O
</s>
<s>
The	O
main	O
feature	O
that	O
L1.5	O
offers	O
users	O
is	O
to	O
allow	O
the	O
bandwidth	O
of	O
a	O
UniPro	B-Application
link	O
to	O
be	O
increased	O
by	O
using	O
2	O
,	O
3	O
or	O
4	O
lanes	O
when	O
a	O
single	O
lane	O
does	O
not	O
provide	O
enough	O
bandwidth	O
.	O
</s>
<s>
Starting	O
in	O
UniPro	B-Application
v1.4	O
,	O
L1.5	O
automatically	O
discovers	O
the	O
number	O
of	O
usable	O
M-PHY	B-Protocol
lanes	O
for	O
each	O
direction	O
of	O
the	O
link	O
.	O
</s>
<s>
Starting	O
in	O
UniPro	B-Application
v1.4	O
,	O
L1.5	O
has	O
a	O
built	O
in	O
protocol	O
called	O
PACP	O
(	O
PA	O
Control	O
Protocol	O
)	O
that	O
allows	O
L1.5	O
to	O
communicate	O
with	O
its	O
peer	O
L1.5	O
entity	O
at	O
the	O
other	O
end	O
of	O
an	O
M-PHY-based	O
link	O
.	O
</s>
<s>
In	O
addition	O
to	O
the	O
L1.5	O
link	O
power	O
management	O
the	O
PACP	O
is	O
also	O
used	O
to	O
access	O
control	O
and	O
status	O
parameters	O
of	O
the	O
peer	O
UniPro	B-Application
device	O
.	O
</s>
<s>
The	O
main	O
task	O
of	O
UniPro	B-Application
's	O
Data	O
Link	O
layer	O
(	O
L2	O
)	O
is	O
to	O
allow	O
reliable	O
communication	O
between	O
two	O
adjacent	O
nodes	O
in	O
the	O
network	O
-	O
despite	O
occasional	O
bit	O
errors	O
at	O
the	O
Physical	O
layer	O
or	O
potential	O
link	O
congestion	O
if	O
the	O
receiver	O
cannot	O
absorb	O
the	O
data	O
fast	O
enough	O
.	O
</s>
<s>
L2	O
clusters	O
17-bit	O
UniPro	B-Application
L1.5	O
symbols	O
into	O
packet-like	O
data	O
frames	O
(	O
the	O
term	O
packet	O
is	O
reserved	O
for	O
L3	O
)	O
.	O
</s>
<s>
Note	O
that	O
two	O
or	O
more	O
of	O
the	O
288	O
bytes	O
are	O
used	O
by	O
higher	O
layers	O
of	O
the	O
UniPro	B-Application
protocol	O
.	O
</s>
<s>
UniPro	B-Application
currently	O
supports	O
two	O
priority	O
levels	O
for	O
data	O
frames	O
called	O
Traffic	O
Class	O
0	O
(	O
TC0	O
)	O
and	O
Traffic	O
Class	O
1	O
(	O
TC1	O
)	O
.	O
</s>
<s>
In	O
UniPro	B-Application
version	O
1.1	O
,	O
an	O
option	O
was	O
introduced	O
to	O
allow	O
simple	O
endpoint	O
devices	O
to	O
implement	O
only	O
one	O
of	O
the	O
two	O
Traffic	O
Classes	O
if	O
they	O
choose	O
to	O
.	O
</s>
<s>
This	O
is	O
different	O
from	O
,	O
for	O
example	O
,	O
the	O
widely	O
used	O
TCP	B-Protocol
protocol	I-Protocol
that	O
detects	O
errors	O
at	O
the	O
endpoints	O
and	O
relies	O
on	O
end-to-end	O
retransmission	O
in	O
case	O
of	O
corrupted	O
or	O
missing	O
data	O
.	O
</s>
<s>
Version	O
1.4	O
of	O
the	O
UniPro	B-Application
spec	O
does	O
not	O
specify	O
the	O
details	O
of	O
a	O
switch	O
,	O
but	O
does	O
specify	O
enough	O
to	O
allow	O
a	O
device	O
to	O
work	O
in	O
a	O
future	O
networked	O
environment	O
.	O
</s>
<s>
Although	O
the	O
role	O
of	O
the	O
L3	O
address	O
is	O
the	O
same	O
as	O
the	O
IP	O
address	O
in	O
packets	O
on	O
the	O
Internet	O
,	O
a	O
UniPro	B-Application
DeviceID	O
address	O
is	O
only	O
7	O
bits	O
long	O
.	O
</s>
<s>
A	O
network	O
can	O
thus	O
have	O
up	O
to	O
128	O
different	O
UniPro	B-Application
devices	O
.	O
</s>
<s>
Note	O
that	O
,	O
as	O
far	O
as	O
UniPro	B-Application
is	O
concerned	O
,	O
all	O
UniPro	B-Application
devices	O
are	O
created	O
equal	O
:	O
unlike	O
PCI	O
Express	O
or	O
USB	O
,	O
any	O
device	O
can	O
take	O
the	O
initiative	O
to	O
communicate	O
with	O
any	O
other	O
device	O
.	O
</s>
<s>
This	O
makes	O
UniPro	B-Application
a	O
true	O
network	O
rather	O
than	O
a	O
bus	O
with	O
one	O
master	O
.	O
</s>
<s>
This	O
implies	O
that	O
,	O
in	O
UniPro	B-Application
,	O
the	O
concepts	O
of	O
an	O
L2	O
Frame	O
,	O
an	O
L3	O
Packet	O
and	O
an	O
L4	O
Segment	O
(	O
see	O
below	O
)	O
are	O
so	O
closely	O
aligned	O
that	O
they	O
are	O
almost	O
synonyms	O
.	O
</s>
<s>
UniPro	B-Application
short-header	O
packets	O
use	O
a	O
single	O
header	O
byte	O
for	O
L3	O
information	O
.	O
</s>
<s>
For	O
short-header	O
packets	O
,	O
the	O
L3	O
source	O
address	O
is	O
not	O
included	O
in	O
the	O
header	O
because	O
it	O
is	O
assumed	O
that	O
the	O
two	O
communicating	O
devices	O
have	O
exchanged	O
such	O
information	O
beforehand	O
(	O
connection-oriented	B-Protocol
communication	I-Protocol
)	O
.	O
</s>
<s>
Long-header	O
packets	O
are	O
intended	O
to	O
be	O
introduced	O
in	O
a	O
future	O
version	O
of	O
the	O
UniPro	B-Application
specification	O
,	O
so	O
their	O
format	O
is	O
undefined	O
(	O
except	O
for	O
one	O
bit	O
)	O
in	O
the	O
current	O
UniPro	B-Application
v1.4	O
specification	O
.	O
</s>
<s>
However	O
,	O
UniPro	B-Application
v1.4	O
defines	O
a	O
hook	O
that	O
allows	O
long-header	O
packets	O
to	O
be	O
received	O
or	O
transmitted	O
by	O
a	O
UniPro	B-Application
v1.4	O
conformant-device	O
assuming	O
the	O
latter	O
can	O
be	O
upgraded	O
via	O
software	O
.	O
</s>
<s>
The	O
"	O
long-header	O
trap	O
"	O
mechanism	O
of	O
UniPro	B-Application
v1.4	O
simply	O
passes	O
the	O
payload	O
of	O
a	O
received	O
L2	O
data	O
frame	O
(	O
being	O
the	O
L3	O
packet	O
with	O
its	O
header	O
and	O
payload	O
)	O
to	O
the	O
L3	O
extension	O
(	O
e.g.	O
</s>
<s>
This	O
mechanism	O
aims	O
to	O
allow	O
UniPro	B-Application
v1.4	O
devices	O
to	O
be	O
able	O
to	O
be	O
upgraded	O
in	O
order	O
to	O
support	O
protocols	O
that	O
require	O
the	O
as-yet	O
undefined	O
long-header	O
packets	O
.	O
</s>
<s>
Although	O
details	O
of	O
switches	O
are	O
still	O
out	O
of	O
scope	O
in	O
the	O
UniPro	B-Application
v1.4	O
spec	O
,	O
L3	O
allows	O
UniPro	B-Application
v1.0/v1.1/v1.4	O
devices	O
to	O
serve	O
as	O
endpoints	O
on	O
a	O
network	O
.	O
</s>
<s>
The	O
features	O
of	O
UniPro	B-Application
's	O
Transport	O
layer	O
are	O
not	O
especially	O
complex	O
,	O
because	O
basic	O
communication	O
services	O
have	O
already	O
been	O
taken	O
care	O
of	O
by	O
lower	O
protocol	O
layers	O
.	O
</s>
<s>
TCP	B-Protocol
and	O
UDP	B-Protocol
)	O
but	O
that	O
are	O
less	O
commonly	O
encountered	O
in	O
local	O
busses	O
like	O
PCI	O
Express	O
,	O
USB	O
or	O
on-chip	O
busses	O
.	O
</s>
<s>
UniPro	B-Application
's	O
L4	O
also	O
has	O
special	O
significance	O
because	O
it	O
is	O
the	O
top	O
protocol	O
layer	O
in	O
the	O
UniPro	B-Application
specification	O
.	O
</s>
<s>
Applications	O
are	O
required	O
to	O
use	O
L4	O
's	O
top	O
interface	O
to	O
interact	O
with	O
UniPro	B-Application
and	O
are	O
not	O
expected	O
to	O
bypass	O
L4	O
to	O
directly	O
access	O
lower	O
layers	O
.	O
</s>
<s>
Thus	O
,	O
although	O
the	O
specification	O
contains	O
an	O
annex	O
with	O
a	O
signal-level	O
interface	O
as	O
a	O
non-normative	O
example	O
,	O
a	O
UniPro	B-Application
implementation	O
is	O
not	O
required	O
to	O
have	O
any	O
specific	O
set	O
of	O
hardware	O
signals	O
or	O
software	O
function	O
calls	O
at	O
its	O
topmost	O
interface	O
.	O
</s>
<s>
UniPro	B-Application
's	O
Transport	O
layer	O
can	O
be	O
seen	O
as	O
providing	O
an	O
extra	O
level	O
of	O
addressing	O
within	O
a	O
UniPro	B-Application
device	O
.	O
</s>
<s>
allows	O
a	O
UniPro	B-Application
device	O
to	O
communicate	O
with	O
another	O
UniPro	B-Application
device	O
using	O
multiple	O
logical	O
data	O
streams	O
(	O
example	O
:	O
sending	O
audio	O
and	O
video	O
and	O
control	O
information	O
separately	O
)	O
.	O
</s>
<s>
allows	O
a	O
UniPro	B-Application
device	O
to	O
simultaneously	O
connect	O
to	O
multiple	O
other	O
devices	O
(	O
this	O
requires	O
switches	O
as	O
supported	O
in	O
a	O
future	O
version	O
of	O
UniPro	B-Application
)	O
using	O
multiple	O
logical	O
data	O
streams	O
.	O
</s>
<s>
The	O
main	O
field	O
in	O
the	O
short	O
L4	O
header	O
is	O
a	O
5-bit	O
"	O
CPort	O
"	O
identifier	O
which	O
can	O
be	O
seen	O
as	O
a	O
sub-address	O
within	O
a	O
UniPro	B-Application
device	O
and	O
is	O
somewhat	O
analogous	O
to	O
the	O
port	B-Protocol
numbers	I-Protocol
used	O
in	O
TCP	B-Protocol
or	O
UDP	B-Protocol
.	O
</s>
<s>
Thus	O
every	O
segment	O
(	O
with	O
a	O
short	O
header	O
)	O
is	O
addressed	O
to	O
a	O
specific	O
CPort	O
of	O
specific	O
UniPro	B-Application
device	O
.	O
</s>
<s>
UniPro	B-Application
v1.4	O
does	O
not	O
define	O
the	O
structure	O
of	O
such	O
segment	O
formats	O
(	O
except	O
for	O
this	O
single	O
bit	O
)	O
.	O
</s>
<s>
UniPro	B-Application
calls	O
a	O
pair	O
of	O
CPorts	O
that	O
communicate	O
with	O
each	O
other	O
a	O
Connection	O
(	O
hence	O
the	O
C	O
in	O
CPort	O
)	O
.	O
</s>
<s>
Because	O
UniPro	B-Application
connections	O
are	O
bidirectional	O
,	O
the	O
destination	O
CPort	O
is	O
also	O
configured	O
to	O
allow	O
data	O
to	O
be	O
sent	O
back	O
to	O
the	O
source	O
CPort	O
.	O
</s>
<s>
In	O
UniPro	B-Application
v1.4	O
connection	O
setup	O
is	O
assumed	O
to	O
be	O
relatively	O
static	O
:	O
the	O
parameters	O
of	O
the	O
paired	O
CPorts	O
are	O
configured	O
by	O
setting	O
the	O
corresponding	O
connection	O
Attributes	O
in	O
the	O
local	O
and	O
peer	O
devices	O
using	O
the	O
DME	O
.	O
</s>
<s>
This	O
will	O
be	O
supplemented	O
by	O
a	O
dynamic	O
connection	O
management	O
protocol	O
in	O
a	O
future	O
version	O
of	O
UniPro	B-Application
.	O
</s>
<s>
E2E	O
FC	O
is	O
only	O
possible	O
for	O
connection-oriented	B-Protocol
communication	I-Protocol
,	O
but	O
at	O
present	O
UniPro	B-Application
's	O
L4	O
does	O
not	O
support	O
alternative	O
options	O
.	O
</s>
<s>
UniPro	B-Application
provides	O
"	O
safety	O
net	O
"	O
mechanisms	O
that	O
mandate	O
that	O
a	O
CPort	O
absorbs	O
all	O
data	O
sent	O
to	O
it	O
without	O
stalling	O
.	O
</s>
<s>
UniPro	B-Application
L4	O
allows	O
a	O
connection	O
between	O
a	O
pair	O
of	O
CPorts	O
to	O
convey	O
a	O
stream	O
of	O
so-called	O
messages	O
(	O
each	O
consisting	O
of	O
a	O
series	O
of	O
bytes	O
)	O
rather	O
than	O
a	O
single	O
stream	O
of	O
bytes	O
.	O
</s>
<s>
Message	O
boundaries	O
are	O
triggered	O
by	O
the	O
application-level	O
protocol	O
using	O
UniPro	B-Application
and	O
are	O
signaled	O
via	O
a	O
bit	O
in	O
the	O
segment	O
header	O
.	O
</s>
<s>
UniPro	B-Application
needs	O
to	O
be	O
told	O
by	O
the	O
application	O
where	O
or	O
when	O
to	O
insert	O
message	O
boundaries	O
into	O
the	O
byte	O
stream	O
:	O
the	O
boundaries	O
have	O
no	O
special	O
meaning	O
for	O
UniPro	B-Application
itself	O
and	O
are	O
provided	O
as	O
a	O
service	O
to	O
build	O
higher-layer	O
protocols	O
on	O
top	O
of	O
UniPro	B-Application
.	O
</s>
<s>
UniPro	B-Application
v1.4	O
introduces	O
the	O
notion	O
of	O
message	O
fragment	O
,	O
a	O
fragment	O
being	O
a	O
portion	O
of	O
a	O
message	O
passed	O
between	O
the	O
application	O
and	O
the	O
CPort	O
.	O
</s>
<s>
This	O
option	O
can	O
be	O
useful	O
when	O
specifying	O
Applications	O
on	O
top	O
of	O
UniPro	B-Application
that	O
need	O
to	O
interrupt	O
the	O
Message	O
creation	O
based	O
on	O
information	O
from	O
the	O
UniPro	B-Application
stack	O
,	O
e.g.	O
,	O
incoming	O
Messages	O
,	O
or	O
backpressure	O
.	O
</s>
<s>
The	O
DME	O
(	O
Device	O
Management	O
Entity	O
)	O
controls	O
the	O
layers	O
in	O
the	O
UniPro	B-Application
stack	O
.	O
</s>
<s>
Furthermore	O
,	O
it	O
provides	O
means	O
to	O
control	O
the	O
peer	O
UniPro	B-Application
stack	O
on	O
the	O
Link	O
.	O
</s>
