EasingembeddedLinuxsoftwaredevelopmentforSBCsMostprogrammerstodayleavingcollegewithElectricalEngineeringorComputerSciencedegreesarefairlywellversedinprogrammingonaLinuxdesktopplatform.
WhentheseprogrammersneedtotaketheleaptoprogrammingembeddedLinuxsystems,theyareoftensurprisedandbewilderedthattheprogramtheywroteontheirdesktopwillnotruntheirLinuxembeddedsystem.
Toalleviatethisproblem,someprogrammerschoosetouseversionsofdesktopsystemsinembeddedapplications.
Thisisgenerallynotagoodfitasdesktopsystemstypicallyhavefansandharddrives,whicharefailurepoints.
Abiggerobstacleisfastchange;theneedtohavethefastest,newesttechnologyobsoletesdesktopsystemsinaslittleassixmonths.
Designingalong-lifeembeddedproductaroundaplatformwithnolongevityisarecipefordisaster.
Evenifdesktopplatformscouldbeguaranteedtobearoundfiveyearsfromnow,theLinuxkernelandassociateddistributionsaremovingtargets.
Thekernelandstandardlibrariesareconstantlyevolving,anddistributionsarefightingtokeeppace.
Kernelpatchesandlibraryupdatescanrenderauser'sprograminoperable.
Thissituationisexacerbatedwhenengineersarerequiredtoupdatedevelopmentmachinesduetoasecurityholeorotherissue.
Awaytoabstracttheembeddeddevelopmentenvironmentfromthestandarddesktopenvironmentisneeded.
Thekeyisnotonlytofindalong-lifeembeddedLinuxhardwareplatform,butalsoalong-lifeembeddedLinuxsoftwareplatform.
AccomplishedembeddedLinuxprogrammersoftencancreateanembeddeddevelopmentplatformbygatheringthecorrectlibrariesandtoolversions,andmodifyingtheMakefileappropriately.
Evenwhensuccessful,it'sasuboptimumdevelopmentenvironment.
Ideally,compilersshouldnotrelyonthelibrariesandkernelsoftheirhost,butinsteadonthetoolchainofthemorestatictarget.
Thesoftwareplatformshouldbecompatiblewithotherplatforms,otherOperatingSystems(OSs),andotherlanguages.
TheSoftwareDevelopmentKit(SDK)shouldbebasedontoolchainswithbroadcommunitysupportsothatevenifoneoftheorganizationsdrivingtheSDKstopssupportingit,itsurvivesontheshouldersoftherest.
EnterEclipseEclipseisanopensource,redistributable,cross-platform,frameworkforcodedevelopment.
ItnativelysupportsJava,andC/C++withitsCDTplug-in.
ItprovidesmanyofthesamefunctionsthathavebeenreinventedoverandoverbythecommercialIntegratedDevelopmentEnvironments(IDEs)(syntaxhighlighting,languageawaresearches,codecompletion,andsoon)butdoesn'trelyonanyoneparticularsetoftoolstoaccomplishit(seeFigure1).
Printedfrom:http://www.
embedded-computing.
com/departments/eclipse/2006/11/ByNathanGustavsonEMAC,Inc.
andEricRossiEMAC,Inc.
Page1of5Printedfromembedded-computing.
comFigure1(clicktozoom)TheflexibilityofthissolutionledEMACandotherembeddedsoftwarecompaniestobuilddevelopmentplatformsinanEclipseenvironment.
Thiscommercialadoptionhascreateddefactostandardizationforembeddedcodedevelopers.
OEMscanwriteEclipseplug-insandprojectsthatworkwithGNUtoolchainswhileprovidingcompatibilitywithnumerouscommercialplatformsrunningbothWindowsandLinux.
EmbeddedJavaEMAC'soriginalEclipseenvironmentwasdevelopedfortheSoM-400Mmodule,usingaDS400TINIprocessorfromDallas/Maxim.
Thisprocessor'sfirmwarecontainsaproprietaryembeddedJRE.
BuildingJavacodeforthesystemiscompletedbycompilingclassesforanormalJREenvironment,replacingthecorejarswithTINIspecificjarsandthenconvertingtheresultingclassesintoTINIexecutables.
TodothisdeveloperstookadvantageofEclipse'snativeAntsupport,whichcanbeusedtocreateakindofadvancedJavaMakefileinXMLformat.
AntthenbuildstargetsbyusingEclipse'sJDTcompileradaptorclass,whichmakestheinternalcompileravailabletoAnt'stasks.
TheSourceforgeTiniAntextensionthenperformsthefinalconversionfromJavaclasstoTINIexecutable.
Allthecomplexdeclarationsrequiredtodothisarehiddeninatop-levelbuild.
propertiesfile,vastlyreducingthecomplexityofcompilationfortheSoM-400Mtosimple,standardAnttasks.
Cross-compiledCTheEclipsetoolsprojectprovidesanopen,redistributableCdevelopmentplug-incalledtheCDT.
Itprovides,amongotherthings:SyntaxhighlightingCodecompletionOn-the-flybuildsDebuggerintegration(usingGDB'sMIinterface)Itdoesnotprovidetheactualcompiler,linker,anddebuggerbinaries.
Thesearespecifictothetargetbeingbuiltforandmustbeprovidedfromanexternalsource.
TheycanthenbeintegratedintoEclipsebywritinganEclipseplug-in,or,moresimply,byusing"standard"makeprojectsandspecifyingthecompilerintheMakefile.
TheMakefileinListing1willcompileasimpleHelloWorldexampleprojectintheEMACEclipseenvironment.
Page2of5Printedfromembedded-computing.
comLiketheembeddedJavaenvironment,complexcompiler/linkerflagscommontoallprojectsarehiddeninahigher-levelfile,whichisthenincludedbyallMakefilesintheSDK.
EMACprovidescross-compilersforallitsboardsbybuildingfreelyavailableGNUcross-compilersagainstthelibrariesofthetargetdevelopmentOS.
OnLinuxtheselibrariesarenative;onWindowstheCygwinlibraryisused.
Wethen"hide"theactualEclipseexecutableandreplaceitwithabatchfilethattemporarilyaddstherequiredpathstosupporttheGNUtoolchainswhenEclipseisstarted.
DebuggingDebuggingtakesplaceusingGDBandGDBServertofacilitatearemotedebuggingenvironment.
Toaccomplishthis,thecompiledexecutableisuploadedtotheSBCandaGDBServersessionisinitiatedlisteningonaspecificportorserialterminal.
TheEclipseDebuggingperspectiveallowstheusertothendebugtheapplicationbyspecifyingtheconnectionparameterstouseaswellastheversionofGDBbuiltforthetargetarchitecture.
TheDebuggingperspectivedisplaysthesourcecodeoftheprogramtobedebuggedandthegeneratedassemblycode.
Itiseasytomanageandmonitorbreakpointsandvariables,aswellassingle-stepthroughtheprogramlinebyline.
Thecurrentpositioninthesourcecodeisautomaticallyhighlighted.
Eclipseprovidesagraphicaldebuggingenvironmentthatgreatlysimplifiestheprocessofremotetargetdebugging.
TargetcommunicationWhendevelopingforanembeddedenvironment,itwillbenecessarytoestablishaconnectionwiththetargetboard,eitherbyaserialterminalprogramorthroughTCPusingaTelnet,SSH,orothersimilarconnection.
Whenthisisdonethroughthecommandlineinterfaceoragraphicalfrontend,theprogrammerisforcedtoconstantlyswitchbetweenwindowstomonitortheconnectionandtheIDEsimultaneously.
EMACeliminatesthisproblembyintegratingEclipseplug-insthatallowforSSH,Telnet,andTerminalconnectionsallwithinEclipse.
ThisallowstheprogrammertomonitortheembeddedtargetboardasifitwerealocalfilesystemandissuecommandsdirectlywithouthavingtoleavetheEclipseenvironment.
CVSEclipseprovidesapowerfulCVSnatively.
BysettingupaCVSloginandprovidingpasswordstocustomers,developerscaninsuretheyalwayshaveaccesstothemostrecentversionsofcodeandbugfixesforproducts.
SDKBASE=.
.
/.
.
/CROSS=$(SDKBASE)gcc-4.
0.
0-i486-D/bin/i486-linux-CC=$(CROSS)gccLIBFLAGS=-lc#VERBOSE=-vCFLAGS=-gOFLAGS=-WlTARGET=helloCFILES=hello.
call:$(TARGET)$(TARGET):objects$(CC)$(VERBOSE)*.
o$(OFLAGS)$(SLIBS)-o$(TARGET)$(LIBFLAGS)objects:$(CFILES)$(CC)$(VERBOSE)$(CFLAGS)-c$(CFILES)clean:$(RM)*.
o*.
gdb$(TARGET)TARGET_IP=192.
168.
0.
1LOGIN=someuserPASSWORD=somepasswordupload:wput$(TARGET)ftp://$(LOGIN):$(PASSWORD)@$(TARGET_IP)/.
.
/.
.
/tmp/$(TARGET)"Withalittleintegration,anOEMcancreatearobust,cross-platformdevelopmentplatformfortheirboardsthatwillrunonthesameplatformadoptedbymanycommercialsoftwarevendors.
"Page3of5Printedfromembedded-computing.
comUploadingsoftwarepatchesandentirelynewcomponentsforSDKsontoaCVSserverprovidesup-to-the-minutesoftwaresupporttocustomers,whocangraphicallyviewdifferencesinfilesandpatchtheirownSDKwithsome,all,ornoneofwhathasbeenuploaded.
DocumentationEclipseprovidesitsownnativebrowser,whichisbeneficialforcreatingHTMLlinkeddocumentationrightintheworkspace.
Inthisway,customerscanbrowsethroughHTMLdocumentation(similartothatgeneratedbyDoxygenandJavadoc).
Context-sensitivehelpisalsointegratedinEclipse(seeFigure2),allowingnewuserstobemoreproductive.
Figure2(clicktozoom)Thisdocumentationcanlinkrightbacktothesoftwaredeveloper'swebsiteaswell,allowinguserdocumentationtobeaddeddynamically.
Userscanswitchrightfromcodetodocumentationwithatab,ratherthannavigatingseveralwindowsatonce.
Integratedtools,betterdevelopmentEclipseprovidesanenvironmentwhereGNUtoolsandcommercialtoolscanplaytogether.
Withalittleintegration,anOEMcancreatearobust,cross-platformdevelopmentplatformfortheirboardsthatwillrunonthesameplatformadoptedbymanycommercialsoftwarevendors.
WithintheEclipseframework,EMACusescross-compilationtoalleviatetheproblemofabstractingtheembeddeddevelopmentenvironmentfromthestandarddesktopenvironment.
DebuggingisaccomplishedusingGDBwithEclipsewindowsforthedebugger'sinputandoutput.
CommunicationwiththetargetisalsointegratedintoEclipsethroughTelnet,FTP,Terminal,andSSHplug-ins.
CVSversioncontrolandHTMLdocumentationarebothaccomplishedwithintheEclipseenvironmentaswell.
AlloftheaforementioneddevelopmentcapabilitiesrolledupintoastandardIDEmakeforapowerful,efficientdevelopmentplatformthatcanbeusedwithasmall8-bitJava-basedcontrolleranda32-bitLinuxserverprogrammedinC.
ThisisthepowerofEclipse.
NathanZ.
GustavsonisaseniorsystemsengineeratEMAC,Inc.
specializinginLinuxandreal-timecontrol.
HeholdsaBSinElectricalEngineeringandiscurrentlypursingaMSatSouthernIllinoisUniversity.
EricRossiisaseniormanageratEMAC,Inc.
whereheisresponsiblefornewproductdevelopmentandcustomengineeringmanagement.
Erichasmorethan25yearsofexperienceinembeddedsystemdesignandholdsaBSinElectricalEngineeringTechnologyaswellasaBSandMSinComputerScience.
Tolearnmore,contactNathanorEricat:EMAC,Inc.
2390EMACWayCarbondale,IL62902Page4of5Printedfromembedded-computing.
com618-529-4525Nathan:ngustavson@emacinc.
comEric:erossi@emacinc.
comwww.
emacinc.
comMMVIIEmbeddedComputingDesign.
AnOpenSystemsPublishing,LLCpublication.
Page5of5Printedfromembedded-computing.
com
从介绍看啊,新增的HostYun 俄罗斯机房采用的是双向CN2线路,其他的像香港和日本机房,均为国内直连线路,访问质量不错。HostYun商家通用九折优惠码:HostYun内存CPUSSD流量带宽价格(原价)购买地址1G1核10G300G/月200M28元/月购买链接1G1核10G500G/月200M38元/月购买链接1G1核20G900G/月200M68元/月购买链接2G1核30G1500G/月...
日本vps云服务器怎么选择?很多人都会遇到日本vps和日本云服务器怎么选择的问题,日本云服务器具有免备案的特点。小编今天就分析一下日本云服务器价格多少钱,以方便大家选购的时候有个更加合适的取舍。日本云服务器租用前比较选择,高性能、安全、高效、免备案日本云服务器是很关键的因素。那么,日本云服务器该怎么选择呢?日本作为我们的邻国,与其贸易、文化往来是比较多的。日本云服务器价格多少钱一年?一、日本·CN...
华为云怎么样?华为云用在线的方式将华为30多年在ICT基础设施领域的技术积累和产品解决方案开放给客户,致力于提供稳定可靠、安全可信、可持续创新的云服务,做智能世界的“黑土地”,推进实现“用得起、用得好、用得放心”的普惠AI。华为云作为底座,为华为全栈全场景AI战略提供强大的算力平台和更易用的开发平台。本次年终聚惠618活动相当给力,1核2G内存1m云耀云服务器仅88元/年起,送主机安全基础版套餐,...
ww.38jjj.com为你推荐
摩拜超15分钟加钱摩拜单车不是按骑行时间收费吗,我怎么只要开锁就要支付一元(而且只骑十几分钟)对对塔为什么不能玩天天擂台?(对对塔)安徽汽车网在安徽那个市的二手车最好?梦之队官网梦之队是哪个国家的?18comic.fun黑色禁药http://www.lovecomic.cn/attachment/Fid_18/18_4_00d3b0cb502ea74.jpg这幅画名字叫什么?seo优化工具SEO优化工具哪个好用点啊?haole018.com为什么www.haole008.com在我这里打不开啊,是不是haole008换新的地址了?336.com求一个游戏的网站 你懂得www.sesehu.comwww.121gao.com 是谁的网站啊bbs2.99nets.com西安论坛、西安茶馆网、西安社区、西安bbs 的网址是多少?
域名大全 中文国际域名 网站域名备案 免费主机 paypal认证 美国主机代购 bash漏洞 申请空间 发包服务器 国外在线代理 天互数据 seednet 国外代理服务器软件 cdn加速是什么 hktv 华为云服务登录 网购分享 ebay注册 web应用服务器 中国电信测速网站 更多