0% found this document useful (0 votes)
99 views2 pages

Micrcontroller Programming Using C With Keil IDE

This book is useful for the learners to know how can we use C program with KeilIDE software compiler.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
0% found this document useful (0 votes)
99 views2 pages

Micrcontroller Programming Using C With Keil IDE

This book is useful for the learners to know how can we use C program with KeilIDE software compiler.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 2

3/19/2017 MicrcontrollerProgrammingUsingCWithKeilIDE|

MicrcontrollerProgrammingUsingC March25,2011
WithKeilIDE

KEILuVisionisthenameofasoftwarededicatedtothedevelopmentandtestingofa
familyofmicrocontrollersbasedon8051technology,whichwearegoingtousealongthis
tutorial.YoucancandownloadanevaluationversionofKEILattheir
website:http://www.keil.com/c51/.Mostversionssharemerelythesameinterface,this
tutorialusesKEILC51uVision4withtheC51compiler.

Tocreateproject,writeandtestthesourcecodeandalsocreatehexfile,followthe
followingsteps:

OpenKeilandStartanewproject:

Youwillpromptedtochoseanameforyournewproject,choseanameand
clicksave.Thefollowingwindowwillappear,whereyouwillbeaskedtoselectadevicefor
TargetTarget1:

Fromthelist,selectATMELandchoseyourmicrocntroller.TheAT89s52willbecalled
yourTargetdevice,whichisthefinaldestinationofyoursourcecode.Youwillbeasked

https://vshamu.wordpress.com/2011/03/25/micrcontrollerprogrammingusingcwithkeilide/ 1/2
3/19/2017 MicrcontrollerProgrammingUsingCWithKeilIDE|

whethertocopystandard8051startupcodeclickNo.

ClickFile,Newandsimilartothefollowingwindowshouldappear.Theblankspacewhere
yourcodeshouldbewritten.

Now,YouhavetoclickFile,Saveasandchoseafilenameforcodeendingwiththe
extension.candclicksave.Thenyouhavetoaddthisfiletoyourprojectworkspaceas
showninthefollowingscreen:

Afterrightclickingonsourcegroup1,clickonAddfilestogroup,thenyouwillbe
promptedtobrowsethefiletoaddtosourcegroup1,chosethefilethatyoujustsaved
andaddittothesourcegroup.Youwillnoticethatthefileisaddedtotheprojecttreeat
theleft.

InsomeversionsofthissoftwareyouhavetoturnONmanuallytheoptiontogenerate
HEXfiles.makesureitisturnedON,byrightclickingontarget1,Optionsfortarget
target1,thenundertheoutputtab,bycheckingtheboxgenerateHEXfile.Thisstep
isveryimportantastheHEXfileisthecompiledoutputofyourprojectthatisgoingtobe
transferredtothemicrocontroller.

Youcanthenstarttowritethesourcecodeinthewindowthenbeforetestingyoursource
code,youhavetocompileyoursourcecode,andcorrecteventualsyntaxerrors.InKEIL
IDE,thisstepiscalledrebuildalltargets.

https://vshamu.wordpress.com/2011/03/25/micrcontrollerprogrammingusingcwithkeilide/ 2/2

You might also like