声卡模块在SkyEye 1.3.1上的尝试(失败,仅备忘)

原先SkyEye 1.3.1上是支持声卡的(s3c44b0/s3c44b0x)。新版本将这个功能去了。本以为和触摸屏类似,再加上就可以了。具体修改如下:

1. gedit device/sound/dev_sound_s3c44b0x.c &
    在:
    {"s3c44b0x",    IISFIF_RX_CONTROL,    0x08,    {0, 0, 0, 0}},
    的下面添加:
    {"s3c2410x",    IISFIF_RX_CONTROL,    0x08,    {0, 0, 0, 0}},

    将:
extern ARMhword *s3c44b0x_iisfifo_tx; /* defined in "skyeye_mach_s3c44b0x.c" */
    改成:[失败的根源]
ARMhword *s3c44b0x_iisfifo_tx; /* defined in "skyeye_mach_s3c44b0x.c" */

2. gedit device/sound/skyeye_sound.c &
将:
    //sound_s3c44b0x_init(mod_set);
改成:
    sound_s3c44b0x_init(mod_set);

3. gedit device/Makefile.am &
取消
#dev_sound = sound/dev_sound_s3c44b0x.c  sound/skyeye_sound.c  sound/skyeye_sound_pcm.c sound/sound_module.c
的注释,然后将:
dev_sound = sound/skyeye_sound.c  sound/skyeye_sound_pcm.c sound/sound_module.c
注释掉

4. gedit device/Makefile.in &
将:
am__objects_7 = skyeye_sound.lo skyeye_sound_pcm.lo sound_module.lo
改成:
am__objects_7 = dev_sound_s3c44b0x.lo skyeye_sound.lo skyeye_sound_pcm.lo sound_module.lo

取消
#dev_sound = sound/dev_sound_s3c44b0x.c  sound/skyeye_sound.c  sound/skyeye_sound_pcm.c sound/sound_module.c
的注释

dev_sound = sound/skyeye_sound.c  sound/skyeye_sound_pcm.c sound/sound_module.c
注释掉

在:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dev_net_rtl8019.Plo@am__quote@
的下面添加:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dev_sound_s3c44b0x.Plo@am__quote@

在:
net_module.lo: net/net_module.c
@am__fastdepCC_TRUE@    $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net_module.lo -MD -MP -MF $(DEPDIR)/net_module.Tpo -c -o net_module.lo `test -f 'net/net_module.c' || echo '$(srcdir)/'`net/net_module.c
@am__fastdepCC_TRUE@    mv -f $(DEPDIR)/net_module.Tpo $(DEPDIR)/net_module.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@    source='net/net_module.c' object='net_module.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@    DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@    $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net_module.lo `test -f 'net/net_module.c' || echo '$(srcdir)/'`net/net_module.c
的下面添加:
dev_sound_s3c44b0x.lo: sound/dev_sound_s3c44b0x.c
@am__fastdepCC_TRUE@    $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dev_sound_s3c44b0x.lo -MD -MP -MF $(DEPDIR)/dev_sound_s3c44b0x.Tpo -c -o dev_sound_s3c44b0x.lo `test -f 'sound/dev_sound_s3c44b0x.c' || echo '$(srcdir)/'`sound/dev_sound_s3c44b0x.c
@am__fastdepCC_TRUE@    mv -f $(DEPDIR)/dev_sound_s3c44b0x.Tpo $(DEPDIR)/dev_sound_s3c44b0x.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@    source='sound/dev_sound_s3c44b0x.c' object='dev_sound_s3c44b0x.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@    DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@    $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dev_sound_s3c44b0x.lo `test -f 'sound/dev_sound_s3c44b0x.c' || echo '$(srcdir)/'`sound/dev_sound_s3c44b0x.c

重新编译安装SkyEye,然后在skyeye.conf文件中添加:
sound: type=s3c2410x, mod=pcm, channels=2, bits_per_sample=16, samples_per_sec=22050
启动时可以看到:
sound: channels:2, bits_per_sample:16, samples_per_sec:22050.
表示SkyEye可以识别sound配置项了。但是启动后还是没有声卡设备!

问题的根源就是
extern ARMhword *s3c44b0x_iisfifo_tx;
上,老版本的SkyEye的这个变量是在s3c44b0的mach文件中定义的,为了能运行我将它改成本地变量,这样自然不行了。哎,可惜本人能力精力有限,不然就帮SkyEye实现声卡模块了。看来只有等新版本的SkyEye来支持声卡模块了。

你可能感兴趣的:(c,object,include)