hal testapp and file open and close, and ES and PES dump. HAL doc position. hal compile

1, st testapp:

hal/3pp/stapi-sdk-7109$ vim README.testapp
Running the ST-SDK testapp on a vip19xx box
==========================================
** Add kreatv-tool-sttestapp to your bootimage configuration
or build the sttestapp bootimage.
** Add kreatv-tool-sttestapp to your build configuration file
** Build your rootdisk/bootdisk and place it in $NFS (location of your choice)
** Edit your $NFS/etc/inittab, make sure start_platform and start_halserver
are disabled. (not needed if you build the sttestapp bootimage)
** Running the testapp
Boot the box, telnet into it (or use the serial console) and do:
/ # start_sttestapp.sh

 List available commands:

ST710X > HELP


to play a MPEG1/2 video elementary_stream (for H264, use decoder 1 instead)

ST710X > VID_INJSTART 0 "susie.m1v"

ST710X > VID_ENABLE 0


to play a MPEG1/2 audio  elementary_stream  (for H264, use decoder 1 instead)

ST710X >  AUD_INJSTART 0 "2097_audio.es"

ST710X >AUD_ENABLE 0


 

start_sttestapp.sh

 

 

skill_hero.es:

start play audio es file:

#AUD_INJSTART 0 "skill_hero.es" 0  A_HEAAC 44100  A_ES 

unmute device 0:

#AUD_ENABLE 0

 

stop play device 0;

#AUD_INJSTOP 0

 

 

skill_hero.pes

start play audio pes file:

#AUD_INJSTART 0 "skill_hero.pes" 0  A_HEAAC 44100  A_PES 

unmute device 0:

#AUD_ENABLE 0

 

stop play device 0;

#AUD_INJSTOP 0

 

 

 

 

 

skill_hero_adts.es:

AUD_INJSTART 0 "skill_hero_adts.es" 0  A_HEAAC 44100  A_ES

skill_hero_adts.es

 

 

 

skill_hero.pes

start play audio pes file:

#AUD_INJSTART 0 "skill_hero.pes" 0  A_HEAAC 44100  A_PES 

unmute device 0:

#AUD_ENABLE 0

 

stop play device 0;

#AUD_INJSTOP 0

 

 

 

 

it is also possible to play a transport stream from nfs disc:

 

The following will give help list for 68

ST7105 > PLAY_START 0 "kms2171_kms2111_toy1.ts" 68  P_MAIN

--> Invalid Pid Type ,should be 

[P_MP1V,P_MP2V,P_MP4V,P_H264,P_MPEG4P2,P_VC1,P_MP1A,P_MP1A_AUX,P_MP1A_AD,

P_MP2A,P_MP2A_AUX,P_MP2A_AD,P_MP4A,P_MP4A_AUX,P_AC3,P_AC3_AUX,P_AC3_AD,

P_AAC,P_AAC_AUX,P_HEAAC,P_HEAAC_AUX,P_HEAAC_AD,P_WMA,P_WMA_AUX,

P_DDPLUS,P_DDPLUS_AUX,P_DDPLUS_AD,P_DTS,P_DTS_AUX,P_DTS_AD,P_LPCM,

P_LPCM_AUX,P_DDPULSE,P_DDPULSE_AUX,P_DDPULSE_AD,P_DRA,P_DRA_AUX,P_DRA_AD,

P_AUD_ID,P_TTXT,P_SUBT,P_PCR,P_PID,P_AVS,P_MMV,P_MMA,P_END]

 

 

play xxx.tx video.

ST710X > PLAY_START 0 "kms2171_kms2111_toy1.ts" P_MP2V +68 

 

in the above case the video is MPEG2 and the video PID is 666. It will play

to the end. If unsure about the syntax of the PID-type, replace P_MP2V

with an arbitrary junk string. The test app will then list the available types.

 

to stop playback:

 

ST710X > PLAY_STOP

 

 

 

 

 


2, file open and close    

definde file pointer:

FILE * faudiop = NULL;

 

open file:

