BROADCAST TIMING, GENLOCK AND TIME CODE IN THE MULTI FORMAT NETWORK AGE
NEVION May 19 2015
6/2/2015 2IBC 2014
Generic Media Setup
Ing
est
Se
rvers
Pla
yo
ut
Serv
e rs
Central Server
Archive Server
Studio 1
Studio n
Terrestrial
Satellite
Transmission 1
Transmission n
Satellite
IPTV
Terrestrial
Mobile
www
EmissionTransmission /
distributionPost
ProductionProduction / Acquisition
SDI ROUTER
WAN
Contribution Distribution
Terrestrial
Satellite
WAN
Content Provider / Broadcaster / Network
SONET / Dark Fiber / IPSONET / Dark Fiber / IP
Archive & Storage
6/2/2015 3IBC 2014
Real Time Area
Ing
est
Se
rvers
Pla
yo
ut
Serv
e rs
Central Server
Archive Server
Studio 1
Studio n
Terrestrial
Satellite
Transmission 1
Transmission n
Satellite
IPTV
Terrestrial
Mobile
www
EmissionTransmission /
distributionPost
ProductionProduction / Acquisition
SDI ROUTER
WAN
Contribution Distribution
Terrestrial
Satellite
WANSONET / Dark Fiber / IP
SONET / Dark Fiber / IP
Archive & Storage
Genlock Timing from Black & Burst
6/2/2015 4IBC 2014
Non Real-Time Area
Ing
est
Se
rvers
Pla
yo
ut
Serv
e rs
Central Server
Archive Server
Studio 1
Studio n
Terrestrial
Satellite
Transmission 1
Transmission n
Satellite
IPTV
Terrestrial
Mobile
www
EmissionTransmission /
distributionPost
ProductionProduction / Acquisition
SDI ROUTER
WAN
Contribution Distribution
Terrestrial
Satellite
WANSONET / Dark Fiber / IP
SONET / Dark Fiber / IP
Archive & Storage
No precise timing for file transfers
Time labeling (Time Code) is king
6/2/2015 5IBC 2014
Synchronisation and Time Code
Synchronisation is referenced to Black & Burst Black & Burst is a standard definition analog video signal running over analog infrastructure
Time Code is referenced to a Linear Time Code signal LTC is a low speed digital signal running over analog audio infrastructure
These are the only remaining analog signals in many facilities
6/2/2015 6IBC 2014
The Move to Networks
All equipment has a network interface for control and monitoring
Growing use of high speed network interfaces for transport of
essence
Ethernet networks are great at absorbing existing infrastructures –
as long as they can satisfy the specific requirements
Data rate, reliability, consistency, timing accuracy, QoS
Why require separate infrastructures just for synchronisation and
Time Code?
IEEE-1588 – Precision Time Protocol or PTP – is a network based
protocol designed to deliver accurate time and frequency
There is potential for the current system to be replaced – and improved
6/2/2015 7IBC 2014
PTP in Broadcasting
PTP has the range and precision to cover all media requirements
Does it have the accuracy? Let’s say we need 1 μs
6/2/2015 8IBC 2014
How PTP Works
PTP sends time over a network from a Master clock to Slave clocks
The object is to make the Slaves’ time the same as the Master’s
Network delays are large and variable
Packet Delay in a 20% Loaded Network of 10 x 1GbE Switches
Absolute minimum is 30us and even at 20% loading many packets exceed this
30 us
40 us
50 us
60 us
70 us
80 us
6/2/2015 9IBC 2014
How PTP Works
Red spots indicate downstream packet delays
Blue spots indicate upstream packet delays
Packet Delay in a 50% Loaded Network of 10 x 1GbE Switches
Very few minimum delay packets
30 us
40 us
50 us
60 us
70 us
80 us
6/2/2015 10IBC 2014
How PTP Works
Packet Delay in an 80% Loaded Network of 10 x 1GbE Switches
No minimum delay packets
Median delay near to 40 us
30 us
40 us
50 us
60 us
70 us
80 us
6/2/2015 11IBC 2014
How PTP Works
Packet delays vary
greatly with network
loading
Large numbers of
minimum delay packets
at 20% loading
No minimum delay
packets at 80% loading
Delays are large and
dynamic
Target accuracy is < 1us
30 us 40 us 50 us 60 us 70 us 80 us 90 us
80% Loading
50% Loading
20% Loading
6/2/2015 12IBC 2014
How PTP Works – delay compensation
Sync messages send the
Master’s time to the Slave (t1)
The Slave time stamps the
receipt of the Sync message
(t2)
Delay Request messages send
the Slave’s time to the Master
(t3)
Delay Response message tells
the Slave when its Delay
Request message was
received by the Master (t4)
The Slave maintains a running
estimate of (t2-t1) and (t4-t3) and
works to equalise them
This keeps Slave time the
same as Master time
Master
Time
Slave
Time
t1
t2
t3
t4
Sync message
Delay request
message
Delay response message
containing value of t4
Follow up message
containing value of t1
Data at
Slave Clock
(t1), t2
t1, t2
t1, t2, t3
t1, t2, t3 ,t4
6/2/2015 13IBC 2014
System Errors
Timing algorithm assumes
symmetric delays in network
A network with 20% loading in one
direction and 80% loading in the
other direction will suffer timing
asymmetry of several
microseconds
30 us 40 us 50 us 60 us 70 us 80 us 90 us
80% Loading
50% Loading
20% Loading
6/2/2015 14IBC 2014
Error Management Techniques
Network Delay Compensation using Transparent Clocks Built into switches
Measure delay through switch and “inform” PTP packets
Correction Field added by first TC and updated by subsequent ones
Uncorrected delay remaining is cable delay only
Only works if all switches have transparent clocks
PreambleNetwork
Protocol
PTP Message
Correction Field
+
− +
Residence Time
Ingress Egress
EgressIngress
Port n Port n+1
Ingress Timestamp Egress Timestamp
PreambleNetwork
Protocol
PTP Message
Correction Field
6/2/2015 15IBC 2014
Error Management Techniques
Network Delay Segmentation by Boundary Clocks Built into switches
Switch has PTP Slave on Input and PTP Master on Outputs
Remaining delay is cable only
Accuracy dependent on all boundary clocks
6/2/2015 16IBC 2014
Error Management Techniques
Intelligent Algorithms Sophisticated Analysis of the PTP packets
Long Term Linear and Non-linear filtering
Simple ERROR = ((t2-t1)-(t4-t3))/2
is replaced with intelligent algorithm
No special switches required
Longer calculation time needed
Not compatible with short lock time
Only feasible approach for undisciplined networks
Master
Time
Slave
Time
t1
t2
t3
t4
Sync message
Delay request
message
Delay response message
containing value of t4
Follow up message
containing value of t1
Data at
Slave Clock
(t1), t2
t1, t2
t1, t2, t3
t1, t2, t3 ,t4
t1, t1, t1, t1…….
t2, t2, t2, t2……
t3, t3, t3, t3………
t4, t4, t4, t4…..
DOWN A BIT
UP A BIT
OK HOLD
IT THERE
Semtech – Copyright 2014
GETTING FROM PTP TIME TO VIDEO, AUDIO AND TIME CODE
17
6/2/2015 18IBC 2014
Typical PTP Slave Output
1 Pulse per Second (1PPS)
Frequency accurate clock 5 MHz, 10 MHz, 125 MHz
Time of Day Calculated based on number of seconds from a defined Epoch
6/2/2015 19IBC 2014
From Time to Media Timing
Media timing is periodic
So if you know the media timing at any one point in time, you know it
for all time
For example if you know that you are at the top of a frame at time E,
you know you are at the top-of-frame at every 1/25 of a second after
E, for PAL based systems
By defining an Epoch, and having a standard which says that all
media are at top-of-frame at that time, all media timing can be
derived based on time from the Epoch.
Fr 2Fr 1 Fr 4Fr 3 Fr I+1Fr I
Fr 2Fr 1 Fr 4Fr 3 Fr K+1Fr K
Fr 2Fr 1 Fr 4Fr 3 Fr J+1Fr J
E
25 fps
30/1.001
fps
24 fps
NOW
Fr 5
TIME SINCE EPOCH (CAN BE SECONDS OR YEARS)
6/2/2015 20IBC 2014
And Not Forgetting Audio
Audio 48 kHz Sample Clock is also timed from Epoch
The 192 sample audio block (Z-bit) is also timed from
Epoch
S2S1 S4S3 S I+1S I
Block 1
E
48 kHz
Audio
Block
NOWTIME SINCE EPOCH (CAN BE SECONDS OR YEARS)
Block J
6/2/2015 21IBC 2014
Media Time Labelling – Time Code
Time code is a time label attached to each video frame
It currently counts hh:mm:ss:ff
Frame count goes up to 39
• Capability needed for higher frame rates
Time goes up to 24 hours
• Capability needed for date as well a time
• 1/1.001 formats use drop frame to consolidate media time with clock time– At least some of them do – some turn a blind eye to real clock time
PTP can be used to emulate all aspects of current time code, and
can also improve on it with more sophisticated labelling
Far better resolution, for higher and even variable frame rates
Coding of Date as well as Time
6/2/2015 22IBC 2014
SMPTE Standardisation
SMPTE (Society of Motion Picture and Television Engineers) is
standardising a PTP profile to replace analog based genlock
SMPTE ST 2059-1 is the timing standard including calculation methods
It defines the Epoch
It defines the phase of all media signals relative to the epoch
It also includes example equations to work out the signal phase at any time
SMPTE ST 2059-2 is the PTP profile Details to follow
These standards are now well on the route to publication Agonisingly close
SMPTE Engineering Guidelines – in process
Introduction to PTP
Time discontinuities
Migration guide
Best practice for large networks
6/2/2015 23IBC 2014
SMPTE PTP Profile Details
Timing accuracy 1μs
Lock time 5s
Slaves cannot be Masters – so initial negotiation is accelerated
Mix of multicast and unicast packet types
Required message transport modes for Announce, Sync and Follow_Up
messages: multicast
Permitted message transport modes for Announce, Sync and Follow_Up
messages: unicast
Delay_Req messages may be multicast or unicast.
Pdelay_Req messages may be multicast or unicast.
Pdelay_Resp and Pdelay_Resp_Follow_Up messages shall be unicast.
Management messages may be multicast or unicast. Replies to management
messages shall be unicast.
TimeSource can be locked, unlocked or “once locked”
Locked is traceable to a reference such as GPS
Unlocked and once locked are where the master’s frequency is referenced to
incoming media
6/2/2015 24IBC 2014
SMPTE PTP Profile – Special Features
SMPTE TLV packets
Metadata for Local Time calculation• Leap seconds
• Daylight Savings
• Time Zone
Metadata for Time Code generation• Local time vs PTP time
• Drop Frame or not
• Time of day to jam Time Code to Local Time
6/2/2015 25IBC 2014
SMPTE Timing Standard
Epoch is 1970-01-01T00:00:00TAI
All signals aligned at the epoch Audio clocks at 32 kHz, 44.1 kHz, 48 kHz, 96 kHz, 192 kHz....
• Blocks of 192 audio samples
Video frames at all frame rates
• Blocks of 2 or 4 video frames arising from the relationship with the colour subcarrier in
analog colour systems (NTSC and PAL)
• Blocks of 5 frames arising from the relationship between audio samples and some video
frames
For each video frame type there is a defined alignment
point, based on the start of the vertical flyback time for
an analog transport of the video signal
6/2/2015 26IBC 2014
The Video Alignment Point
Each frame type has an alignment point – X
• Which aligns with the epoch
• Based on analog V sync
V Blanking – VANC space
Active Video
V Blanking – VANC space
Active Video
Fie
ld 1
(F =
0) O
dd
Fie
ld 2
(F =
1) E
ve
n
FV
H
Line 1
Line 4
Line 20
Line 264
Line 266
Line 283
Line 525
Example of 525-line
interlaced
Formats that were never
analog have an
equivalent point created
Semtech – Copyright 2014
A PTP GENLOCK
27
6/2/2015 28IBC 2014
A PTP Genlock
A PTP slave part – deriving time
SMPTE profile support
SMPTE TLV extraction
Holdover to accommodate long periods without reliable timing reference data
A Genlock part – converting time to media timing
Low Jitter Video Clock Generation
• Absolute frequency accuracy required
• Not necessarily a multiple of 1Hz
– 1/1.001 frequencies are a multiple of 1/91 Hz
Programmable Video Format Timing Pulse Generation
Low Jitter Audio Clock and Block Generation
Epoch Alignment
• With programmable offset for cable length compensation
Possibly a Time Code part – converting time to time labels
Translation of time, TLV and Video frame information into Time Code
• Including drop frame where necessary
Semtech – Copyright 2014
PTP FOR NETWORK STREAMED VIDEO
29
6/2/2015 30IBC 2014
PTP for Network Streamed Video
Packetised and streamed video needs buffering to eliminate network timing jitter
It is necessary to place a maximum on the permissible latency in a streamed video
application
It may be critical that overall latency is fixed
A PTP signal accompanying the streamed video can be used to transport the input timing to
the output
The Epoch is defined locally – maybe just the nearest top of frame after the equipment started up
SDIPacket
Encoder
Packet
DecoderSDI
PTP master
with SDI
reference
PTP slave
with N frame
offset
Buffer to pad
latency to N
frames
Variable delay with maximum of N frames
Fixed delay of exactly N frames
Semtech – Copyright 2014
CONCLUSIONS
31
6/2/2015 32IBC 2014
Conclusions
PTP can be used to replace black & burst for synchronisation
As long as a standardised Epoch is in use
And genlocks have a very much improved holdover performance
PTP can be used to enhance Time Code for time labelling
It can operate over control and monitoring networks or media essence networks
It may need special switches with PTP capability
Transparent clocks or Boundary clocks
Intelligent algorithms can be used instead
But fast lock time will be difficult to achieve
PTP can also bring precision and consistency to the latency of streamed network media links
It spans the network link and carries the “real-time” timing from the input to the output, using an arbitrary epoch
Thank You