




版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
ImportantSamsungElectronicsCo.Ltd.(“Samsung”)reservestherighttomakechangestotheinformationinthispublicationatanytimewithoutImportantSamsungElectronicsCo.Ltd.(“Samsung”)reservestherighttomakechangestotheinformationinthispublicationatanytimewithoutpriornotice.Allinformationprovidedisforreferencepurposeonly.Samsungassumesnoresponsibilityforpossibleerrorsoromissions,orforanyconsequencesresultingfromtheuseoftheinformationcontainedherein.anyinformationprovidedinthispublication.CustomershallindemnifyandholdSamsunganditsofficers,employees,subsidiaries,affiliates,anddistributorsharmlessagainstallclaims,costs,damages,expenses,andreasonableattorneyfeesarisingoutof,eitherdirectlyorindirectly,anyclaim(includingbutnotlimitedtopersonalinjuryordeath)thatmaybeassociatedwithsuchunintended,unauthorizedand/orillegaluse.Thispublicationonitsowndoesnotconveyanylicense,eitherexpressorimplied,relatingtoanySamsungand/orthird-partyproducts,undertheintellectualpropertyrightsofSamsungand/oranythirdparties.WARNINGNopartofthispublicationmaybereproduced,storedinaretrievalsystem,ortransmittedinanyformorbyanymeans,electricormechanical,byphotocopying,recording,orotherwise,withoutthepriorwrittenconsentofSamsung.Thispublicationisintendedforusebydesignatedrecipientsonly.Thispublicationcontainsconfidentialinformation(includingtradesecrets)ofSamsungprotectedbyCompetitionLaw,TradeSecretsProtectionActandotherrelatedlaws,andthereforemaynotbe,inpartorinwhole,directlyorindirectlypublicized,distributed,photocopiedorSamsungmakesnowarranty,representation,orguaranteeregardingthesuitabilityofitsproductsforanyparticularpurpose,nordoesSamsungassumeanyliabilityarisingoutoftheapplicationoruseofanyproductorcircuitandspecificallydisclaimsanyandallliability,includingwithoutlimitationanyconsequentialorincidentaldamages.used(includinginapostingontheInternetCustomersareresponsiblefortheirownproductsSAMSUNGunspecifiedaccessispossible)byanyunauthorizedapplications."Typical"parameterscananddovaryparty.Samsungreservesitsrighttotakeanyandmeasuresbothinequityandlawavailabletoitandclaim"Typicals"mustbevalidatedforeachcustomerdamagesagainstanypartythatmisappropriatesbythectm'stptJeff_cuiattrt/riilifration.Samsungproductsarenotdesigned,intended,orauthorizedforuseinapplicationsintendedtosupportorsustainlife,orforanyotherapplicationinwhichthefailureoftheSamsung警 本文件仅向经韩国三星电子株式会社授权的人员提供productcouldreasonablybeexpectedtocreateasituationwherepersonalinjuryordeathmayoccur.CustomersacknowledgeandagreethattheyaresolelyresponsibletomeetallotherlegalandregulatoryrequirementsregardingtheirapplicationsusingSamsungproductsnotwithstandingCopyright©2011SamsungElectronicsCo.,SamsungElectronicsCo.,San#24Nongseo-Dong,Giheung-GuContactUs:HomePage:Allbrandnames,Allbrandnames,trademarksandregisteredtrademarksbelongtotheirrespectiveExynos,Exynos4212,FlexOneNAND,andOneNANDaretrademarksofSamsungARM,Jazelle,TrustZone,andThumbareregisteredtrademarksofARMLimited.Cortex,ETM,ETB,Coresight,ISA,andNeonaretrademarksofARMLimited.JavaisatrademarkofSunMicrosystems,SDisaregisteredtrademarkofToshibaMMCandeMMCaretrademarksofMultiMediaCardAssociation.JTAGisaregisteredtrademarkofJTAGTechnologies,Inc.SynopsysisaregisteredtrademarkofSynopsys,Inc.I2SisatrademarkofPhillipsElectronics.I2CisatrademarkofPhillipsSemiconductorMIPIandSlimbusareregisteredtrademarksoftheMobileIndustryProcessorInterface(MIPI)AllothertrademarksusedinthispublicationarethepropertyoftheirrespectiveSAMSUNGsi-plaza/Jeff_cuiatChipHandlingPrecautionagainstElectrostaticWhenhandlingsemiconductordevices,ChipHandlingPrecautionagainstElectrostaticWhenhandlingsemiconductordevices,besurethattheenvironmentisprotectedagainststaticOperatorsshouldwearanti-staticclothinganduseearthAllobjectsthatcomeindirectcontactwithdevicesshouldbemadeofmaterialsthatdonotproducestaticelectricitythatwouldcausedamage.EquipmentandworktablemustbeIonizerisrecommendedtoremoveelectronBesuretousesemiconductorproductsintheenvironmentthatmaynotbeexposedtodustordirtSemiconductordevicesaresensitivetoenvironmenttemperatureandhumidity.Hightemperatureorhumiditymaydeterioratesemiconductordevice’scharacteristics.Thereforeavoidstorageoruseinsuchconditions.kSUNGCareshoudrtt/ycvilkrccrdevice.DonotexposesemiconductordevicetochemicalbecausereactiontochemicalmaycausedeteriorationofdeviceLightIncaseofnon-EMC(EpoxyMoldingCompound)package,donotexposesemiconductorICtostronglight.Itmaycausedevice’smalfunction.(But,somespecialproductswhichutilizethelightorhavesecurityfunctionareexceptedfromthisguide)Semiconductordevicescanbeinfluencedbyradioactive,cosmicrayorX-ray.Radioactive,cosmicandX-raymaycausesofterrorduringdeviceoperation.Thereforesemiconductordevicesmustbeshieldedunderenvironmentthatmaybeexposedtoradioactive,cosmicrayorX-ray.Notethatsemiconductordevice’scharacteristicsmaybeaffectedbystrongelectromagneticwaveormagneticfieldduringoperationunderinsufficientPCBcircuitdesignforEMS.SAMSUNGsi-plaza/Jeff_cuiatSAMSUNGsi-plaza/Jeff_cuiatRevisionFeb.27,Mar.8,AddChapter2.3.2TC4I2CdevicesTableofTableofStartandStop DataTransfer ACKSignal FlowchartsofOperationsinEach ConnectionofExynosandI2C TC4I2C 2.4.1RegisterMap KernelSetupand I2C Platform SAMSUNGsi-plaza/Jeff_cuiatListofListofFigureFigureFigureFigureFigureFigureFigureFigureFigureFigureFigureTC4I2C-BusBlock StartandStop I2C-BusInterfaceData DataTransferontheI2C- AcknowledgementontheI2C- OperationsforMaster/Receive I2CDriver SAMSUNGsi-plaza/Jeff_cuiatListofListofTableTableTableTableTableTableTable SupportedI2C ListofPinstobeUsedtoConnectExynosand TC4I2C RegisterMap I2C I2CSystemDriverFile SAMSUNGsi-plaza/Jeff_cuiatListofListofExampleExampleExampleExampleExampleTC4KernelSetupand Platform MachineDriver-mach- MachineDriver-setup- DeviceDriver-i2c- SAMSUNGsi-plaza/Jeff_cuiatListofRegisterRWAccessTypeRegisterValueSAMSUNGResetVleoListofRegisterRWAccessTypeRegisterValueSAMSUNGResetVleona/Jeff_cuiat Somebitsofcontrolregistersaredrivenbyhardwareorwriteoperationonly.Asaresulttheindicatedresetvalueandthereadvalueafterresetmightbedifferent.0Clearstheregister1SetstheregisterxDon'tcarexXUndefinedmultiple?Undefined,butdependsonthedeviceorpinDeviceThevaluedependsonthePinThevaluedependsonthepinRReadTheapplicationhaspermissiontoreadtheRegisterfield.Writestoread-onlyfieldshavenoeffect.WWriteTheapplicationhaspermissiontowriteintheRegisterRead&TheapplicationhaspermissiontoreadandwritesintheRegisterfield.Theapplicationsetsthisfieldbywriting1’b1andclearsitbywriting1’b0.ListofSAMSUNGsi-plaza/Jeff_cuiatListofSAMSUNGsi-plaza/Jeff_cuiatDeviceInter-IntegratedSamsungTC4I2CSystem_DriverDeveloper's11.1ThisdocumentdescribeshowtoapplytheSamsungTC4I2CSystem_DriverDeveloper's11.1ThisdocumentdescribeshowtoapplytheI2CdriverofAndroid4.0.3BSPbasedontheTC4referenceboardandisintendedforthedeveloperswhohaveexperienceddevelopmentofLinuxkernelandAndroid.1.2DocumentThemainpurposeofthisdocumentistoguideontheapplicationofTC4I2CsystemTherefore,itneedstounderstandtheI2C-relatedhardwareandsoftwareontheLinuxkerneldriverandAndroidplatformofTC4.ThisdocumentdescribessomehardwareIPslikeI2CSubsystem,andI2CdriverofLinuxkernelforSAMSUNGBlocksforI2CofExynos:I2C-BusBlockPartforI2CofTC4board:I2C-BusBlocksi-plaza/Jeff_cuiatSoftwareLinuxkernel:I2CdeviceConfigurationforTC4Android4.0.3DefaultI2CconfigurationforLinuxkernelandDriverI2Cdriver:Machine,CPU,PlatformandI2CdriversinLinuxSamsungTC4I2CSystem_DriverDeveloper's1.3OperationTableTableSamsungTC4I2CSystem_DriverDeveloper's1.3OperationTableTableSAMSUNGsi-plaza/Jeff_cuiatOut/MasterReceiveSlaveReceiveSlaveReceiveTC4ReferenceBoardforLinuxKernel3.0,Android4.0.3IceCreamBootU-Boot:SamsungTC4I2CSystem_DriverDeveloper's2H/WSamsungTC4I2CSystem_DriverDeveloper's2H/W2.1TC4I2CTheI2CinterfaceofExynossupports9channelsmulti-master,slaveI2Cbusinterfaces.Supportsupto100kbit/sintheStandardmodeandupto400kbit/sintheFastmode.TheI2C-BusBlockDiagramofTC4areshowninFigureFigureTC4I2C-BusBlockSAMSUNGsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper's2.2I2C-BusInterfaceSamsungTC4I2CSystem_DriverDeveloper's2.2I2C-BusInterfaceThefunctionalrelationshipsamongtheseoperatingmodesaredescribedinthesesections:StartandStopconditionsDatatransferformatRead-WriteoperationAbortconditionsConfiguringIIC-bus2.2.1StartandStopTheStartandStopconditionisshowninFigureSAMSUNGsi-plaza/Jeff_cuiatFigureStartandStopSamsungTC4I2CSystem_DriverDeveloper's2.2.2DataSamsungTC4I2CSystem_DriverDeveloper's2.2.2DataTransfersi-plaza/JFue-usIf2FigureDataTransferontheI2C-SAMSUNGSamsungTC4I2CSystem_DriverDeveloper's2.2.3ACKSamsungTC4I2CSystem_DriverDeveloper's2.2.3ACKSignalFigureSAMSUNG2.2.4FlowchartsofOperationsinEachsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper'sSamsungTC4I2CSystem_DriverDeveloper'sFigureFigure7illustratestheoperationsforMaster/ReceiverSAMSUNGsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper'sSamsungTC4I2CSystem_DriverDeveloper'sFigureSAMSUNGsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper'sSamsungTC4I2CSystem_DriverDeveloper'sFigureSAMSUNGsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper'sSamsungTC4I2CSystem_DriverDeveloper'sFigure9illustratestheoperationsforSlave/ReceiverFigureSAMSUNGsi-plaza/Jeff_cuiatSamsungTC4I2CSystem_DriverDeveloper'sDeviceConnectionsofTC4I2CConnectionofExynosandI2CTableListofPinstobeUsedtoConnectExynosandSAMSUNG2.3.2TC4I2CTableTC4I2CI2CFuelSamsungTC4I2CSystem_DriverDeveloper'sDeviceConnectionsofTC4I2CConnectionofExynosandI2CTableListofPinstobeUsedtoConnectExynosandSAMSUNG2.3.2TC4I2CTableTC4I2CI2CFuelUSBInput/I2C-businterface0serialclockInput/I2C-businterface0serialdataInput/I2C-businterface1serialclockInput/I2C-businterface1serialdataInput/I2C-businterface2serialclockInput/I2C-businterface2serialdataInput/I2C-businterface3serialclockInput/I2C-businterface3serialdataInput/I2C-businterface4serialclockInput/I2C-businterface4serialdataInput/I2C-businterface5serialclockInput/I2C-businterface5serialdataInput/I2C-businterface6serialclockInput/I2C-businterface6serialdataInput/I2C-businterface7serialclockIOutptiat1I2C-businterface7serialdataSamsungTC4I2CSystem_DriverDeveloper'sI2CRegisterRegisterMapBaseAddress:0x1386_0000,0x1387_0000,0x1388_0000,0x1389_0000,TableRegisterMapSAMSUNGsi-plazaSamsungTC4I2CSystem_DriverDeveloper'sI2CRegisterRegisterMapBaseAddress:0x1386_0000,0x1387_0000,0x1388_0000,0x1389_0000,TableRegisterMapSAMSUNGsi-plaza/Jeff_cuiatResetSpecifiestheI2C-businterface0controlSpecifiestheI2C-businterface0addressSpecifiestheI2C-businterface0transmit/receivedatashiftregisterSpecifiestheI2C-businterface0multi-masterlinecontrolregisterSamsungTC4I2CSystem_DriverDeveloper's3S/W3.1I2CDeviceI2CdevicedriverisSamsungTC4I2CSystem_DriverDeveloper's3S/W3.1I2CDeviceI2Cdevicedriverisplacedat3.2I2CTableI2CSThisfunctionregistersanI2CdrivertotheThisfunctionunregistersanI2Cdrivertothe*adap,u32ThisfunctioncheckswhethertheI2Cadapterhastheneededfunctionality.tticilievidictcit(ticit*dev,void*data)isfcitsertetatei2lsi-plaza)eff_cuiatThisfunctiongetstheprivatedatafrom01,2012ici.*msgs,intThisfunctionexecutesasingleorcombinedI2Cmessage. initi2c_register_board_info(intbusnum,structi2c_board_infoconst*info,unsignedlen)ThisfunctionregistersthedeviceinfototheSamsungTC4I2CSystem_DriverDeveloper's44.1SamsungTC4I2CSystem_DriverDeveloper's44.1KernelThischapterdescribestheconfigurationofLinuxkernelforTC4I2C4.1.1KernelSetupand"maketc4_dvt_icecream_defconfig"enablesthekernelsetupforTC4Android,anduse"makemenuconfig"fordetailedconfiguration.ExampleTC4KernelSetupandSAMSUNGsi-plaza/Jeff_cuiatandroid-kernel-samsung-dev$makemenuconfigSamsungTC4I2CSystem_DriverDeveloper's4.1.2I2CSamsungTC4I2CSystem_DriverDeveloper's4.1.2I2CThischapterdescribesthekernelconfigurationforI2CofTC4I2Csystem.InitialscreenofkernelconfigurationisshowninFigure10:si-plaza/Fgfcnit-gSelect"DeviceDriversI2CsupportI2CHardwareBussupportS3C2410I2CFigureI2CDriverSAMSUNGSamsungTC4I2CSystem_DriverDeveloper's5ThischapterdescribeshowtoapplytheI2CsystemSamsungTC4I2CSystem_DriverDeveloper's5ThischapterdescribeshowtoapplytheI2CsystemofAndroid4.0.3BSPbasedontheTC4reference5.1I2CDeviceDriverofTable7isthefiledeploymentofI2CsystemTableI2CSystemDriverFilePlatformDevice:I2CchannelSAMSUNGFile:dev-oSourceExample Platformstatistrucrsorec2ee] [0]=.start= =S3C_PA_IIC1+SZ_4K- [1]=.start= =3840structplatform_devices3c_device_i2c1{ ="s3c2410- = = 45};47voidinits3c_i2c1_set_platdata(structs3c2410_platform_i2c*pd)48{PlatformMachineDeviceSamsungTC4I2CSystem_DriverDeveloper's5.1.2MachineSamsungTC4I2CSystem_DriverDeveloper's5.1.2MachineFile:mach-oSourceExampleMachineDriver-mach-oSourceExampleMachineDriver-setup- , //ForS5K4EC(usingi2c6) i2c_register_board_info(7,i2c_devs7, if(!pd)pd=pd->bus_num=1;}npd=s3c_set_platdata(pd,sizeof(structif(!npd-npd->cfg_gpio=s3c_i2c1_cfg_gpio;61}SamsungTC4I2CSystem_DriverDeveloper's5.1.3DeviceSamsungTC4I2CSystem_DriverDeveloper's5.1.3DeviceoSourceExampleDeviceDriver-i2c-1124inti2c_register_driver(structmodule*owner,structi2c_driver*driver)1125{ int /*Can'tregisteruntilafterdrivermodelinitf return- s*dhivrothflfiventhrvrce*07.11 driver->driver.owner=owner; driver->driver.bus=&i2c_bus_type; /*Whenregistrationreturns,thedriver *willhavecalledprobe()forallmatching-but-unbounddevices. res=driver_register(&driver->driver); if(res) return /*Driversshouldswitchtodev_pm_opsinstead.*/ if(driver->suspend) pr_warn("i2c-core:driver[%s]usinglegacysuspendmethod\n", if(driver- pr_warn("i2c-core:driver[%s]usinglegacyresumemethod\n", pr_debug("i2c-core:driver[%s]registered\n",driver->); INIT_LIST_HEAD(&driver- /*Walktheadaptersthatarealreadypresent20voids3c_i2c1_cfg_gpio(structplatform_device*dev)21{if(soc_is_exynos5210()||S3C_GPIO_SFN(2),28}SamsungTC4I2CSystem_DriverSamsungTC4I2CS
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 历史期末专题复习提纲2024-2025学年统编版七年级历史下册
- 交通设备制造业数字化转型中的智能制造与产品生命周期管理实践报告
- 社区心理健康服务在2025年的发展现状与推广策略报告
- 智能信用体系在共享出行平台的应用与推广报告
- 国产医疗器械2025年市场竞争力:技术创新与品牌影响力分析报告
- 装备制造业2025年自主研发与产业链协同创新研究报告
- 生态修复工程2025年生物多样性保护与生态修复项目生态修复生态系统恢复路径研究报告
- 供应链金融如何优化中小企业供应链金融资源配置与风险管理报告
- 2025年养老地产市场需求变化与适老化产品设计趋势分析报告
- 2025年BIM技术在建筑项目全过程管理中的信息化管理与智能决策报告
- 【MOOC】跨文化思想交流英语-南京理工大学 中国大学慕课MOOC答案
- 中国心力衰竭诊断和治疗指南2024解读(完整版)
- 国开《当代中国政治制度》形考任务1-4参考答案
- 2024年山东省交通运输行业职业技能竞赛(装卸机械电器修理工)试题库(含答案)
- 2023-2024学年人教版小学英语四年级下册期末测试卷含答案
- 2023~2023年中石油职称英语考试真题及参考答案
- 机械连接扭矩检查记录
- 水利水电工程砖砌体单元评定表
- GB_T 24359-2021 第三方物流服务质量及测评(高清-现行)
- 院士专家工作站管理办法
- 工程造价咨询服务收费标准--鲁价费发〔2007〕205号
评论
0/150
提交评论