title: H264 NAL unit header - detect type and bring custom videos in this format
body: <p>On a special interface on my device, I can see the NAL units passing by. Two example files shown below:</p>
  
  <pre><code>P-Frames:
  00 00 00 01 41 FC 0F 90 86 DE F9 E1 4D 37 AE D3 
  24 A9 F2 F7 E8 A0 9A 9E B3 FD FE 3A D2 77 3E 79 
  8C 93 2D 75 61 60 A0 FA BF CB 46 B6 67 A6 C2 81 
  2B 47 A5 A2 71 5D 4F 90 32 14 EE D5 DE 58 3B 6E 
  ...
  
  I-Frames / Key-Frames:
  00 00 00 01 65 B8 20 67 FF FE 1E 8A 00 02 05 BE 
  4D 49 85 EB FC 9E 44 F7 D0 CE A0 77 25 CD 80 D4 
  4A A4 E5 66 EE E7 F9 17 E5 81 DC 94 9C 2B 3C DF 
  DE D2 63 CC 89 98 82 4D AF C6 BF E8 3F 0D 3C BE 
  ...
  </code></pre>
  
  <p>My goal is, to be able to overwrite this data in order to inject / play my own video. So fare so good, seems to work but it doesn't look good yet. While replayed NAL units, which were previously stored from the very same interface look good, an injected video doesn't. I think i did not get the right video format yet.
  I used different tools like ffmpeg to convert videos into a h264 format. But the video still never looks fine. I think the issue is with the key-frames. While I see lots of 00 00 00 01 41 parts in the converted videos, i can't find a 00 00 00 01 65.</p>
  
  <p>What kind of video format is this? And how to convert my own videos into this format? By using ffmpeg or other tools.</p>
  
  <p>Thanks in advance</p>