顯示具有 multicast 標籤的文章。 顯示所有文章
顯示具有 multicast 標籤的文章。 顯示所有文章

2013年10月16日 星期三

如何由收到的封包得知是 unicast 或是 multicast ?

ONVIF 使用 WS-Discovery 作為其尋找設備的規範,並且對Discovery作了點小修改。
其中主要的差異便是針對 unicast/multicast probe,其錯誤處理不同。 

  • 當收到 multicast probe時,若發現此封包有任何錯誤時,都不回錯誤。 
  • 當收到 unicast probe時,若發現此封包的 MatchBy 有錯誤時,需回錯誤。 

2013年5月28日 星期二

ONVIF -- Multicast 問題分析經驗談

在進行 ONVIF Device Test Tool v12.12 的測試過程中,當測試 ONVIF 的 startMulticast 命令時,送出 Audio 時總是無法通過測試工具的檢驗,後來釐清是因為 profile s中規定 audio需要設定為 PCM-ulaw 的關係,但因此也學習了許多與 multicast 有關的知識。

以下將以 startMulticast 為例,整理幾個分析 multicast 的小技巧。

預備知識

StartMulticast 命令所做的事情,就是根據某個已經設定好的 profile,啟動 multicast streaming,可能同時包含 video 與 audio。原文摘錄如下:
This command starts multicast streaming using a specified media profile of an NVT. Streaming continues until StopMulticastStreaming is called for the same Profile. The streaming shall continue after a reboot of the NVT until a StopMulticastStreaming request is received. The multicast address, port and TTL are configured in the VideoEncoderConfiguration, AudioEncoderConfiguration and MetadataConfiguration respectively. An NVT that supports video, audio or metadata multicast streaming shall support the starting of a multicast stream through the StartMulticastStreaming command.