if (faudiop == NULL) {

if((faudiop=fopen("/2097_audio.es","a+"))==NULL)

{

 Debug->Error("%s:%d:%s, open file error   leosu  \n",__FILE__, __LINE__,__FUNCTION__ );

}

}

 

write file:

   if (faudiop != NULL) {

  size_t writesize = fwrite (HalBuffer + BufferOffset + 14 + adtsHeadLength , 1 , frameSize , faudiop );

if(14 + adtsHeadLength+frameSize !=- writesize)

{

 Debug->Error("%s:%d:%s, write wrong count    leosu  \n",__FILE__, __LINE__,__FUNCTION__ );  

}

}

 

 

close files:

  if (faudiop != NULL) {

  fclose(faudiop);

  }

 

3, PES dump.

dump audio for mp4 file:

extension/streamer/payload-sink-elements/TAudioPayloadSinkElement.cpp

 

 

 

4, HAL doc position:

audio related:

hal/3pp/stapi-sdk-7109/st40/vip19x3/ST7105/stapisdk/apilib/src/staudlx/docs/common$

hal/3pp/stapi-sdk-7109/st40/vip19x3/ST7105/stapisdk/apilib/src/staudlx$

hal/3pp/stapi-sdk-7109/st40/vip19x3/ST7105/stapisdk/apilib/src/stvid$

 

5,  hal compile

5.1 edit soruce file:

leosu@leosu:/mnt/sda3/dev_iptv/DEV_youtube_4_4/hal/3pp/stapi-sdk-7109/st40/vip19x3/ST7105/stapisdk/apilib/src/staudlx/src/parser$ vim es_aac_parser.c

ST_ErrorCode_t ES_AAC_Parser_Init(ComParserInit_t *Init_p, ParserHandle_t *const handle )

{  printk("ES_AAC_Parser_Init \n");

 

5.2 touch for compile

leosu@leosu:/mnt/sda3/dev_iptv/DEV_youtube_4_4/hal/3pp/stapi-sdk-7109/st40/vip19x3/ST7105/stapisdk$ touch bin/setenv.sh


5.3 make 3pp hal

leosu@leosu:/mnt/sda3/dev_iptv/DEV_youtube_4_4/hal/3pp/stapi-sdk-7109$ make local_all

 

5.4 copy ko file into box rootdisk:

leosu@leosu:/mnt/sda3/dev_iptv/DEV_youtube_4_4/hal/3pp/stapi-sdk-7109$ sudo cp st40/vip19x3/ST7105/dist/modules/stapi_all.ko  /opt/nfs/rootdisk_19x3/rootdisk/lib/modules/stapi/stapi_all.ko 


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
这个错误通常是由于缺少共享对象文件导致的。当程序试图加载一个共享对象文件,但找不到该文件时,就会出现这个错误信息。根据您提供的引用内容,该错误信息中指出了缺少的共享对象文件的名称,比如libascend_hal.so。要解决这个错误,您可以采取以下步骤: 1. 确认共享对象文件是否存在。您可以使用命令`ls`来检查文件是否存在。例如,使用命令`ls /path/to/libascend_hal.so`来检查libascend_hal.so文件是否位于指定的路径中。 2. 如果文件不存在,您需要找到正确的共享对象文件,并将其放置在正确的位置。您可以从官方网站或其他来源下载所需的共享对象文件。 3. 如果文件存在但仍然无法加载,可能是因为系统无法找到该文件的路径。在这种情况下,您可以尝试将共享对象文件所在的目录添加到LD_LIBRARY_PATH环境变量中。可以使用以下命令将目录添加到LD_LIBRARY_PATH中: export LD_LIBRARY_PATH=/path/to/directory:$LD_LIBRARY_PATH 4. 如果您正在使用特定的应用程序或库,您还可以尝试重新编译该应用程序或库,以确保它们能够正确链接到所需的共享对象文件。 请注意,这些步骤可能会因具体情况而有所不同,具体解决方法取决于您的操作系统和应用程序的要求。建议您查阅相关文档或向开发者寻求帮助以获取更具体的解决方案。<span class="em">1</span><span class="em">2</span><span class="em">3</span>

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值