显示 start_index 为 invalid syntax
hm1375_parrotv1.1验证通过_20170824_1528.7z
全志R16的parrotv1.1的系统调通摄像头hm1375 2017/8/24 14:04 版本:V1.1 开发板:SC3817R OS:parrotv1.1(Android4.4.2) 1、 R:\wyb\hm1375_parrotv1.1\android\device\softwinner\astar-evb30\configs\camera.cfg ;------------------------------------------------------------------------------- ; 用于camera的配置 ; ; 采用格式: ; key = key_value ; 注意: 每个key需要顶格写; ; key_value紧跟着key后面的等号后面, 位于同一行中; ; key_value限制大小为256字节以内; ; ;------------------------------------------------------------------------------- ;------------------------------------------------------------------------------- ; exif information of "make" and "model" ;------------------------------------------------------------------------------- key_camera_exif_make = MAKE_A31S key_camera_exif_model = MODEL_A31ST ;------------------------------------------------------------------------------- ; 1 for single camera, 2 for double camera ;------------------------------------------------------------------------------- number_of_camera = 1 ;------------------------------------------------------------------------------- ; CAMERA_FACING_BACK ; gc0307 hm1375 ;------------------------------------------------------------------------------- camera_id = 0 ;------------------------------------------------------------------------------- ; 1 for CAMERA_FACING_FRONT ; 0 for CAMERA_FACING_BACK ;------------------------------------------------------------------------------- camera_facing = 0 ;------------------------------------------------------------------------------- ; 1 for camera without isp(using built-in isp of Axx) ; 0 for camera with isp ;------------------------------------------------------------------------------- use_builtin_isp = 0 ;------------------------------------------------------------------------------- ; camera orientation (0, 90, 180, 270) ;------------------------------------------------------------------------------- camera_orientation = 90 ;------------------------------------------------------------------------------- ; driver device name ;------------------------------------------------------------------------------- camera_device = /dev/video0 ;------------------------------------------------------------------------------- ; device id ; for two camera devices with one CSI ;------------------------------------------------------------------------------- device_id = 0 used_preview_size = 1 key_support_preview_size = 1280x1024, 1280x960, 1280x720, 640x480 key_default_preview_size = 640x480 used_picture_size = 1 key_support_picture_size = 1280x1024, 1280x960, 1280x720, 640x480 key_default_picture_size = 640x480 used_flash_mode = 0 key_support_flash_mode = on,off,auto key_default_flash_mode = on used_color_effect=0 key_support_color_effect = none,mono,negative,sepia,aqua key_default_color_effect = none used_frame_rate = 1 key_support_frame_rate = 10 key_default_frame_rate = 10 used_focus_mode = 0 key_support_focus_mode = auto,infinity,macro,fixed,continuous-video,continuous-picture key_default_focus_mode = auto used_scene_mode = 0 key_support_scene_mode = auto,portrait,landscape,night,night-portrait,theatre,beach,snow,sunset,steadyphoto,fireworks,sports,party,candlelight,barcode key_default_scene_mode = auto used_white_balance = 0 key_support_white_balance = auto,incandescent,fluorescent,warm-fluorescent,daylight,cloudy-daylight key_default_white_balance = auto used_exposure_compensation = 1 key_max_exposure_compensation = 3 key_min_exposure_compensation = -3 key_step_exposure_compensation = 1 key_default_exposure_compensation = 0 2、录像的时候需要干掉对1080p分辨率的支持(HM1375最大支持720p): R:\wyb\hm1375_parrotv1.1\android\device\softwinner\astar-evb30\configs\media_profiles.xml <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2010 The Android Open Source Project Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> <!DOCTYPE MediaSettings [ <!ELEMENT MediaSettings (CamcorderProfiles, EncoderOutputFileFormat+, VideoEncoderCap+, AudioEncoderCap+, VideoDecoderCap, AudioDecoderCap)> <!ELEMENT CamcorderProfiles (EncoderProfile+, ImageEncoding+, ImageDecoding, Camera)> <!ELEMENT EncoderProfile (Video, Audio)> <!ATTLIST EncoderProfile quality (high|low) #REQUIRED> <!ATTLIST EncoderProfile fileFormat (mp4) #REQUIRED> <!ATTLIST EncoderProfile duration (30|60) #REQUIRED> <!ELEMENT Video EMPTY> <!ATTLIST Video codec (h264|h263|m4v) #REQUIRED> <!ATTLIST Video bitRate CDATA #REQUIRED> <!ATTLIST Video width CDATA #REQUIRED> <!ATTLIST Video height CDATA #REQUIRED> <!ATTLIST Video frameRate CDATA #REQUIRED> <!ELEMENT Audio EMPTY> <!ATTLIST Audio codec (amrnb|amrwb|aac) #REQUIRED> <!ATTLIST Audio bitRate CDATA #REQUIRED> <!ATTLIST Audio sampleRate CDATA #REQUIRED> <!ATTLIST Audio channels (1|2) #REQUIRED> <!ELEMENT ImageEncoding EMPTY> <!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED> <!ELEMENT ImageDecoding EMPTY> <!ATTLIST ImageDecoding memCap CDATA #REQUIRED> <!ELEMENT Camera EMPTY> <!ATTLIST Camera previewFrameRate CDATA #REQUIRED> <!ELEMENT EncoderOutputFileFormat EMPTY> <!ATTLIST EncoderOutputFileFormat name (mp4) #REQUIRED> <!ELEMENT VideoEncoderCap EMPTY> <!ATTLIST VideoEncoderCap name (h264) #REQUIRED> <!ATTLIST VideoEncoderCap enabled (true|false) #REQUIRED> <!ATTLIST VideoEncoderCap minBitRate CDATA #REQUIRED> <!ATTLIST VideoEncoderCap maxBitRate CDATA #REQUIRED> <!ATTLIST VideoEncoderCap minFrameWidth CDATA #REQUIRED> <!ATTLIST VideoEncoderCap maxFrameWidth CDATA #REQUIRED> <!ATTLIST VideoEncoderCap minFrameHeight CDATA #REQUIRED> <!ATTLIST VideoEncoderCap maxFrameHeight CDATA #REQUIRED> <!ATTLIST VideoEncoderCap minFrameRate CDATA #REQUIRED> <!ATTLIST VideoEncoderCap maxFrameRate CDATA #REQUIRED> <!ELEMENT AudioEncoderCap EMPTY> <!ATTLIST AudioEncoderCap name (amrnb|amrwb|aac|wma) #REQUIRED> <!ATTLIST AudioEncoderCap enabled (true|false) #REQUIRED> <!ATTLIST AudioEncoderCap minBitRate CDATA #REQUIRED> <!ATTLIST AudioEncoderCap maxBitRate CDATA #REQUIRED> <!ATTLIST AudioEncoderCap minSampleRate CDATA #REQUIRED> <!ATTLIST AudioEncoderCap maxSampleRate CDATA #REQUIRED> <!ATTLIST AudioEncoderCap minChannels (1|2) #REQUIRED> <!ATTLIST AudioEncoderCap maxChannels (1|2) #REQUIRED> <!ELEMENT VideoDecoderCap EMPTY> <!ATTLIST VideoDecoderCap name (wmv) #REQUIRED> <!ATTLIST VideoDecoderCap enabled (true|false) #REQUIRED> <!ELEMENT AudioDecoderCap EMPTY> <!ATTLIST AudioDecoderCap name (wma) #REQUIRED> <!ATTLIST AudioDecoderCap enabled (true|false) #REQUIRED> ]> <!-- This file is used to declare the multimedia profiles and capabilities on an android-powered device. --> <MediaSettings> <!-- Each camcorder profile defines a set of predefined configuration parameters --> <!-- Back Camera --> <!-- Front Camera --> <CamcorderProfiles cameraId="0"> <EncoderProfile quality="1080p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="9000000" width="1920" height="1080" frameRate="24" /> <Audio codec="aac" bitRate="128000" sampleRate="44100" channels="1" /> </EncoderProfile> <EncoderProfile quality="720p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="3000000" width="1280" height="720" frameRate="30" /> <Audio codec="aac" bitRate="128000" sampleRate="44100" channels="1" /> </EncoderProfile> <EncoderProfile quality="480p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="1500000" width="640" height="480" frameRate="30" /> <Audio codec="aac" bitRate="12200" sampleRate="8000" channels="1" /> </EncoderProfile> <EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="9000000" width="1920" height="1080" frameRate="24" /> <Audio codec="aac" bitRate="128000" sampleRate="44100" channels="1" /> </EncoderProfile> <EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="3000000" width="1280" height="720" frameRate="30" /> <!-- audio setting is ignored --> <Audio codec="aac" bitRate="128000" sampleRate="44100" channels="1" /> </EncoderProfile> <EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="1500000" width="640" height="480" frameRate="30" /> <Audio codec="aac" bitRate="12200" sampleRate="8000" channels="1" /> </EncoderProfile> <ImageEncoding quality="90" /> <ImageEncoding quality="80" /> <ImageEncoding quality="70" /> <ImageDecoding memCap="20000000" /> <Camera previewFrameRate="0" /> </CamcorderProfiles> <CamcorderProfiles cameraId="1"> <EncoderProfile quality="480p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="1500000" width="640" height="480" frameRate="10" /> <Audio codec="aac" bitRate="12200" sampleRate="8000" channels="1" /> </EncoderProfile> <EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30"> <Video codec="h264" bitRate="1500000" width="640" height="480" frameRate="10" /> <Audio codec="aac" bitRate="12200" sampleRate="8000" channels="1" /> </EncoderProfile> <ImageEncoding quality="90" /> <ImageEncoding quality="80" /> <ImageEncoding quality="70" /> <ImageDecoding memCap="20000000" /> <Camera previewFrameRate="0" /> </CamcorderProfiles> <EncoderOutputFileFormat name="mp4" /> <!-- If a codec is not enabled, it is invisible to the applications In other words, the applications won't be able to use the codec or query the capabilities of the codec at all if it is disabled --> <VideoEncoderCap name="h264" enabled="true" minBitRate="64000" maxBitRate="3000000" minFrameWidth="320" maxFrameWidth="1600" minFrameHeight="240" maxFrameHeight="1200" minFrameRate="1" maxFrameRate="30" /> <AudioEncoderCap name="aac" enabled="true" minBitRate="12200" maxBitRate="51200" minSampleRate="8000" maxSampleRate="44100" minChannels="1" maxChannels="2" /> <AudioEncoderCap name="amrwb" enabled="true" minBitRate="6600" maxBitRate="23050" minSampleRate="16000" maxSampleRate="16000" minChannels="1" maxChannels="1" /> <AudioEncoderCap name="amrnb" enabled="true" minBitRate="5525" maxBitRate="12200" minSampleRate="8000" maxSampleRate="8000" minChannels="1" maxChannels="1" /> <!-- FIXME: We do not check decoder capabilities at present At present, we only check whether windows media is visible for TEST applications. For other applications, we do not perform any checks at all. --> <VideoDecoderCap name="wmv" enabled="true"/> <AudioDecoderCap name="wma" enabled="true"/> <!-- The VideoEditor Capability configuration: - maxInputFrameWidth: maximum video width of imported video clip. - maxInputFrameHeight: maximum video height of imported video clip. - maxOutputFrameWidth: maximum video width of exported video clip. - maxOutputFrameHeight: maximum video height of exported video clip. - maxPrefetchYUVFrames: maximum prefetch YUV frames for encoder, used to limit the amount of memory for prefetched YUV frames. For this platform, it allows maximum 30MB(3MB per 1080p frame x 10 frames) memory. --> <VideoEditorCap maxInputFrameWidth="1920" maxInputFrameHeight="1080" maxOutputFrameWidth="1920" maxOutputFrameHeight="1080" maxPrefetchYUVFrames="10"/> <!-- The VideoEditor Export codec profile and level values correspond to the values in OMX_Video.h. E.g. for h264, profile value 1 means OMX_VIDEO_AVCProfileBaseline and level 4096 means OMX_VIDEO_AVCLevel41. Please note that the values are in decimal. These values are for video encoder. --> <!-- Codec = h.264, Baseline profile, level 4.1 --> <ExportVideoProfile name="h264" profile= "1" level="4096"/> <!-- Codec = h.263, Baseline profile, level 0 --> <ExportVideoProfile name="h263" profile= "1" level="1"/> <!-- Codec = mpeg4, Simple profile, level 5 --> <ExportVideoProfile name="m4v" profile= "1" level="128"/> </MediaSettings> 3、 R:\wyb\hm1375_parrotv1.1\android\device\softwinner\astar-evb30\init.sun8i.rc #csi module insmod /system/vendor/modules/videobuf-core.ko insmod /system/vendor/modules/videobuf-dma-contig.ko insmod /system/vendor/modules/cam_detect.ko #insmod /system/vendor/modules/actuator.ko #insmod /system/vendor/modules/ad5820_act.ko insmod /system/vendor/modules/cci.ko insmod /system/vendor/modules/vfe_os.ko insmod /system/vendor/modules/vfe_subdev.ko #insmod /system/vendor/modules/gc0307.ko #insmod /system/vendor/modules/ov2035.ko #insmod /system/vendor/modules/ov2640.ko #insmod /system/vendor/modules/ov5640.ko insmod /system/vendor/modules/hm1375.ko insmod /system/vendor/modules/vfe_v4l2.ko 4、可选修改: R:\wyb\hm1375_parrotv1.1\android\device\softwinner\astar-evb30\ueventd.sun8i.rc /dev/video0 0666 media media #/dev/video1 0666 media media 5、可选修改: R:\wyb\hm1375_parrotv1.1\android\frameworks\base\packages\SettingsProvider\res\values\defaults.xml <integer name="def_screen_off_timeout">60000</integer> <bool name="def_lockscreen_disabled">false</bool> 修改为: <integer name="def_screen_off_timeout">1800000</integer> <bool name="def_lockscreen_disabled">true</bool> 6、 R:\wyb\hm1375_parrotv1.1\android\frameworks\base\services\java\com\android\server\BatteryService.java public final class BatteryService extends Binder { private static final String TAG = BatteryService.class.getSimpleName(); // private static final boolean DEBUG = false; private static final boolean DEBUG = true; private static final int BATTERY_SCALE = 100; // battery capacity is a percentage // Used locally for determining when to make a last ditch effort to log // discharge stats before the device dies. private int mCriticalBatteryLevel; …… private void sendIntentLocked() { // Pack up the values and broadcast them to everyone final Intent intent = new Intent(Intent.ACTION_BATTERY_CHANGED); intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY | Intent.FLAG_RECEIVER_REPLACE_PENDING); int icon = getIconLocked(mBatteryProps.batteryLevel); intent.putExtra(BatteryManager.EXTRA_STATUS, mBatteryProps.batteryStatus); intent.putExtra(BatteryManager.EXTRA_HEALTH, mBatteryProps.batteryHealth); intent.putExtra(BatteryManager.EXTRA_PRESENT, mBatteryProps.batteryPresent); //intent.putExtra(BatteryManager.EXTRA_LEVEL, mBatteryProps.batteryLevel); intent.putExtra(BatteryManager.EXTRA_LEVEL, 100); intent.putExtra(BatteryManager.EXTRA_SCALE, BATTERY_SCALE); intent.putExtra(BatteryManager.EXTRA_ICON_SMALL, icon); intent.putExtra(BatteryManager.EXTRA_PLUGGED, mPlugType); //intent.putExtra(BatteryManager.EXTRA_VOLTAGE, mBatteryProps.batteryVoltage); intent.putExtra(BatteryManager.EXTRA_VOLTAGE, 4200); intent.putExtra(BatteryManager.EXTRA_TEMPERATURE, mBatteryProps.batteryTemperature); intent.putExtra(BatteryManager.EXTRA_TECHNOLOGY, mBatteryProps.batteryTechnology); intent.putExtra(BatteryManager.EXTRA_INVALID_CHARGER, mInvalidCharger); if (DEBUG) { Slog.d(TAG, "2016/12/05 10:41 wenyuanbo **** Sending ACTION_BATTERY_CHANGED. level:" + mBatteryProps.batteryLevel + ", scale:" + BATTERY_SCALE + ", status:" + mBatteryProps.batteryStatus + ", health:" + mBatteryProps.batteryHealth + ", present:" + mBatteryProps.batteryPresent + ", voltage: " + mBatteryProps.batteryVoltage + ", temperature: " + mBatteryProps.batteryTemperature + ", technology: " + mBatteryProps.batteryTechnology + ", AC powered:" + mBatteryProps.chargerAcOnline + ", USB powered:" + mBatteryProps.chargerUsbOnline + ", Wireless powered:" + mBatteryProps.chargerWirelessOnline + ", icon:" + icon + ", invalid charger:" + mInvalidCharger); } mHandler.post(new Runnable() { @Override public void run() { ActivityManagerNative.broadcastStickyIntent(intent, null, UserHandle.USER_ALL); } }); } …… } 7、低电量的时候摄像头会被关闭: R:\wyb\hm1375_parrotv1.1\android\packages\apps\Camera2\src\com\android\camera\CameraActivity.java import static com.android.camera.CameraManager.CameraOpenErrorCallback; public class CameraActivity extends Activity implements ModuleSwitcher.ModuleSwitchListener, ActionBar.OnMenuVisibilityListener, ShareActionProvider.OnShareTargetSelectedListener { private static final String TAG = "CAM_Activity"; private static final String INTENT_ACTION_STILL_IMAGE_CAMERA_SECURE = "android.media.action.STILL_IMAGE_CAMERA_SECURE"; public static final String ACTION_IMAGE_CAPTURE_SECURE = "android.media.action.IMAGE_CAPTURE_SECURE"; public static final String ACTION_TRIM_VIDEO = "com.android.camera.action.TRIM"; public static final String MEDIA_ITEM_PATH = "media-item-path"; …… private Intent mVideoShareIntent; private Intent mImageShareIntent; private AlertDialog mLocationDialog; private BroadcastReceiver mBatteryInfoReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if (Intent.ACTION_BATTERY_CHANGED.equals(action)) { int Level = intent.getIntExtra("level", 0); int Scale = intent.getIntExtra("scale", 100); Log.w(TAG, "2016/11/29 19:54 &&&& wenyuanbo battery Level" + Level); /* *Logic: *1.the battery level is lower then 5%. *2.if in camera, make sure that not in the snapshot progress. *3.if in videocamera, make sure that not in the videorecording progress. *4.everytime starting the camera activity, the battery level is broadcasted, * if meeting the conditions above, give a dialog, press it and finish the activity. *5.if the conditions are not satisfied when started, play for a moment, in the camera acitvity * or video camera activity, the conditiosn are satisfied, also give a dialog for finishing the activity. * *by fuqiang. */ if(Level < 5) { Runnable runnable_close_camera = new Runnable() { @Override public void run() { //close the camera. // CameraActivity.this.finish(); } }; Log.w(TAG, "2016/11/29 18:20 **** wenyuanbo battery Level" + Level); showLocationDialog(); } /* *Logic: *1.the battery level is lhigher then 5% and lower than 15%. *2.if in camera, make sure that not in the snapshot progress. *3.if in videocamera, make sure that not in the videorecording progress. *4.whether in camera or in videocamera, make sure that the flash mode is supported. *5.everytime starting the camera activity, the battery level is broadcasted, * if meeting the conditions above, forbidden the flash(gray icon), give a dialog to notise user. *6.if the conditions are not satisfied when started, play for a moment, in the camera acitvity * or video camera activity, the conditiosn are satisfied, forbidden the flash and give a notice dialog. *7.the dialog is only given once for each camera activity starting. * *by fuqiang. */ else if(Level < 16) { //close the flash mode. /* if (mIsLowBatteryDialogShown == false) { mRotateDialog.showAlertDialog( getString(R.string.warning), getString(R.string.low_battery_15), null, null, getString(R.string.close), null); mIsLowBatteryDialogShown = true; } */ } } } }; …… } 8、HM1375的驱动程序请直接联系HiMax原厂或者代理商: R:\wyb\hm1375_parrotv1.1\lichee\linux-3.4\drivers\media\video\sunxi-vfe\device\hm1375.c R:\wyb\hm1375_parrotv1.1\lichee\linux-3.4\drivers\media\video\sunxi-vfe\device\Makefile obj-m += ov5640.o obj-m += hm1375.o obj-m += hm5065.o obj-m += ov2640.o obj-m += ov7736.o #obj-m += s5k4ec.o #obj-m += s5k4ec_mipi.o #obj-m += gc2035.o #obj-m += gt2005.o #obj-m += gc0307.o obj-m += gc0308.o #obj-m += gc0309.o #obj-m += gc0328.o #obj-m += gc0329.o #obj-m += gc0311.o #obj-m += hi253.o #obj-m += sp2518.o #obj-m += sp2519.o #obj-m += sp0718.o #obj-m += sp0838.o #obj-m += ov16825.o #obj-m += ov5650.o #obj-m += ov5647.o #obj-m += ov5647_mipi.o #obj-m += t8et5.o #obj-m += s5k4e1.o #obj-m += s5k4e1_mipi.o #obj-m += sp2518.o #obj-m += sp0718.o #obj-m += gc5004.o #obj-m += gc5004_mipi.o #obj-m += ov5648.o #obj-m += ar0330.o #obj-m += ov5648.o #obj-m += sp5408.o #obj-m += ov12830.o #obj-m += ov8825.o #obj-m += ov8850.o #obj-m += gc2155.o #obj-m += ov8858.o #obj-m += ov13850.o #obj-m += ov8858_4lane.o 9、hm1375项请参照ov2640填写: R:\wyb\hm1375_parrotv1.1\lichee\linux-3.4\drivers\media\video\sunxi-vfe\sensor_info.c struct sensor_item sensor_list_t[] = { // name i2c_addr sensor type sensor size sensor max pclk //{ "gc2145" , 0x78, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "hm1375" , 0x48, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "hm5065" , 0x3e, SENSOR_YUV , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov2640" , 0x60, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "ov5640" , 0x78, SENSOR_YUV , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov5647" , 0x6c, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov5647_mipi" , 0x6c, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov5650" , 0x50, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov5648" , 0x6c, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ov8825" , 0x6c, SENSOR_RAW , PIXEL_NUM_8M , CORE_CLK_RATE_FOR_8M}, { "ov8850" , 0x20, SENSOR_RAW , PIXEL_NUM_8M , CORE_CLK_RATE_FOR_8M}, { "ov12830" , 0x6c, SENSOR_RAW , PIXEL_NUM_12M , CORE_CLK_RATE_FOR_16M}, { "ov16825" , 0x6c, SENSOR_RAW , PIXEL_NUM_16M , CORE_CLK_RATE_FOR_16M}, { "gc0329" , 0x62, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc0309" , 0x42, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc0307" , 0x42, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc0308" , 0x42, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc2035" , 0x78, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "gt2005" , 0x78, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "gc2015" , 0x60, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "gc2235" , 0x78, SENSOR_RAW , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "sp0838" , 0x30, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "sp0718" , 0x6c, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "sp2518" , 0x6c, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "hi253" , 0x40, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "hi257" , 0x40, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "s5k4ec" , 0x5a, SENSOR_YUV , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "s5k4ec_mipi" , 0x5a, SENSOR_YUV , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "s5k4e1" , 0x20, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "s5k4e1_mipi" , 0x20, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "t4k05" , 0x6c, SENSOR_RAW , PIXEL_NUM_8M , CORE_CLK_RATE_FOR_8M}, { "t8et5" , 0x78, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "ar0330" , 0x20, SENSOR_RAW , PIXEL_NUM_3M , CORE_CLK_RATE_FOR_3M}, { "bf3a03" , 0xDC, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc0311" , 0x66, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc0311" , 0x66, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, { "gc5004" , 0x6c, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "gc5004_mipi" , 0x6c, SENSOR_RAW , PIXEL_NUM_5M , CORE_CLK_RATE_FOR_5M}, { "nt99252" , 0x6c, SENSOR_YUV , PIXEL_NUM_2M , CORE_CLK_RATE_FOR_2M}, { "ov7736" , 0x42, SENSOR_YUV , PIXEL_NUM_0_3M , CORE_CLK_RATE_FOR_2M}, }; 10、 R:\wyb\hm1375_parrotv1.1\lichee\tools\pack\chips\sun8iw5p1\configs\default\env.cfg bootdelay=3 #default bootcmd, will change at runtime according to key press bootcmd=run setargs_nand boot_normal#default nand boot #kernel command arguments console=ttyS0,115200 nand_root=/dev/nandd mmc_root=/dev/mmcblk0p7 init=/init loglevel=8 #set kernel cmdline if boot.img or recovery.img has no cmdline we will use this setargs_nand=setenv bootargs console=${console} root=${nand_root} init=${init} ion_cma_512m=120m ion_cma_1g=176m ion_carveout_512m=96m ion_carveout_1g=150m coherent_pool=4m loglevel=${loglevel} partitions=${partitions} setargs_mmc=setenv bootargs console=${console} root=${mmc_root} init=${init} ion_cma_512m=120m ion_cma_1g=176m ion_carveout_512m=96m ion_carveout_1g=150m coherent_pool=4m loglevel=${loglevel} partitions=${partitions} #nand command syntax: sunxi_flash read address partition_name read_bytes #0x40007800 = 0x40008000(kernel entry) - 0x800(boot.img header 2k) boot_normal=sunxi_flash read 40007800 boot;boota 40007800 boot_recovery=sunxi_flash read 40007800 recovery;boota 40007800 boot_fastboot=fastboot #recovery key recovery_key_value_max=0x13 recovery_key_value_min=0x10 #fastboot key fastboot_key_value_max=0x8 fastboot_key_value_min=0x2 11、 R:\wyb\hm1375_parrotv1.1\lichee\tools\pack\chips\sun8iw5p1\configs\evb-30\sys_config.fex ;---------------------------------------------------------------------------------- ;dcdc1_vol ---set dcdc1 voltage,mV,1600-3400,100mV/step ;dcdc2_vol ---set dcdc2 voltage,mV,600-1540,20mV/step ;dcdc3_vol ---set dcdc3 voltage,mV,600-1860,20mV/step ;dcdc4_vol ---set dcdc4 voltage,mV,600-1540,20mV/step ;dcdc5_vol ---set dcdc5 voltage,mV,1000-2550,50mV/step ;aldo2_vol ---set aldo2 voltage,mV,700-3300,100mV/step ;aldo3_vol ---set aldo3 voltage,mV,700-3300,100mV/step ;---------------------------------------------------------------------------------- [power_sply] dcdc1_vol = 3000 dcdc2_vol = 1100 dcdc3_vol = 1200 dcdc4_vol = 0 dcdc5_vol = 1500 aldo2_vol = 2500 aldo3_vol = 3000 dldo3_vol = 2800 ;gpio0_vol = 2800 ldoio0_vol = 2800 ;-------------------------------------------------------------------------------- ;vip (video input port) configuration ;vip_used: 0:disable 1:enable ;vip_mode: 0:sample one interface to one buffer 1:sample two interface to one buffer ;vip_dev_qty: The quantity of devices linked to capture bus ; ;vip_define_sensor_list: If you want use sensor detect function, please set vip_define_sensor_list = 1, and ; verify that file /system/etc/hawkview/sensor_list_cfg.ini is properly configured! ; ;vip_dev(x)_pos: sensor position, "rear" or "front", if vip_define_sensor_list = 1,vip_dev(x)_pos must be configured! ; ;vip_dev(x)_isp_used 0:not use isp 1:use isp ;vip_dev(x)_fmt: 0:yuv 1:bayer raw rgb ;vip_dev(x)_stby_mode: 0:not shut down power at standby 1:shut down power at standby ;vip_dev(x)_vflip: flip in vertical direction 0:disable 1:enable ;vip_dev(x)_hflip: flip in horizontal direction 0:disable 1:enable ;vip_dev(x)_iovdd: camera module io power handle string, pmu power supply ;vip_dev(x)_iovdd_vol: camera module io power voltage, pmu power supply ;vip_dev(x)_avdd: camera module analog power handle string, pmu power supply ;vip_dev(x)_avdd_vol: camera module analog power voltage, pmu power supply ;vip_dev(x)_dvdd: camera module core power handle string, pmu power supply ;vip_dev(x)_dvdd_vol: camera module core power voltage, pmu power supply ;vip_dev(x)_afvdd: camera module vcm power handle string, pmu power supply ;vip_dev(x)_afvdd_vol: camera module vcm power voltage, pmu power supply ;x indicates the index of the devices which are linked to the same capture bus ;fill voltage in uV, e.g. iovdd = 2.8V, vip_devx_iovdd_vol = 2800000 ;fill handle string as below: ;axp22_eldo3 ;axp22_dldo4 ;axp22_eldo2 ;fill handle string "" when not using any pmu power supply ;-------------------------------------------------------------------------------- [csi0] vip_used = 1 vip_mode = 0 vip_dev_qty = 1 vip_define_sensor_list = 0 vip_csi_pck = port:PE00<2><default><default><default> vip_csi_mck = port:PE01<2><default><default><default> vip_csi_hsync = port:PE02<2><default><default><default> vip_csi_vsync = port:PE03<2><default><default><default> vip_csi_d0 = port:PE04<2><default><default><default> vip_csi_d1 = port:PE05<2><default><default><default> vip_csi_d2 = port:PE06<2><default><default><default> vip_csi_d3 = port:PE07<2><default><default><default> vip_csi_d4 = port:PE08<2><default><default><default> vip_csi_d5 = port:PE09<2><default><default><default> vip_csi_d6 = port:PE10<2><default><default><default> vip_csi_d7 = port:PE11<2><default><default><default> vip_csi_sck = port:PE12<2><default><default><default> vip_csi_sda = port:PE13<2><default><default><default> ;vip_dev0_mname = "ov5640" vip_dev0_mname = "hm1375" ;vip_dev0_mname = "hm5065" vip_dev0_pos = "rear" vip_dev0_lane = 1 vip_dev0_twi_id = 2 ;vip_dev0_twi_addr = 0x78 vip_dev0_twi_addr = 0x48 ;vip_dev0_twi_addr = 0x3e vip_dev0_isp_used = 0 vip_dev0_fmt = 0 (在调试的时候请置0:) vip_dev0_stby_mode = 0 vip_dev0_vflip = 0 vip_dev0_hflip = 0 ;vip_dev0_iovdd = "axp22_dldo3" vip_dev0_iovdd = "" vip_dev0_iovdd_vol = 2800000 vip_dev0_avdd = "axp22_ldoio0" vip_dev0_avdd_vol = 2800000 vip_dev0_dvdd = "" vip_dev0_dvdd_vol = 1800000 vip_dev0_afvdd = "" vip_dev0_afvdd_vol = 2800000 vip_dev0_power_en = vip_dev0_reset = port:PE14<1><default><default><0> vip_dev0_pwdn = port:PE15<1><default><default><1> vip_dev0_flash_en = vip_dev0_flash_mode = vip_dev0_af_pwdn = power_start = 3