hpl_xdmac_config.h 117 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400
  1. /* Auto-generated config file hpl_xdmac_config.h */
  2. #ifndef HPL_XDMAC_CONFIG_H
  3. #define HPL_XDMAC_CONFIG_H
  4. // <<< Use Configuration Wizard in Context Menu >>>
  5. // <e> XDMAC enable
  6. // <i> Indicates whether xdmac is enabled or not
  7. // <id> xdmac_enable
  8. #ifndef CONF_DMA_ENABLE
  9. #define CONF_DMA_ENABLE 0
  10. #endif
  11. // <e> Channel 0 settings
  12. // <id> dmac_channel_0_settings
  13. #ifndef CONF_DMAC_CHANNEL_0_SETTINGS
  14. #define CONF_DMAC_CHANNEL_0_SETTINGS 0
  15. #endif
  16. // <o> Burst Size
  17. // <0x0=> 1 burst size
  18. // <0x1=> 4 burst size
  19. // <0x2=> 8 burst size
  20. // <0x3=> 16 burst size
  21. // <i> Define the memory burst size
  22. // <id> dmac_burstsize_0
  23. #ifndef CONF_DMAC_BURSTSIZE_0
  24. #define CONF_DMAC_BURSTSIZE_0 0x0
  25. #endif
  26. // <o> Chunk Size
  27. // <0x0=> 1 data transferred
  28. // <0x1=> 2 data transferred
  29. // <0x2=> 4 data transferred
  30. // <0x3=> 8 data transferred
  31. // <0x4=> 16 data transferred
  32. // <i> Define the peripheral chunk size
  33. // <id> dmac_chunksize_0
  34. #ifndef CONF_DMAC_CHUNKSIZE_0
  35. #define CONF_DMAC_CHUNKSIZE_0 0x0
  36. #endif
  37. // <o> Beat Size
  38. // <0=> 8-bit bus transfer
  39. // <1=> 16-bit bus transfer
  40. // <2=> 32-bit bus transfer
  41. // <i> Defines the size of one beat
  42. // <id> dmac_beatsize_0
  43. #ifndef CONF_DMAC_BEATSIZE_0
  44. #define CONF_DMAC_BEATSIZE_0 0x0
  45. #endif
  46. // <o> Source Interface Identifier
  47. // <0x0=> AHB_IF0
  48. // <0x1=> AHB_IF1
  49. // <i> Define the data is read through the system bus interface 0 or 1
  50. // <id> dma_src_interface_0
  51. #ifndef CONF_DMAC_SRC_INTERFACE_0
  52. #define CONF_DMAC_SRC_INTERFACE_0 0x0
  53. #endif
  54. // <o> Destination Interface Identifier
  55. // <0x0=> AHB_IF0
  56. // <0x1=> AHB_IF1
  57. // <i> Define the data is written through the system bus interface 0 or 1
  58. // <id> dma_des_interface_0
  59. #ifndef CONF_DMAC_DES_INTERFACE_0
  60. #define CONF_DMAC_DES_INTERFACE_0 0x0
  61. #endif
  62. // <q> Source Address Increment
  63. // <i> Indicates whether the source address incremented as beat size or not
  64. // <id> dmac_srcinc_0
  65. #ifndef CONF_DMAC_SRCINC_0
  66. #define CONF_DMAC_SRCINC_0 0
  67. #endif
  68. // <q> Destination Address Increment
  69. // <i> Indicates whether the destination address incremented as beat size or not
  70. // <id> dmac_dstinc_0
  71. #ifndef CONF_DMAC_DSTINC_0
  72. #define CONF_DMAC_DSTINC_0 0
  73. #endif
  74. // <o> Transfer Type
  75. // <0x0=> Memory to Memory Transfer
  76. // <0x1=> Peripheral to Memory Transfer
  77. // <0x2=> Memory to Peripheral Transfer
  78. // <i> Define the data transfer type
  79. // <id> dma_trans_type_0
  80. #ifndef CONF_DMAC_TRANS_TYPE_0
  81. #define CONF_DMAC_TRANS_TYPE_0 0x0
  82. #endif
  83. // <o> Trigger source
  84. // <0xFF=> Software Trigger
  85. // <0x00=> HSMCI TX/RX Trigger
  86. // <0x01=> SPI0 TX Trigger
  87. // <0x02=> SPI0 RX Trigger
  88. // <0x03=> SPI1 TX Trigger
  89. // <0x04=> SPI1 RX Trigger
  90. // <0x05=> QSPI TX Trigger
  91. // <0x06=> QSPI RX Trigger
  92. // <0x07=> USART0 TX Trigger
  93. // <0x08=> USART0 RX Trigger
  94. // <0x09=> USART1 TX Trigger
  95. // <0x0A=> USART1 RX Trigger
  96. // <0x0B=> USART2 TX Trigger
  97. // <0x0C=> USART2 RX Trigger
  98. // <0x0D=> PWM0 TX Trigger
  99. // <0x0E=> TWIHS0 TX Trigger
  100. // <0x0F=> TWIHS0 RX Trigger
  101. // <0x10=> TWIHS1 TX Trigger
  102. // <0x11=> TWIHS1 RX Trigger
  103. // <0x12=> TWIHS2 TX Trigger
  104. // <0x13=> TWIHS2 RX Trigger
  105. // <0x14=> UART0 TX Trigger
  106. // <0x15=> UART0 RX Trigger
  107. // <0x16=> UART1 TX Trigger
  108. // <0x17=> UART1 RX Trigger
  109. // <0x18=> UART2 TX Trigger
  110. // <0x19=> UART2 RX Trigger
  111. // <0x1A=> UART3 TX Trigger
  112. // <0x1B=> UART3 RX Trigger
  113. // <0x1C=> UART4 TX Trigger
  114. // <0x1D=> UART4 RX Trigger
  115. // <0x1E=> DACC TX Trigger
  116. // <0x20=> SSC TX Trigger
  117. // <0x21=> SSC RX Trigger
  118. // <0x22=> PIOA RX Trigger
  119. // <0x23=> AFEC0 RX Trigger
  120. // <0x24=> AFEC1 RX Trigger
  121. // <0x25=> AES TX Trigger
  122. // <0x26=> AES RX Trigger
  123. // <0x27=> PWM1 TX Trigger
  124. // <0x28=> TC0 RX Trigger
  125. // <0x29=> TC3 RX Trigger
  126. // <0x2A=> TC6 RX Trigger
  127. // <0x2B=> TC9 RX Trigger
  128. // <0x2C=> I2SC0 TX Left Trigger
  129. // <0x2D=> I2SC0 RX Left Trigger
  130. // <0x2E=> I2SC1 TX Left Trigger
  131. // <0x2F=> I2SC1 RX Left Trigger
  132. // <0x30=> I2SC0 TX Right Trigger
  133. // <0x31=> I2SC0 RX Right Trigger
  134. // <0x32=> I2SC1 TX Right Trigger
  135. // <0x33=> I2SC1 RX Right Trigger
  136. // <i> Define the DMA trigger source
  137. // <id> dmac_trifsrc_0
  138. #ifndef CONF_DMAC_TRIGSRC_0
  139. #define CONF_DMAC_TRIGSRC_0 0xff
  140. #endif
  141. // </e>
  142. #if CONF_DMAC_TRANS_TYPE_0 == 0
  143. #define CONF_DMAC_TYPE_0 0
  144. #define CONF_DMAC_DSYNC_0 0
  145. #elif CONF_DMAC_TRANS_TYPE_0 == 1
  146. #define CONF_DMAC_TYPE_0 1
  147. #define CONF_DMAC_DSYNC_0 0
  148. #elif CONF_DMAC_TRANS_TYPE_0 == 2
  149. #define CONF_DMAC_TYPE_0 1
  150. #define CONF_DMAC_DSYNC_0 1
  151. #endif
  152. #if CONF_DMAC_TRIGSRC_0 == 0xFF
  153. #define CONF_DMAC_SWREQ_0 1
  154. #else
  155. #define CONF_DMAC_SWREQ_0 0
  156. #endif
  157. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  158. * or fixed destination address mode, source and destination addresses are incremented
  159. * by 8-bit or 16-bit.
  160. * Workaround: The user can fix the problem by setting the source addressing mode to
  161. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  162. */
  163. #if (CONF_DMAC_CHANNEL_0_SETTINGS == 1 && CONF_DMAC_BEATSIZE_0 != 2 && ((!CONF_DMAC_SRCINC_0) || (!CONF_DMAC_DSTINC_0)))
  164. #if (!CONF_DMAC_SRCINC_0)
  165. #define CONF_DMAC_SRC_STRIDE_0 ((int16_t)(-1))
  166. #endif
  167. #if (!CONF_DMAC_DSTINC_0)
  168. #define CONF_DMAC_DES_STRIDE_0 ((int16_t)(-1))
  169. #endif
  170. #endif
  171. #ifndef CONF_DMAC_SRC_STRIDE_0
  172. #define CONF_DMAC_SRC_STRIDE_0 0
  173. #endif
  174. #ifndef CONF_DMAC_DES_STRIDE_0
  175. #define CONF_DMAC_DES_STRIDE_0 0
  176. #endif
  177. // <e> Channel 1 settings
  178. // <id> dmac_channel_1_settings
  179. #ifndef CONF_DMAC_CHANNEL_1_SETTINGS
  180. #define CONF_DMAC_CHANNEL_1_SETTINGS 0
  181. #endif
  182. // <o> Burst Size
  183. // <0x0=> 1 burst size
  184. // <0x1=> 4 burst size
  185. // <0x2=> 8 burst size
  186. // <0x3=> 16 burst size
  187. // <i> Define the memory burst size
  188. // <id> dmac_burstsize_1
  189. #ifndef CONF_DMAC_BURSTSIZE_1
  190. #define CONF_DMAC_BURSTSIZE_1 0x0
  191. #endif
  192. // <o> Chunk Size
  193. // <0x0=> 1 data transferred
  194. // <0x1=> 2 data transferred
  195. // <0x2=> 4 data transferred
  196. // <0x3=> 8 data transferred
  197. // <0x4=> 16 data transferred
  198. // <i> Define the peripheral chunk size
  199. // <id> dmac_chunksize_1
  200. #ifndef CONF_DMAC_CHUNKSIZE_1
  201. #define CONF_DMAC_CHUNKSIZE_1 0x0
  202. #endif
  203. // <o> Beat Size
  204. // <0=> 8-bit bus transfer
  205. // <1=> 16-bit bus transfer
  206. // <2=> 32-bit bus transfer
  207. // <i> Defines the size of one beat
  208. // <id> dmac_beatsize_1
  209. #ifndef CONF_DMAC_BEATSIZE_1
  210. #define CONF_DMAC_BEATSIZE_1 0x0
  211. #endif
  212. // <o> Source Interface Identifier
  213. // <0x0=> AHB_IF0
  214. // <0x1=> AHB_IF1
  215. // <i> Define the data is read through the system bus interface 0 or 1
  216. // <id> dma_src_interface_1
  217. #ifndef CONF_DMAC_SRC_INTERFACE_1
  218. #define CONF_DMAC_SRC_INTERFACE_1 0x0
  219. #endif
  220. // <o> Destination Interface Identifier
  221. // <0x0=> AHB_IF0
  222. // <0x1=> AHB_IF1
  223. // <i> Define the data is written through the system bus interface 0 or 1
  224. // <id> dma_des_interface_1
  225. #ifndef CONF_DMAC_DES_INTERFACE_1
  226. #define CONF_DMAC_DES_INTERFACE_1 0x0
  227. #endif
  228. // <q> Source Address Increment
  229. // <i> Indicates whether the source address incremented as beat size or not
  230. // <id> dmac_srcinc_1
  231. #ifndef CONF_DMAC_SRCINC_1
  232. #define CONF_DMAC_SRCINC_1 0
  233. #endif
  234. // <q> Destination Address Increment
  235. // <i> Indicates whether the destination address incremented as beat size or not
  236. // <id> dmac_dstinc_1
  237. #ifndef CONF_DMAC_DSTINC_1
  238. #define CONF_DMAC_DSTINC_1 0
  239. #endif
  240. // <o> Transfer Type
  241. // <0x0=> Memory to Memory Transfer
  242. // <0x1=> Peripheral to Memory Transfer
  243. // <0x2=> Memory to Peripheral Transfer
  244. // <i> Define the data transfer type
  245. // <id> dma_trans_type_1
  246. #ifndef CONF_DMAC_TRANS_TYPE_1
  247. #define CONF_DMAC_TRANS_TYPE_1 0x0
  248. #endif
  249. // <o> Trigger source
  250. // <0xFF=> Software Trigger
  251. // <0x00=> HSMCI TX/RX Trigger
  252. // <0x01=> SPI0 TX Trigger
  253. // <0x02=> SPI0 RX Trigger
  254. // <0x03=> SPI1 TX Trigger
  255. // <0x04=> SPI1 RX Trigger
  256. // <0x05=> QSPI TX Trigger
  257. // <0x06=> QSPI RX Trigger
  258. // <0x07=> USART0 TX Trigger
  259. // <0x08=> USART0 RX Trigger
  260. // <0x09=> USART1 TX Trigger
  261. // <0x0A=> USART1 RX Trigger
  262. // <0x0B=> USART2 TX Trigger
  263. // <0x0C=> USART2 RX Trigger
  264. // <0x0D=> PWM0 TX Trigger
  265. // <0x0E=> TWIHS0 TX Trigger
  266. // <0x0F=> TWIHS0 RX Trigger
  267. // <0x10=> TWIHS1 TX Trigger
  268. // <0x11=> TWIHS1 RX Trigger
  269. // <0x12=> TWIHS2 TX Trigger
  270. // <0x13=> TWIHS2 RX Trigger
  271. // <0x14=> UART0 TX Trigger
  272. // <0x15=> UART0 RX Trigger
  273. // <0x16=> UART1 TX Trigger
  274. // <0x17=> UART1 RX Trigger
  275. // <0x18=> UART2 TX Trigger
  276. // <0x19=> UART2 RX Trigger
  277. // <0x1A=> UART3 TX Trigger
  278. // <0x1B=> UART3 RX Trigger
  279. // <0x1C=> UART4 TX Trigger
  280. // <0x1D=> UART4 RX Trigger
  281. // <0x1E=> DACC TX Trigger
  282. // <0x20=> SSC TX Trigger
  283. // <0x21=> SSC RX Trigger
  284. // <0x22=> PIOA RX Trigger
  285. // <0x23=> AFEC0 RX Trigger
  286. // <0x24=> AFEC1 RX Trigger
  287. // <0x25=> AES TX Trigger
  288. // <0x26=> AES RX Trigger
  289. // <0x27=> PWM1 TX Trigger
  290. // <0x28=> TC0 RX Trigger
  291. // <0x29=> TC3 RX Trigger
  292. // <0x2A=> TC6 RX Trigger
  293. // <0x2B=> TC9 RX Trigger
  294. // <0x2C=> I2SC0 TX Left Trigger
  295. // <0x2D=> I2SC0 RX Left Trigger
  296. // <0x2E=> I2SC1 TX Left Trigger
  297. // <0x2F=> I2SC1 RX Left Trigger
  298. // <0x30=> I2SC0 TX Right Trigger
  299. // <0x31=> I2SC0 RX Right Trigger
  300. // <0x32=> I2SC1 TX Right Trigger
  301. // <0x33=> I2SC1 RX Right Trigger
  302. // <i> Define the DMA trigger source
  303. // <id> dmac_trifsrc_1
  304. #ifndef CONF_DMAC_TRIGSRC_1
  305. #define CONF_DMAC_TRIGSRC_1 0xff
  306. #endif
  307. // </e>
  308. #if CONF_DMAC_TRANS_TYPE_1 == 0
  309. #define CONF_DMAC_TYPE_1 0
  310. #define CONF_DMAC_DSYNC_1 0
  311. #elif CONF_DMAC_TRANS_TYPE_1 == 1
  312. #define CONF_DMAC_TYPE_1 1
  313. #define CONF_DMAC_DSYNC_1 0
  314. #elif CONF_DMAC_TRANS_TYPE_1 == 2
  315. #define CONF_DMAC_TYPE_1 1
  316. #define CONF_DMAC_DSYNC_1 1
  317. #endif
  318. #if CONF_DMAC_TRIGSRC_1 == 0xFF
  319. #define CONF_DMAC_SWREQ_1 1
  320. #else
  321. #define CONF_DMAC_SWREQ_1 0
  322. #endif
  323. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  324. * or fixed destination address mode, source and destination addresses are incremented
  325. * by 8-bit or 16-bit.
  326. * Workaround: The user can fix the problem by setting the source addressing mode to
  327. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  328. */
  329. #if (CONF_DMAC_CHANNEL_1_SETTINGS == 1 && CONF_DMAC_BEATSIZE_1 != 2 && ((!CONF_DMAC_SRCINC_1) || (!CONF_DMAC_DSTINC_1)))
  330. #if (!CONF_DMAC_SRCINC_1)
  331. #define CONF_DMAC_SRC_STRIDE_1 ((int16_t)(-1))
  332. #endif
  333. #if (!CONF_DMAC_DSTINC_1)
  334. #define CONF_DMAC_DES_STRIDE_1 ((int16_t)(-1))
  335. #endif
  336. #endif
  337. #ifndef CONF_DMAC_SRC_STRIDE_1
  338. #define CONF_DMAC_SRC_STRIDE_1 0
  339. #endif
  340. #ifndef CONF_DMAC_DES_STRIDE_1
  341. #define CONF_DMAC_DES_STRIDE_1 0
  342. #endif
  343. // <e> Channel 2 settings
  344. // <id> dmac_channel_2_settings
  345. #ifndef CONF_DMAC_CHANNEL_2_SETTINGS
  346. #define CONF_DMAC_CHANNEL_2_SETTINGS 0
  347. #endif
  348. // <o> Burst Size
  349. // <0x0=> 1 burst size
  350. // <0x1=> 4 burst size
  351. // <0x2=> 8 burst size
  352. // <0x3=> 16 burst size
  353. // <i> Define the memory burst size
  354. // <id> dmac_burstsize_2
  355. #ifndef CONF_DMAC_BURSTSIZE_2
  356. #define CONF_DMAC_BURSTSIZE_2 0x0
  357. #endif
  358. // <o> Chunk Size
  359. // <0x0=> 1 data transferred
  360. // <0x1=> 2 data transferred
  361. // <0x2=> 4 data transferred
  362. // <0x3=> 8 data transferred
  363. // <0x4=> 16 data transferred
  364. // <i> Define the peripheral chunk size
  365. // <id> dmac_chunksize_2
  366. #ifndef CONF_DMAC_CHUNKSIZE_2
  367. #define CONF_DMAC_CHUNKSIZE_2 0x0
  368. #endif
  369. // <o> Beat Size
  370. // <0=> 8-bit bus transfer
  371. // <1=> 16-bit bus transfer
  372. // <2=> 32-bit bus transfer
  373. // <i> Defines the size of one beat
  374. // <id> dmac_beatsize_2
  375. #ifndef CONF_DMAC_BEATSIZE_2
  376. #define CONF_DMAC_BEATSIZE_2 0x0
  377. #endif
  378. // <o> Source Interface Identifier
  379. // <0x0=> AHB_IF0
  380. // <0x1=> AHB_IF1
  381. // <i> Define the data is read through the system bus interface 0 or 1
  382. // <id> dma_src_interface_2
  383. #ifndef CONF_DMAC_SRC_INTERFACE_2
  384. #define CONF_DMAC_SRC_INTERFACE_2 0x0
  385. #endif
  386. // <o> Destination Interface Identifier
  387. // <0x0=> AHB_IF0
  388. // <0x1=> AHB_IF1
  389. // <i> Define the data is written through the system bus interface 0 or 1
  390. // <id> dma_des_interface_2
  391. #ifndef CONF_DMAC_DES_INTERFACE_2
  392. #define CONF_DMAC_DES_INTERFACE_2 0x0
  393. #endif
  394. // <q> Source Address Increment
  395. // <i> Indicates whether the source address incremented as beat size or not
  396. // <id> dmac_srcinc_2
  397. #ifndef CONF_DMAC_SRCINC_2
  398. #define CONF_DMAC_SRCINC_2 0
  399. #endif
  400. // <q> Destination Address Increment
  401. // <i> Indicates whether the destination address incremented as beat size or not
  402. // <id> dmac_dstinc_2
  403. #ifndef CONF_DMAC_DSTINC_2
  404. #define CONF_DMAC_DSTINC_2 0
  405. #endif
  406. // <o> Transfer Type
  407. // <0x0=> Memory to Memory Transfer
  408. // <0x1=> Peripheral to Memory Transfer
  409. // <0x2=> Memory to Peripheral Transfer
  410. // <i> Define the data transfer type
  411. // <id> dma_trans_type_2
  412. #ifndef CONF_DMAC_TRANS_TYPE_2
  413. #define CONF_DMAC_TRANS_TYPE_2 0x0
  414. #endif
  415. // <o> Trigger source
  416. // <0xFF=> Software Trigger
  417. // <0x00=> HSMCI TX/RX Trigger
  418. // <0x01=> SPI0 TX Trigger
  419. // <0x02=> SPI0 RX Trigger
  420. // <0x03=> SPI1 TX Trigger
  421. // <0x04=> SPI1 RX Trigger
  422. // <0x05=> QSPI TX Trigger
  423. // <0x06=> QSPI RX Trigger
  424. // <0x07=> USART0 TX Trigger
  425. // <0x08=> USART0 RX Trigger
  426. // <0x09=> USART1 TX Trigger
  427. // <0x0A=> USART1 RX Trigger
  428. // <0x0B=> USART2 TX Trigger
  429. // <0x0C=> USART2 RX Trigger
  430. // <0x0D=> PWM0 TX Trigger
  431. // <0x0E=> TWIHS0 TX Trigger
  432. // <0x0F=> TWIHS0 RX Trigger
  433. // <0x10=> TWIHS1 TX Trigger
  434. // <0x11=> TWIHS1 RX Trigger
  435. // <0x12=> TWIHS2 TX Trigger
  436. // <0x13=> TWIHS2 RX Trigger
  437. // <0x14=> UART0 TX Trigger
  438. // <0x15=> UART0 RX Trigger
  439. // <0x16=> UART1 TX Trigger
  440. // <0x17=> UART1 RX Trigger
  441. // <0x18=> UART2 TX Trigger
  442. // <0x19=> UART2 RX Trigger
  443. // <0x1A=> UART3 TX Trigger
  444. // <0x1B=> UART3 RX Trigger
  445. // <0x1C=> UART4 TX Trigger
  446. // <0x1D=> UART4 RX Trigger
  447. // <0x1E=> DACC TX Trigger
  448. // <0x20=> SSC TX Trigger
  449. // <0x21=> SSC RX Trigger
  450. // <0x22=> PIOA RX Trigger
  451. // <0x23=> AFEC0 RX Trigger
  452. // <0x24=> AFEC1 RX Trigger
  453. // <0x25=> AES TX Trigger
  454. // <0x26=> AES RX Trigger
  455. // <0x27=> PWM1 TX Trigger
  456. // <0x28=> TC0 RX Trigger
  457. // <0x29=> TC3 RX Trigger
  458. // <0x2A=> TC6 RX Trigger
  459. // <0x2B=> TC9 RX Trigger
  460. // <0x2C=> I2SC0 TX Left Trigger
  461. // <0x2D=> I2SC0 RX Left Trigger
  462. // <0x2E=> I2SC1 TX Left Trigger
  463. // <0x2F=> I2SC1 RX Left Trigger
  464. // <0x30=> I2SC0 TX Right Trigger
  465. // <0x31=> I2SC0 RX Right Trigger
  466. // <0x32=> I2SC1 TX Right Trigger
  467. // <0x33=> I2SC1 RX Right Trigger
  468. // <i> Define the DMA trigger source
  469. // <id> dmac_trifsrc_2
  470. #ifndef CONF_DMAC_TRIGSRC_2
  471. #define CONF_DMAC_TRIGSRC_2 0xff
  472. #endif
  473. // </e>
  474. #if CONF_DMAC_TRANS_TYPE_2 == 0
  475. #define CONF_DMAC_TYPE_2 0
  476. #define CONF_DMAC_DSYNC_2 0
  477. #elif CONF_DMAC_TRANS_TYPE_2 == 1
  478. #define CONF_DMAC_TYPE_2 1
  479. #define CONF_DMAC_DSYNC_2 0
  480. #elif CONF_DMAC_TRANS_TYPE_2 == 2
  481. #define CONF_DMAC_TYPE_2 1
  482. #define CONF_DMAC_DSYNC_2 1
  483. #endif
  484. #if CONF_DMAC_TRIGSRC_2 == 0xFF
  485. #define CONF_DMAC_SWREQ_2 1
  486. #else
  487. #define CONF_DMAC_SWREQ_2 0
  488. #endif
  489. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  490. * or fixed destination address mode, source and destination addresses are incremented
  491. * by 8-bit or 16-bit.
  492. * Workaround: The user can fix the problem by setting the source addressing mode to
  493. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  494. */
  495. #if (CONF_DMAC_CHANNEL_2_SETTINGS == 1 && CONF_DMAC_BEATSIZE_2 != 2 && ((!CONF_DMAC_SRCINC_2) || (!CONF_DMAC_DSTINC_2)))
  496. #if (!CONF_DMAC_SRCINC_2)
  497. #define CONF_DMAC_SRC_STRIDE_2 ((int16_t)(-1))
  498. #endif
  499. #if (!CONF_DMAC_DSTINC_2)
  500. #define CONF_DMAC_DES_STRIDE_2 ((int16_t)(-1))
  501. #endif
  502. #endif
  503. #ifndef CONF_DMAC_SRC_STRIDE_2
  504. #define CONF_DMAC_SRC_STRIDE_2 0
  505. #endif
  506. #ifndef CONF_DMAC_DES_STRIDE_2
  507. #define CONF_DMAC_DES_STRIDE_2 0
  508. #endif
  509. // <e> Channel 3 settings
  510. // <id> dmac_channel_3_settings
  511. #ifndef CONF_DMAC_CHANNEL_3_SETTINGS
  512. #define CONF_DMAC_CHANNEL_3_SETTINGS 0
  513. #endif
  514. // <o> Burst Size
  515. // <0x0=> 1 burst size
  516. // <0x1=> 4 burst size
  517. // <0x2=> 8 burst size
  518. // <0x3=> 16 burst size
  519. // <i> Define the memory burst size
  520. // <id> dmac_burstsize_3
  521. #ifndef CONF_DMAC_BURSTSIZE_3
  522. #define CONF_DMAC_BURSTSIZE_3 0x0
  523. #endif
  524. // <o> Chunk Size
  525. // <0x0=> 1 data transferred
  526. // <0x1=> 2 data transferred
  527. // <0x2=> 4 data transferred
  528. // <0x3=> 8 data transferred
  529. // <0x4=> 16 data transferred
  530. // <i> Define the peripheral chunk size
  531. // <id> dmac_chunksize_3
  532. #ifndef CONF_DMAC_CHUNKSIZE_3
  533. #define CONF_DMAC_CHUNKSIZE_3 0x0
  534. #endif
  535. // <o> Beat Size
  536. // <0=> 8-bit bus transfer
  537. // <1=> 16-bit bus transfer
  538. // <2=> 32-bit bus transfer
  539. // <i> Defines the size of one beat
  540. // <id> dmac_beatsize_3
  541. #ifndef CONF_DMAC_BEATSIZE_3
  542. #define CONF_DMAC_BEATSIZE_3 0x0
  543. #endif
  544. // <o> Source Interface Identifier
  545. // <0x0=> AHB_IF0
  546. // <0x1=> AHB_IF1
  547. // <i> Define the data is read through the system bus interface 0 or 1
  548. // <id> dma_src_interface_3
  549. #ifndef CONF_DMAC_SRC_INTERFACE_3
  550. #define CONF_DMAC_SRC_INTERFACE_3 0x0
  551. #endif
  552. // <o> Destination Interface Identifier
  553. // <0x0=> AHB_IF0
  554. // <0x1=> AHB_IF1
  555. // <i> Define the data is written through the system bus interface 0 or 1
  556. // <id> dma_des_interface_3
  557. #ifndef CONF_DMAC_DES_INTERFACE_3
  558. #define CONF_DMAC_DES_INTERFACE_3 0x0
  559. #endif
  560. // <q> Source Address Increment
  561. // <i> Indicates whether the source address incremented as beat size or not
  562. // <id> dmac_srcinc_3
  563. #ifndef CONF_DMAC_SRCINC_3
  564. #define CONF_DMAC_SRCINC_3 0
  565. #endif
  566. // <q> Destination Address Increment
  567. // <i> Indicates whether the destination address incremented as beat size or not
  568. // <id> dmac_dstinc_3
  569. #ifndef CONF_DMAC_DSTINC_3
  570. #define CONF_DMAC_DSTINC_3 0
  571. #endif
  572. // <o> Transfer Type
  573. // <0x0=> Memory to Memory Transfer
  574. // <0x1=> Peripheral to Memory Transfer
  575. // <0x2=> Memory to Peripheral Transfer
  576. // <i> Define the data transfer type
  577. // <id> dma_trans_type_3
  578. #ifndef CONF_DMAC_TRANS_TYPE_3
  579. #define CONF_DMAC_TRANS_TYPE_3 0x0
  580. #endif
  581. // <o> Trigger source
  582. // <0xFF=> Software Trigger
  583. // <0x00=> HSMCI TX/RX Trigger
  584. // <0x01=> SPI0 TX Trigger
  585. // <0x02=> SPI0 RX Trigger
  586. // <0x03=> SPI1 TX Trigger
  587. // <0x04=> SPI1 RX Trigger
  588. // <0x05=> QSPI TX Trigger
  589. // <0x06=> QSPI RX Trigger
  590. // <0x07=> USART0 TX Trigger
  591. // <0x08=> USART0 RX Trigger
  592. // <0x09=> USART1 TX Trigger
  593. // <0x0A=> USART1 RX Trigger
  594. // <0x0B=> USART2 TX Trigger
  595. // <0x0C=> USART2 RX Trigger
  596. // <0x0D=> PWM0 TX Trigger
  597. // <0x0E=> TWIHS0 TX Trigger
  598. // <0x0F=> TWIHS0 RX Trigger
  599. // <0x10=> TWIHS1 TX Trigger
  600. // <0x11=> TWIHS1 RX Trigger
  601. // <0x12=> TWIHS2 TX Trigger
  602. // <0x13=> TWIHS2 RX Trigger
  603. // <0x14=> UART0 TX Trigger
  604. // <0x15=> UART0 RX Trigger
  605. // <0x16=> UART1 TX Trigger
  606. // <0x17=> UART1 RX Trigger
  607. // <0x18=> UART2 TX Trigger
  608. // <0x19=> UART2 RX Trigger
  609. // <0x1A=> UART3 TX Trigger
  610. // <0x1B=> UART3 RX Trigger
  611. // <0x1C=> UART4 TX Trigger
  612. // <0x1D=> UART4 RX Trigger
  613. // <0x1E=> DACC TX Trigger
  614. // <0x20=> SSC TX Trigger
  615. // <0x21=> SSC RX Trigger
  616. // <0x22=> PIOA RX Trigger
  617. // <0x23=> AFEC0 RX Trigger
  618. // <0x24=> AFEC1 RX Trigger
  619. // <0x25=> AES TX Trigger
  620. // <0x26=> AES RX Trigger
  621. // <0x27=> PWM1 TX Trigger
  622. // <0x28=> TC0 RX Trigger
  623. // <0x29=> TC3 RX Trigger
  624. // <0x2A=> TC6 RX Trigger
  625. // <0x2B=> TC9 RX Trigger
  626. // <0x2C=> I2SC0 TX Left Trigger
  627. // <0x2D=> I2SC0 RX Left Trigger
  628. // <0x2E=> I2SC1 TX Left Trigger
  629. // <0x2F=> I2SC1 RX Left Trigger
  630. // <0x30=> I2SC0 TX Right Trigger
  631. // <0x31=> I2SC0 RX Right Trigger
  632. // <0x32=> I2SC1 TX Right Trigger
  633. // <0x33=> I2SC1 RX Right Trigger
  634. // <i> Define the DMA trigger source
  635. // <id> dmac_trifsrc_3
  636. #ifndef CONF_DMAC_TRIGSRC_3
  637. #define CONF_DMAC_TRIGSRC_3 0xff
  638. #endif
  639. // </e>
  640. #if CONF_DMAC_TRANS_TYPE_3 == 0
  641. #define CONF_DMAC_TYPE_3 0
  642. #define CONF_DMAC_DSYNC_3 0
  643. #elif CONF_DMAC_TRANS_TYPE_3 == 1
  644. #define CONF_DMAC_TYPE_3 1
  645. #define CONF_DMAC_DSYNC_3 0
  646. #elif CONF_DMAC_TRANS_TYPE_3 == 2
  647. #define CONF_DMAC_TYPE_3 1
  648. #define CONF_DMAC_DSYNC_3 1
  649. #endif
  650. #if CONF_DMAC_TRIGSRC_3 == 0xFF
  651. #define CONF_DMAC_SWREQ_3 1
  652. #else
  653. #define CONF_DMAC_SWREQ_3 0
  654. #endif
  655. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  656. * or fixed destination address mode, source and destination addresses are incremented
  657. * by 8-bit or 16-bit.
  658. * Workaround: The user can fix the problem by setting the source addressing mode to
  659. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  660. */
  661. #if (CONF_DMAC_CHANNEL_3_SETTINGS == 1 && CONF_DMAC_BEATSIZE_3 != 2 && ((!CONF_DMAC_SRCINC_3) || (!CONF_DMAC_DSTINC_3)))
  662. #if (!CONF_DMAC_SRCINC_3)
  663. #define CONF_DMAC_SRC_STRIDE_3 ((int16_t)(-1))
  664. #endif
  665. #if (!CONF_DMAC_DSTINC_3)
  666. #define CONF_DMAC_DES_STRIDE_3 ((int16_t)(-1))
  667. #endif
  668. #endif
  669. #ifndef CONF_DMAC_SRC_STRIDE_3
  670. #define CONF_DMAC_SRC_STRIDE_3 0
  671. #endif
  672. #ifndef CONF_DMAC_DES_STRIDE_3
  673. #define CONF_DMAC_DES_STRIDE_3 0
  674. #endif
  675. // <e> Channel 4 settings
  676. // <id> dmac_channel_4_settings
  677. #ifndef CONF_DMAC_CHANNEL_4_SETTINGS
  678. #define CONF_DMAC_CHANNEL_4_SETTINGS 0
  679. #endif
  680. // <o> Burst Size
  681. // <0x0=> 1 burst size
  682. // <0x1=> 4 burst size
  683. // <0x2=> 8 burst size
  684. // <0x3=> 16 burst size
  685. // <i> Define the memory burst size
  686. // <id> dmac_burstsize_4
  687. #ifndef CONF_DMAC_BURSTSIZE_4
  688. #define CONF_DMAC_BURSTSIZE_4 0x0
  689. #endif
  690. // <o> Chunk Size
  691. // <0x0=> 1 data transferred
  692. // <0x1=> 2 data transferred
  693. // <0x2=> 4 data transferred
  694. // <0x3=> 8 data transferred
  695. // <0x4=> 16 data transferred
  696. // <i> Define the peripheral chunk size
  697. // <id> dmac_chunksize_4
  698. #ifndef CONF_DMAC_CHUNKSIZE_4
  699. #define CONF_DMAC_CHUNKSIZE_4 0x0
  700. #endif
  701. // <o> Beat Size
  702. // <0=> 8-bit bus transfer
  703. // <1=> 16-bit bus transfer
  704. // <2=> 32-bit bus transfer
  705. // <i> Defines the size of one beat
  706. // <id> dmac_beatsize_4
  707. #ifndef CONF_DMAC_BEATSIZE_4
  708. #define CONF_DMAC_BEATSIZE_4 0x0
  709. #endif
  710. // <o> Source Interface Identifier
  711. // <0x0=> AHB_IF0
  712. // <0x1=> AHB_IF1
  713. // <i> Define the data is read through the system bus interface 0 or 1
  714. // <id> dma_src_interface_4
  715. #ifndef CONF_DMAC_SRC_INTERFACE_4
  716. #define CONF_DMAC_SRC_INTERFACE_4 0x0
  717. #endif
  718. // <o> Destination Interface Identifier
  719. // <0x0=> AHB_IF0
  720. // <0x1=> AHB_IF1
  721. // <i> Define the data is written through the system bus interface 0 or 1
  722. // <id> dma_des_interface_4
  723. #ifndef CONF_DMAC_DES_INTERFACE_4
  724. #define CONF_DMAC_DES_INTERFACE_4 0x0
  725. #endif
  726. // <q> Source Address Increment
  727. // <i> Indicates whether the source address incremented as beat size or not
  728. // <id> dmac_srcinc_4
  729. #ifndef CONF_DMAC_SRCINC_4
  730. #define CONF_DMAC_SRCINC_4 0
  731. #endif
  732. // <q> Destination Address Increment
  733. // <i> Indicates whether the destination address incremented as beat size or not
  734. // <id> dmac_dstinc_4
  735. #ifndef CONF_DMAC_DSTINC_4
  736. #define CONF_DMAC_DSTINC_4 0
  737. #endif
  738. // <o> Transfer Type
  739. // <0x0=> Memory to Memory Transfer
  740. // <0x1=> Peripheral to Memory Transfer
  741. // <0x2=> Memory to Peripheral Transfer
  742. // <i> Define the data transfer type
  743. // <id> dma_trans_type_4
  744. #ifndef CONF_DMAC_TRANS_TYPE_4
  745. #define CONF_DMAC_TRANS_TYPE_4 0x0
  746. #endif
  747. // <o> Trigger source
  748. // <0xFF=> Software Trigger
  749. // <0x00=> HSMCI TX/RX Trigger
  750. // <0x01=> SPI0 TX Trigger
  751. // <0x02=> SPI0 RX Trigger
  752. // <0x03=> SPI1 TX Trigger
  753. // <0x04=> SPI1 RX Trigger
  754. // <0x05=> QSPI TX Trigger
  755. // <0x06=> QSPI RX Trigger
  756. // <0x07=> USART0 TX Trigger
  757. // <0x08=> USART0 RX Trigger
  758. // <0x09=> USART1 TX Trigger
  759. // <0x0A=> USART1 RX Trigger
  760. // <0x0B=> USART2 TX Trigger
  761. // <0x0C=> USART2 RX Trigger
  762. // <0x0D=> PWM0 TX Trigger
  763. // <0x0E=> TWIHS0 TX Trigger
  764. // <0x0F=> TWIHS0 RX Trigger
  765. // <0x10=> TWIHS1 TX Trigger
  766. // <0x11=> TWIHS1 RX Trigger
  767. // <0x12=> TWIHS2 TX Trigger
  768. // <0x13=> TWIHS2 RX Trigger
  769. // <0x14=> UART0 TX Trigger
  770. // <0x15=> UART0 RX Trigger
  771. // <0x16=> UART1 TX Trigger
  772. // <0x17=> UART1 RX Trigger
  773. // <0x18=> UART2 TX Trigger
  774. // <0x19=> UART2 RX Trigger
  775. // <0x1A=> UART3 TX Trigger
  776. // <0x1B=> UART3 RX Trigger
  777. // <0x1C=> UART4 TX Trigger
  778. // <0x1D=> UART4 RX Trigger
  779. // <0x1E=> DACC TX Trigger
  780. // <0x20=> SSC TX Trigger
  781. // <0x21=> SSC RX Trigger
  782. // <0x22=> PIOA RX Trigger
  783. // <0x23=> AFEC0 RX Trigger
  784. // <0x24=> AFEC1 RX Trigger
  785. // <0x25=> AES TX Trigger
  786. // <0x26=> AES RX Trigger
  787. // <0x27=> PWM1 TX Trigger
  788. // <0x28=> TC0 RX Trigger
  789. // <0x29=> TC3 RX Trigger
  790. // <0x2A=> TC6 RX Trigger
  791. // <0x2B=> TC9 RX Trigger
  792. // <0x2C=> I2SC0 TX Left Trigger
  793. // <0x2D=> I2SC0 RX Left Trigger
  794. // <0x2E=> I2SC1 TX Left Trigger
  795. // <0x2F=> I2SC1 RX Left Trigger
  796. // <0x30=> I2SC0 TX Right Trigger
  797. // <0x31=> I2SC0 RX Right Trigger
  798. // <0x32=> I2SC1 TX Right Trigger
  799. // <0x33=> I2SC1 RX Right Trigger
  800. // <i> Define the DMA trigger source
  801. // <id> dmac_trifsrc_4
  802. #ifndef CONF_DMAC_TRIGSRC_4
  803. #define CONF_DMAC_TRIGSRC_4 0xff
  804. #endif
  805. // </e>
  806. #if CONF_DMAC_TRANS_TYPE_4 == 0
  807. #define CONF_DMAC_TYPE_4 0
  808. #define CONF_DMAC_DSYNC_4 0
  809. #elif CONF_DMAC_TRANS_TYPE_4 == 1
  810. #define CONF_DMAC_TYPE_4 1
  811. #define CONF_DMAC_DSYNC_4 0
  812. #elif CONF_DMAC_TRANS_TYPE_4 == 2
  813. #define CONF_DMAC_TYPE_4 1
  814. #define CONF_DMAC_DSYNC_4 1
  815. #endif
  816. #if CONF_DMAC_TRIGSRC_4 == 0xFF
  817. #define CONF_DMAC_SWREQ_4 1
  818. #else
  819. #define CONF_DMAC_SWREQ_4 0
  820. #endif
  821. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  822. * or fixed destination address mode, source and destination addresses are incremented
  823. * by 8-bit or 16-bit.
  824. * Workaround: The user can fix the problem by setting the source addressing mode to
  825. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  826. */
  827. #if (CONF_DMAC_CHANNEL_4_SETTINGS == 1 && CONF_DMAC_BEATSIZE_4 != 2 && ((!CONF_DMAC_SRCINC_4) || (!CONF_DMAC_DSTINC_4)))
  828. #if (!CONF_DMAC_SRCINC_4)
  829. #define CONF_DMAC_SRC_STRIDE_4 ((int16_t)(-1))
  830. #endif
  831. #if (!CONF_DMAC_DSTINC_4)
  832. #define CONF_DMAC_DES_STRIDE_4 ((int16_t)(-1))
  833. #endif
  834. #endif
  835. #ifndef CONF_DMAC_SRC_STRIDE_4
  836. #define CONF_DMAC_SRC_STRIDE_4 0
  837. #endif
  838. #ifndef CONF_DMAC_DES_STRIDE_4
  839. #define CONF_DMAC_DES_STRIDE_4 0
  840. #endif
  841. // <e> Channel 5 settings
  842. // <id> dmac_channel_5_settings
  843. #ifndef CONF_DMAC_CHANNEL_5_SETTINGS
  844. #define CONF_DMAC_CHANNEL_5_SETTINGS 0
  845. #endif
  846. // <o> Burst Size
  847. // <0x0=> 1 burst size
  848. // <0x1=> 4 burst size
  849. // <0x2=> 8 burst size
  850. // <0x3=> 16 burst size
  851. // <i> Define the memory burst size
  852. // <id> dmac_burstsize_5
  853. #ifndef CONF_DMAC_BURSTSIZE_5
  854. #define CONF_DMAC_BURSTSIZE_5 0x0
  855. #endif
  856. // <o> Chunk Size
  857. // <0x0=> 1 data transferred
  858. // <0x1=> 2 data transferred
  859. // <0x2=> 4 data transferred
  860. // <0x3=> 8 data transferred
  861. // <0x4=> 16 data transferred
  862. // <i> Define the peripheral chunk size
  863. // <id> dmac_chunksize_5
  864. #ifndef CONF_DMAC_CHUNKSIZE_5
  865. #define CONF_DMAC_CHUNKSIZE_5 0x0
  866. #endif
  867. // <o> Beat Size
  868. // <0=> 8-bit bus transfer
  869. // <1=> 16-bit bus transfer
  870. // <2=> 32-bit bus transfer
  871. // <i> Defines the size of one beat
  872. // <id> dmac_beatsize_5
  873. #ifndef CONF_DMAC_BEATSIZE_5
  874. #define CONF_DMAC_BEATSIZE_5 0x0
  875. #endif
  876. // <o> Source Interface Identifier
  877. // <0x0=> AHB_IF0
  878. // <0x1=> AHB_IF1
  879. // <i> Define the data is read through the system bus interface 0 or 1
  880. // <id> dma_src_interface_5
  881. #ifndef CONF_DMAC_SRC_INTERFACE_5
  882. #define CONF_DMAC_SRC_INTERFACE_5 0x0
  883. #endif
  884. // <o> Destination Interface Identifier
  885. // <0x0=> AHB_IF0
  886. // <0x1=> AHB_IF1
  887. // <i> Define the data is written through the system bus interface 0 or 1
  888. // <id> dma_des_interface_5
  889. #ifndef CONF_DMAC_DES_INTERFACE_5
  890. #define CONF_DMAC_DES_INTERFACE_5 0x0
  891. #endif
  892. // <q> Source Address Increment
  893. // <i> Indicates whether the source address incremented as beat size or not
  894. // <id> dmac_srcinc_5
  895. #ifndef CONF_DMAC_SRCINC_5
  896. #define CONF_DMAC_SRCINC_5 0
  897. #endif
  898. // <q> Destination Address Increment
  899. // <i> Indicates whether the destination address incremented as beat size or not
  900. // <id> dmac_dstinc_5
  901. #ifndef CONF_DMAC_DSTINC_5
  902. #define CONF_DMAC_DSTINC_5 0
  903. #endif
  904. // <o> Transfer Type
  905. // <0x0=> Memory to Memory Transfer
  906. // <0x1=> Peripheral to Memory Transfer
  907. // <0x2=> Memory to Peripheral Transfer
  908. // <i> Define the data transfer type
  909. // <id> dma_trans_type_5
  910. #ifndef CONF_DMAC_TRANS_TYPE_5
  911. #define CONF_DMAC_TRANS_TYPE_5 0x0
  912. #endif
  913. // <o> Trigger source
  914. // <0xFF=> Software Trigger
  915. // <0x00=> HSMCI TX/RX Trigger
  916. // <0x01=> SPI0 TX Trigger
  917. // <0x02=> SPI0 RX Trigger
  918. // <0x03=> SPI1 TX Trigger
  919. // <0x04=> SPI1 RX Trigger
  920. // <0x05=> QSPI TX Trigger
  921. // <0x06=> QSPI RX Trigger
  922. // <0x07=> USART0 TX Trigger
  923. // <0x08=> USART0 RX Trigger
  924. // <0x09=> USART1 TX Trigger
  925. // <0x0A=> USART1 RX Trigger
  926. // <0x0B=> USART2 TX Trigger
  927. // <0x0C=> USART2 RX Trigger
  928. // <0x0D=> PWM0 TX Trigger
  929. // <0x0E=> TWIHS0 TX Trigger
  930. // <0x0F=> TWIHS0 RX Trigger
  931. // <0x10=> TWIHS1 TX Trigger
  932. // <0x11=> TWIHS1 RX Trigger
  933. // <0x12=> TWIHS2 TX Trigger
  934. // <0x13=> TWIHS2 RX Trigger
  935. // <0x14=> UART0 TX Trigger
  936. // <0x15=> UART0 RX Trigger
  937. // <0x16=> UART1 TX Trigger
  938. // <0x17=> UART1 RX Trigger
  939. // <0x18=> UART2 TX Trigger
  940. // <0x19=> UART2 RX Trigger
  941. // <0x1A=> UART3 TX Trigger
  942. // <0x1B=> UART3 RX Trigger
  943. // <0x1C=> UART4 TX Trigger
  944. // <0x1D=> UART4 RX Trigger
  945. // <0x1E=> DACC TX Trigger
  946. // <0x20=> SSC TX Trigger
  947. // <0x21=> SSC RX Trigger
  948. // <0x22=> PIOA RX Trigger
  949. // <0x23=> AFEC0 RX Trigger
  950. // <0x24=> AFEC1 RX Trigger
  951. // <0x25=> AES TX Trigger
  952. // <0x26=> AES RX Trigger
  953. // <0x27=> PWM1 TX Trigger
  954. // <0x28=> TC0 RX Trigger
  955. // <0x29=> TC3 RX Trigger
  956. // <0x2A=> TC6 RX Trigger
  957. // <0x2B=> TC9 RX Trigger
  958. // <0x2C=> I2SC0 TX Left Trigger
  959. // <0x2D=> I2SC0 RX Left Trigger
  960. // <0x2E=> I2SC1 TX Left Trigger
  961. // <0x2F=> I2SC1 RX Left Trigger
  962. // <0x30=> I2SC0 TX Right Trigger
  963. // <0x31=> I2SC0 RX Right Trigger
  964. // <0x32=> I2SC1 TX Right Trigger
  965. // <0x33=> I2SC1 RX Right Trigger
  966. // <i> Define the DMA trigger source
  967. // <id> dmac_trifsrc_5
  968. #ifndef CONF_DMAC_TRIGSRC_5
  969. #define CONF_DMAC_TRIGSRC_5 0xff
  970. #endif
  971. // </e>
  972. #if CONF_DMAC_TRANS_TYPE_5 == 0
  973. #define CONF_DMAC_TYPE_5 0
  974. #define CONF_DMAC_DSYNC_5 0
  975. #elif CONF_DMAC_TRANS_TYPE_5 == 1
  976. #define CONF_DMAC_TYPE_5 1
  977. #define CONF_DMAC_DSYNC_5 0
  978. #elif CONF_DMAC_TRANS_TYPE_5 == 2
  979. #define CONF_DMAC_TYPE_5 1
  980. #define CONF_DMAC_DSYNC_5 1
  981. #endif
  982. #if CONF_DMAC_TRIGSRC_5 == 0xFF
  983. #define CONF_DMAC_SWREQ_5 1
  984. #else
  985. #define CONF_DMAC_SWREQ_5 0
  986. #endif
  987. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  988. * or fixed destination address mode, source and destination addresses are incremented
  989. * by 8-bit or 16-bit.
  990. * Workaround: The user can fix the problem by setting the source addressing mode to
  991. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  992. */
  993. #if (CONF_DMAC_CHANNEL_5_SETTINGS == 1 && CONF_DMAC_BEATSIZE_5 != 2 && ((!CONF_DMAC_SRCINC_5) || (!CONF_DMAC_DSTINC_5)))
  994. #if (!CONF_DMAC_SRCINC_5)
  995. #define CONF_DMAC_SRC_STRIDE_5 ((int16_t)(-1))
  996. #endif
  997. #if (!CONF_DMAC_DSTINC_5)
  998. #define CONF_DMAC_DES_STRIDE_5 ((int16_t)(-1))
  999. #endif
  1000. #endif
  1001. #ifndef CONF_DMAC_SRC_STRIDE_5
  1002. #define CONF_DMAC_SRC_STRIDE_5 0
  1003. #endif
  1004. #ifndef CONF_DMAC_DES_STRIDE_5
  1005. #define CONF_DMAC_DES_STRIDE_5 0
  1006. #endif
  1007. // <e> Channel 6 settings
  1008. // <id> dmac_channel_6_settings
  1009. #ifndef CONF_DMAC_CHANNEL_6_SETTINGS
  1010. #define CONF_DMAC_CHANNEL_6_SETTINGS 0
  1011. #endif
  1012. // <o> Burst Size
  1013. // <0x0=> 1 burst size
  1014. // <0x1=> 4 burst size
  1015. // <0x2=> 8 burst size
  1016. // <0x3=> 16 burst size
  1017. // <i> Define the memory burst size
  1018. // <id> dmac_burstsize_6
  1019. #ifndef CONF_DMAC_BURSTSIZE_6
  1020. #define CONF_DMAC_BURSTSIZE_6 0x0
  1021. #endif
  1022. // <o> Chunk Size
  1023. // <0x0=> 1 data transferred
  1024. // <0x1=> 2 data transferred
  1025. // <0x2=> 4 data transferred
  1026. // <0x3=> 8 data transferred
  1027. // <0x4=> 16 data transferred
  1028. // <i> Define the peripheral chunk size
  1029. // <id> dmac_chunksize_6
  1030. #ifndef CONF_DMAC_CHUNKSIZE_6
  1031. #define CONF_DMAC_CHUNKSIZE_6 0x0
  1032. #endif
  1033. // <o> Beat Size
  1034. // <0=> 8-bit bus transfer
  1035. // <1=> 16-bit bus transfer
  1036. // <2=> 32-bit bus transfer
  1037. // <i> Defines the size of one beat
  1038. // <id> dmac_beatsize_6
  1039. #ifndef CONF_DMAC_BEATSIZE_6
  1040. #define CONF_DMAC_BEATSIZE_6 0x0
  1041. #endif
  1042. // <o> Source Interface Identifier
  1043. // <0x0=> AHB_IF0
  1044. // <0x1=> AHB_IF1
  1045. // <i> Define the data is read through the system bus interface 0 or 1
  1046. // <id> dma_src_interface_6
  1047. #ifndef CONF_DMAC_SRC_INTERFACE_6
  1048. #define CONF_DMAC_SRC_INTERFACE_6 0x0
  1049. #endif
  1050. // <o> Destination Interface Identifier
  1051. // <0x0=> AHB_IF0
  1052. // <0x1=> AHB_IF1
  1053. // <i> Define the data is written through the system bus interface 0 or 1
  1054. // <id> dma_des_interface_6
  1055. #ifndef CONF_DMAC_DES_INTERFACE_6
  1056. #define CONF_DMAC_DES_INTERFACE_6 0x0
  1057. #endif
  1058. // <q> Source Address Increment
  1059. // <i> Indicates whether the source address incremented as beat size or not
  1060. // <id> dmac_srcinc_6
  1061. #ifndef CONF_DMAC_SRCINC_6
  1062. #define CONF_DMAC_SRCINC_6 0
  1063. #endif
  1064. // <q> Destination Address Increment
  1065. // <i> Indicates whether the destination address incremented as beat size or not
  1066. // <id> dmac_dstinc_6
  1067. #ifndef CONF_DMAC_DSTINC_6
  1068. #define CONF_DMAC_DSTINC_6 0
  1069. #endif
  1070. // <o> Transfer Type
  1071. // <0x0=> Memory to Memory Transfer
  1072. // <0x1=> Peripheral to Memory Transfer
  1073. // <0x2=> Memory to Peripheral Transfer
  1074. // <i> Define the data transfer type
  1075. // <id> dma_trans_type_6
  1076. #ifndef CONF_DMAC_TRANS_TYPE_6
  1077. #define CONF_DMAC_TRANS_TYPE_6 0x0
  1078. #endif
  1079. // <o> Trigger source
  1080. // <0xFF=> Software Trigger
  1081. // <0x00=> HSMCI TX/RX Trigger
  1082. // <0x01=> SPI0 TX Trigger
  1083. // <0x02=> SPI0 RX Trigger
  1084. // <0x03=> SPI1 TX Trigger
  1085. // <0x04=> SPI1 RX Trigger
  1086. // <0x05=> QSPI TX Trigger
  1087. // <0x06=> QSPI RX Trigger
  1088. // <0x07=> USART0 TX Trigger
  1089. // <0x08=> USART0 RX Trigger
  1090. // <0x09=> USART1 TX Trigger
  1091. // <0x0A=> USART1 RX Trigger
  1092. // <0x0B=> USART2 TX Trigger
  1093. // <0x0C=> USART2 RX Trigger
  1094. // <0x0D=> PWM0 TX Trigger
  1095. // <0x0E=> TWIHS0 TX Trigger
  1096. // <0x0F=> TWIHS0 RX Trigger
  1097. // <0x10=> TWIHS1 TX Trigger
  1098. // <0x11=> TWIHS1 RX Trigger
  1099. // <0x12=> TWIHS2 TX Trigger
  1100. // <0x13=> TWIHS2 RX Trigger
  1101. // <0x14=> UART0 TX Trigger
  1102. // <0x15=> UART0 RX Trigger
  1103. // <0x16=> UART1 TX Trigger
  1104. // <0x17=> UART1 RX Trigger
  1105. // <0x18=> UART2 TX Trigger
  1106. // <0x19=> UART2 RX Trigger
  1107. // <0x1A=> UART3 TX Trigger
  1108. // <0x1B=> UART3 RX Trigger
  1109. // <0x1C=> UART4 TX Trigger
  1110. // <0x1D=> UART4 RX Trigger
  1111. // <0x1E=> DACC TX Trigger
  1112. // <0x20=> SSC TX Trigger
  1113. // <0x21=> SSC RX Trigger
  1114. // <0x22=> PIOA RX Trigger
  1115. // <0x23=> AFEC0 RX Trigger
  1116. // <0x24=> AFEC1 RX Trigger
  1117. // <0x25=> AES TX Trigger
  1118. // <0x26=> AES RX Trigger
  1119. // <0x27=> PWM1 TX Trigger
  1120. // <0x28=> TC0 RX Trigger
  1121. // <0x29=> TC3 RX Trigger
  1122. // <0x2A=> TC6 RX Trigger
  1123. // <0x2B=> TC9 RX Trigger
  1124. // <0x2C=> I2SC0 TX Left Trigger
  1125. // <0x2D=> I2SC0 RX Left Trigger
  1126. // <0x2E=> I2SC1 TX Left Trigger
  1127. // <0x2F=> I2SC1 RX Left Trigger
  1128. // <0x30=> I2SC0 TX Right Trigger
  1129. // <0x31=> I2SC0 RX Right Trigger
  1130. // <0x32=> I2SC1 TX Right Trigger
  1131. // <0x33=> I2SC1 RX Right Trigger
  1132. // <i> Define the DMA trigger source
  1133. // <id> dmac_trifsrc_6
  1134. #ifndef CONF_DMAC_TRIGSRC_6
  1135. #define CONF_DMAC_TRIGSRC_6 0xff
  1136. #endif
  1137. // </e>
  1138. #if CONF_DMAC_TRANS_TYPE_6 == 0
  1139. #define CONF_DMAC_TYPE_6 0
  1140. #define CONF_DMAC_DSYNC_6 0
  1141. #elif CONF_DMAC_TRANS_TYPE_6 == 1
  1142. #define CONF_DMAC_TYPE_6 1
  1143. #define CONF_DMAC_DSYNC_6 0
  1144. #elif CONF_DMAC_TRANS_TYPE_6 == 2
  1145. #define CONF_DMAC_TYPE_6 1
  1146. #define CONF_DMAC_DSYNC_6 1
  1147. #endif
  1148. #if CONF_DMAC_TRIGSRC_6 == 0xFF
  1149. #define CONF_DMAC_SWREQ_6 1
  1150. #else
  1151. #define CONF_DMAC_SWREQ_6 0
  1152. #endif
  1153. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1154. * or fixed destination address mode, source and destination addresses are incremented
  1155. * by 8-bit or 16-bit.
  1156. * Workaround: The user can fix the problem by setting the source addressing mode to
  1157. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1158. */
  1159. #if (CONF_DMAC_CHANNEL_6_SETTINGS == 1 && CONF_DMAC_BEATSIZE_6 != 2 && ((!CONF_DMAC_SRCINC_6) || (!CONF_DMAC_DSTINC_6)))
  1160. #if (!CONF_DMAC_SRCINC_6)
  1161. #define CONF_DMAC_SRC_STRIDE_6 ((int16_t)(-1))
  1162. #endif
  1163. #if (!CONF_DMAC_DSTINC_6)
  1164. #define CONF_DMAC_DES_STRIDE_6 ((int16_t)(-1))
  1165. #endif
  1166. #endif
  1167. #ifndef CONF_DMAC_SRC_STRIDE_6
  1168. #define CONF_DMAC_SRC_STRIDE_6 0
  1169. #endif
  1170. #ifndef CONF_DMAC_DES_STRIDE_6
  1171. #define CONF_DMAC_DES_STRIDE_6 0
  1172. #endif
  1173. // <e> Channel 7 settings
  1174. // <id> dmac_channel_7_settings
  1175. #ifndef CONF_DMAC_CHANNEL_7_SETTINGS
  1176. #define CONF_DMAC_CHANNEL_7_SETTINGS 0
  1177. #endif
  1178. // <o> Burst Size
  1179. // <0x0=> 1 burst size
  1180. // <0x1=> 4 burst size
  1181. // <0x2=> 8 burst size
  1182. // <0x3=> 16 burst size
  1183. // <i> Define the memory burst size
  1184. // <id> dmac_burstsize_7
  1185. #ifndef CONF_DMAC_BURSTSIZE_7
  1186. #define CONF_DMAC_BURSTSIZE_7 0x0
  1187. #endif
  1188. // <o> Chunk Size
  1189. // <0x0=> 1 data transferred
  1190. // <0x1=> 2 data transferred
  1191. // <0x2=> 4 data transferred
  1192. // <0x3=> 8 data transferred
  1193. // <0x4=> 16 data transferred
  1194. // <i> Define the peripheral chunk size
  1195. // <id> dmac_chunksize_7
  1196. #ifndef CONF_DMAC_CHUNKSIZE_7
  1197. #define CONF_DMAC_CHUNKSIZE_7 0x0
  1198. #endif
  1199. // <o> Beat Size
  1200. // <0=> 8-bit bus transfer
  1201. // <1=> 16-bit bus transfer
  1202. // <2=> 32-bit bus transfer
  1203. // <i> Defines the size of one beat
  1204. // <id> dmac_beatsize_7
  1205. #ifndef CONF_DMAC_BEATSIZE_7
  1206. #define CONF_DMAC_BEATSIZE_7 0x0
  1207. #endif
  1208. // <o> Source Interface Identifier
  1209. // <0x0=> AHB_IF0
  1210. // <0x1=> AHB_IF1
  1211. // <i> Define the data is read through the system bus interface 0 or 1
  1212. // <id> dma_src_interface_7
  1213. #ifndef CONF_DMAC_SRC_INTERFACE_7
  1214. #define CONF_DMAC_SRC_INTERFACE_7 0x0
  1215. #endif
  1216. // <o> Destination Interface Identifier
  1217. // <0x0=> AHB_IF0
  1218. // <0x1=> AHB_IF1
  1219. // <i> Define the data is written through the system bus interface 0 or 1
  1220. // <id> dma_des_interface_7
  1221. #ifndef CONF_DMAC_DES_INTERFACE_7
  1222. #define CONF_DMAC_DES_INTERFACE_7 0x0
  1223. #endif
  1224. // <q> Source Address Increment
  1225. // <i> Indicates whether the source address incremented as beat size or not
  1226. // <id> dmac_srcinc_7
  1227. #ifndef CONF_DMAC_SRCINC_7
  1228. #define CONF_DMAC_SRCINC_7 0
  1229. #endif
  1230. // <q> Destination Address Increment
  1231. // <i> Indicates whether the destination address incremented as beat size or not
  1232. // <id> dmac_dstinc_7
  1233. #ifndef CONF_DMAC_DSTINC_7
  1234. #define CONF_DMAC_DSTINC_7 0
  1235. #endif
  1236. // <o> Transfer Type
  1237. // <0x0=> Memory to Memory Transfer
  1238. // <0x1=> Peripheral to Memory Transfer
  1239. // <0x2=> Memory to Peripheral Transfer
  1240. // <i> Define the data transfer type
  1241. // <id> dma_trans_type_7
  1242. #ifndef CONF_DMAC_TRANS_TYPE_7
  1243. #define CONF_DMAC_TRANS_TYPE_7 0x0
  1244. #endif
  1245. // <o> Trigger source
  1246. // <0xFF=> Software Trigger
  1247. // <0x00=> HSMCI TX/RX Trigger
  1248. // <0x01=> SPI0 TX Trigger
  1249. // <0x02=> SPI0 RX Trigger
  1250. // <0x03=> SPI1 TX Trigger
  1251. // <0x04=> SPI1 RX Trigger
  1252. // <0x05=> QSPI TX Trigger
  1253. // <0x06=> QSPI RX Trigger
  1254. // <0x07=> USART0 TX Trigger
  1255. // <0x08=> USART0 RX Trigger
  1256. // <0x09=> USART1 TX Trigger
  1257. // <0x0A=> USART1 RX Trigger
  1258. // <0x0B=> USART2 TX Trigger
  1259. // <0x0C=> USART2 RX Trigger
  1260. // <0x0D=> PWM0 TX Trigger
  1261. // <0x0E=> TWIHS0 TX Trigger
  1262. // <0x0F=> TWIHS0 RX Trigger
  1263. // <0x10=> TWIHS1 TX Trigger
  1264. // <0x11=> TWIHS1 RX Trigger
  1265. // <0x12=> TWIHS2 TX Trigger
  1266. // <0x13=> TWIHS2 RX Trigger
  1267. // <0x14=> UART0 TX Trigger
  1268. // <0x15=> UART0 RX Trigger
  1269. // <0x16=> UART1 TX Trigger
  1270. // <0x17=> UART1 RX Trigger
  1271. // <0x18=> UART2 TX Trigger
  1272. // <0x19=> UART2 RX Trigger
  1273. // <0x1A=> UART3 TX Trigger
  1274. // <0x1B=> UART3 RX Trigger
  1275. // <0x1C=> UART4 TX Trigger
  1276. // <0x1D=> UART4 RX Trigger
  1277. // <0x1E=> DACC TX Trigger
  1278. // <0x20=> SSC TX Trigger
  1279. // <0x21=> SSC RX Trigger
  1280. // <0x22=> PIOA RX Trigger
  1281. // <0x23=> AFEC0 RX Trigger
  1282. // <0x24=> AFEC1 RX Trigger
  1283. // <0x25=> AES TX Trigger
  1284. // <0x26=> AES RX Trigger
  1285. // <0x27=> PWM1 TX Trigger
  1286. // <0x28=> TC0 RX Trigger
  1287. // <0x29=> TC3 RX Trigger
  1288. // <0x2A=> TC6 RX Trigger
  1289. // <0x2B=> TC9 RX Trigger
  1290. // <0x2C=> I2SC0 TX Left Trigger
  1291. // <0x2D=> I2SC0 RX Left Trigger
  1292. // <0x2E=> I2SC1 TX Left Trigger
  1293. // <0x2F=> I2SC1 RX Left Trigger
  1294. // <0x30=> I2SC0 TX Right Trigger
  1295. // <0x31=> I2SC0 RX Right Trigger
  1296. // <0x32=> I2SC1 TX Right Trigger
  1297. // <0x33=> I2SC1 RX Right Trigger
  1298. // <i> Define the DMA trigger source
  1299. // <id> dmac_trifsrc_7
  1300. #ifndef CONF_DMAC_TRIGSRC_7
  1301. #define CONF_DMAC_TRIGSRC_7 0xff
  1302. #endif
  1303. // </e>
  1304. #if CONF_DMAC_TRANS_TYPE_7 == 0
  1305. #define CONF_DMAC_TYPE_7 0
  1306. #define CONF_DMAC_DSYNC_7 0
  1307. #elif CONF_DMAC_TRANS_TYPE_7 == 1
  1308. #define CONF_DMAC_TYPE_7 1
  1309. #define CONF_DMAC_DSYNC_7 0
  1310. #elif CONF_DMAC_TRANS_TYPE_7 == 2
  1311. #define CONF_DMAC_TYPE_7 1
  1312. #define CONF_DMAC_DSYNC_7 1
  1313. #endif
  1314. #if CONF_DMAC_TRIGSRC_7 == 0xFF
  1315. #define CONF_DMAC_SWREQ_7 1
  1316. #else
  1317. #define CONF_DMAC_SWREQ_7 0
  1318. #endif
  1319. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1320. * or fixed destination address mode, source and destination addresses are incremented
  1321. * by 8-bit or 16-bit.
  1322. * Workaround: The user can fix the problem by setting the source addressing mode to
  1323. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1324. */
  1325. #if (CONF_DMAC_CHANNEL_7_SETTINGS == 1 && CONF_DMAC_BEATSIZE_7 != 2 && ((!CONF_DMAC_SRCINC_7) || (!CONF_DMAC_DSTINC_7)))
  1326. #if (!CONF_DMAC_SRCINC_7)
  1327. #define CONF_DMAC_SRC_STRIDE_7 ((int16_t)(-1))
  1328. #endif
  1329. #if (!CONF_DMAC_DSTINC_7)
  1330. #define CONF_DMAC_DES_STRIDE_7 ((int16_t)(-1))
  1331. #endif
  1332. #endif
  1333. #ifndef CONF_DMAC_SRC_STRIDE_7
  1334. #define CONF_DMAC_SRC_STRIDE_7 0
  1335. #endif
  1336. #ifndef CONF_DMAC_DES_STRIDE_7
  1337. #define CONF_DMAC_DES_STRIDE_7 0
  1338. #endif
  1339. // <e> Channel 8 settings
  1340. // <id> dmac_channel_8_settings
  1341. #ifndef CONF_DMAC_CHANNEL_8_SETTINGS
  1342. #define CONF_DMAC_CHANNEL_8_SETTINGS 0
  1343. #endif
  1344. // <o> Burst Size
  1345. // <0x0=> 1 burst size
  1346. // <0x1=> 4 burst size
  1347. // <0x2=> 8 burst size
  1348. // <0x3=> 16 burst size
  1349. // <i> Define the memory burst size
  1350. // <id> dmac_burstsize_8
  1351. #ifndef CONF_DMAC_BURSTSIZE_8
  1352. #define CONF_DMAC_BURSTSIZE_8 0x0
  1353. #endif
  1354. // <o> Chunk Size
  1355. // <0x0=> 1 data transferred
  1356. // <0x1=> 2 data transferred
  1357. // <0x2=> 4 data transferred
  1358. // <0x3=> 8 data transferred
  1359. // <0x4=> 16 data transferred
  1360. // <i> Define the peripheral chunk size
  1361. // <id> dmac_chunksize_8
  1362. #ifndef CONF_DMAC_CHUNKSIZE_8
  1363. #define CONF_DMAC_CHUNKSIZE_8 0x0
  1364. #endif
  1365. // <o> Beat Size
  1366. // <0=> 8-bit bus transfer
  1367. // <1=> 16-bit bus transfer
  1368. // <2=> 32-bit bus transfer
  1369. // <i> Defines the size of one beat
  1370. // <id> dmac_beatsize_8
  1371. #ifndef CONF_DMAC_BEATSIZE_8
  1372. #define CONF_DMAC_BEATSIZE_8 0x0
  1373. #endif
  1374. // <o> Source Interface Identifier
  1375. // <0x0=> AHB_IF0
  1376. // <0x1=> AHB_IF1
  1377. // <i> Define the data is read through the system bus interface 0 or 1
  1378. // <id> dma_src_interface_8
  1379. #ifndef CONF_DMAC_SRC_INTERFACE_8
  1380. #define CONF_DMAC_SRC_INTERFACE_8 0x0
  1381. #endif
  1382. // <o> Destination Interface Identifier
  1383. // <0x0=> AHB_IF0
  1384. // <0x1=> AHB_IF1
  1385. // <i> Define the data is written through the system bus interface 0 or 1
  1386. // <id> dma_des_interface_8
  1387. #ifndef CONF_DMAC_DES_INTERFACE_8
  1388. #define CONF_DMAC_DES_INTERFACE_8 0x0
  1389. #endif
  1390. // <q> Source Address Increment
  1391. // <i> Indicates whether the source address incremented as beat size or not
  1392. // <id> dmac_srcinc_8
  1393. #ifndef CONF_DMAC_SRCINC_8
  1394. #define CONF_DMAC_SRCINC_8 0
  1395. #endif
  1396. // <q> Destination Address Increment
  1397. // <i> Indicates whether the destination address incremented as beat size or not
  1398. // <id> dmac_dstinc_8
  1399. #ifndef CONF_DMAC_DSTINC_8
  1400. #define CONF_DMAC_DSTINC_8 0
  1401. #endif
  1402. // <o> Transfer Type
  1403. // <0x0=> Memory to Memory Transfer
  1404. // <0x1=> Peripheral to Memory Transfer
  1405. // <0x2=> Memory to Peripheral Transfer
  1406. // <i> Define the data transfer type
  1407. // <id> dma_trans_type_8
  1408. #ifndef CONF_DMAC_TRANS_TYPE_8
  1409. #define CONF_DMAC_TRANS_TYPE_8 0x0
  1410. #endif
  1411. // <o> Trigger source
  1412. // <0xFF=> Software Trigger
  1413. // <0x00=> HSMCI TX/RX Trigger
  1414. // <0x01=> SPI0 TX Trigger
  1415. // <0x02=> SPI0 RX Trigger
  1416. // <0x03=> SPI1 TX Trigger
  1417. // <0x04=> SPI1 RX Trigger
  1418. // <0x05=> QSPI TX Trigger
  1419. // <0x06=> QSPI RX Trigger
  1420. // <0x07=> USART0 TX Trigger
  1421. // <0x08=> USART0 RX Trigger
  1422. // <0x09=> USART1 TX Trigger
  1423. // <0x0A=> USART1 RX Trigger
  1424. // <0x0B=> USART2 TX Trigger
  1425. // <0x0C=> USART2 RX Trigger
  1426. // <0x0D=> PWM0 TX Trigger
  1427. // <0x0E=> TWIHS0 TX Trigger
  1428. // <0x0F=> TWIHS0 RX Trigger
  1429. // <0x10=> TWIHS1 TX Trigger
  1430. // <0x11=> TWIHS1 RX Trigger
  1431. // <0x12=> TWIHS2 TX Trigger
  1432. // <0x13=> TWIHS2 RX Trigger
  1433. // <0x14=> UART0 TX Trigger
  1434. // <0x15=> UART0 RX Trigger
  1435. // <0x16=> UART1 TX Trigger
  1436. // <0x17=> UART1 RX Trigger
  1437. // <0x18=> UART2 TX Trigger
  1438. // <0x19=> UART2 RX Trigger
  1439. // <0x1A=> UART3 TX Trigger
  1440. // <0x1B=> UART3 RX Trigger
  1441. // <0x1C=> UART4 TX Trigger
  1442. // <0x1D=> UART4 RX Trigger
  1443. // <0x1E=> DACC TX Trigger
  1444. // <0x20=> SSC TX Trigger
  1445. // <0x21=> SSC RX Trigger
  1446. // <0x22=> PIOA RX Trigger
  1447. // <0x23=> AFEC0 RX Trigger
  1448. // <0x24=> AFEC1 RX Trigger
  1449. // <0x25=> AES TX Trigger
  1450. // <0x26=> AES RX Trigger
  1451. // <0x27=> PWM1 TX Trigger
  1452. // <0x28=> TC0 RX Trigger
  1453. // <0x29=> TC3 RX Trigger
  1454. // <0x2A=> TC6 RX Trigger
  1455. // <0x2B=> TC9 RX Trigger
  1456. // <0x2C=> I2SC0 TX Left Trigger
  1457. // <0x2D=> I2SC0 RX Left Trigger
  1458. // <0x2E=> I2SC1 TX Left Trigger
  1459. // <0x2F=> I2SC1 RX Left Trigger
  1460. // <0x30=> I2SC0 TX Right Trigger
  1461. // <0x31=> I2SC0 RX Right Trigger
  1462. // <0x32=> I2SC1 TX Right Trigger
  1463. // <0x33=> I2SC1 RX Right Trigger
  1464. // <i> Define the DMA trigger source
  1465. // <id> dmac_trifsrc_8
  1466. #ifndef CONF_DMAC_TRIGSRC_8
  1467. #define CONF_DMAC_TRIGSRC_8 0xff
  1468. #endif
  1469. // </e>
  1470. #if CONF_DMAC_TRANS_TYPE_8 == 0
  1471. #define CONF_DMAC_TYPE_8 0
  1472. #define CONF_DMAC_DSYNC_8 0
  1473. #elif CONF_DMAC_TRANS_TYPE_8 == 1
  1474. #define CONF_DMAC_TYPE_8 1
  1475. #define CONF_DMAC_DSYNC_8 0
  1476. #elif CONF_DMAC_TRANS_TYPE_8 == 2
  1477. #define CONF_DMAC_TYPE_8 1
  1478. #define CONF_DMAC_DSYNC_8 1
  1479. #endif
  1480. #if CONF_DMAC_TRIGSRC_8 == 0xFF
  1481. #define CONF_DMAC_SWREQ_8 1
  1482. #else
  1483. #define CONF_DMAC_SWREQ_8 0
  1484. #endif
  1485. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1486. * or fixed destination address mode, source and destination addresses are incremented
  1487. * by 8-bit or 16-bit.
  1488. * Workaround: The user can fix the problem by setting the source addressing mode to
  1489. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1490. */
  1491. #if (CONF_DMAC_CHANNEL_8_SETTINGS == 1 && CONF_DMAC_BEATSIZE_8 != 2 && ((!CONF_DMAC_SRCINC_8) || (!CONF_DMAC_DSTINC_8)))
  1492. #if (!CONF_DMAC_SRCINC_8)
  1493. #define CONF_DMAC_SRC_STRIDE_8 ((int16_t)(-1))
  1494. #endif
  1495. #if (!CONF_DMAC_DSTINC_8)
  1496. #define CONF_DMAC_DES_STRIDE_8 ((int16_t)(-1))
  1497. #endif
  1498. #endif
  1499. #ifndef CONF_DMAC_SRC_STRIDE_8
  1500. #define CONF_DMAC_SRC_STRIDE_8 0
  1501. #endif
  1502. #ifndef CONF_DMAC_DES_STRIDE_8
  1503. #define CONF_DMAC_DES_STRIDE_8 0
  1504. #endif
  1505. // <e> Channel 9 settings
  1506. // <id> dmac_channel_9_settings
  1507. #ifndef CONF_DMAC_CHANNEL_9_SETTINGS
  1508. #define CONF_DMAC_CHANNEL_9_SETTINGS 0
  1509. #endif
  1510. // <o> Burst Size
  1511. // <0x0=> 1 burst size
  1512. // <0x1=> 4 burst size
  1513. // <0x2=> 8 burst size
  1514. // <0x3=> 16 burst size
  1515. // <i> Define the memory burst size
  1516. // <id> dmac_burstsize_9
  1517. #ifndef CONF_DMAC_BURSTSIZE_9
  1518. #define CONF_DMAC_BURSTSIZE_9 0x0
  1519. #endif
  1520. // <o> Chunk Size
  1521. // <0x0=> 1 data transferred
  1522. // <0x1=> 2 data transferred
  1523. // <0x2=> 4 data transferred
  1524. // <0x3=> 8 data transferred
  1525. // <0x4=> 16 data transferred
  1526. // <i> Define the peripheral chunk size
  1527. // <id> dmac_chunksize_9
  1528. #ifndef CONF_DMAC_CHUNKSIZE_9
  1529. #define CONF_DMAC_CHUNKSIZE_9 0x0
  1530. #endif
  1531. // <o> Beat Size
  1532. // <0=> 8-bit bus transfer
  1533. // <1=> 16-bit bus transfer
  1534. // <2=> 32-bit bus transfer
  1535. // <i> Defines the size of one beat
  1536. // <id> dmac_beatsize_9
  1537. #ifndef CONF_DMAC_BEATSIZE_9
  1538. #define CONF_DMAC_BEATSIZE_9 0x0
  1539. #endif
  1540. // <o> Source Interface Identifier
  1541. // <0x0=> AHB_IF0
  1542. // <0x1=> AHB_IF1
  1543. // <i> Define the data is read through the system bus interface 0 or 1
  1544. // <id> dma_src_interface_9
  1545. #ifndef CONF_DMAC_SRC_INTERFACE_9
  1546. #define CONF_DMAC_SRC_INTERFACE_9 0x0
  1547. #endif
  1548. // <o> Destination Interface Identifier
  1549. // <0x0=> AHB_IF0
  1550. // <0x1=> AHB_IF1
  1551. // <i> Define the data is written through the system bus interface 0 or 1
  1552. // <id> dma_des_interface_9
  1553. #ifndef CONF_DMAC_DES_INTERFACE_9
  1554. #define CONF_DMAC_DES_INTERFACE_9 0x0
  1555. #endif
  1556. // <q> Source Address Increment
  1557. // <i> Indicates whether the source address incremented as beat size or not
  1558. // <id> dmac_srcinc_9
  1559. #ifndef CONF_DMAC_SRCINC_9
  1560. #define CONF_DMAC_SRCINC_9 0
  1561. #endif
  1562. // <q> Destination Address Increment
  1563. // <i> Indicates whether the destination address incremented as beat size or not
  1564. // <id> dmac_dstinc_9
  1565. #ifndef CONF_DMAC_DSTINC_9
  1566. #define CONF_DMAC_DSTINC_9 0
  1567. #endif
  1568. // <o> Transfer Type
  1569. // <0x0=> Memory to Memory Transfer
  1570. // <0x1=> Peripheral to Memory Transfer
  1571. // <0x2=> Memory to Peripheral Transfer
  1572. // <i> Define the data transfer type
  1573. // <id> dma_trans_type_9
  1574. #ifndef CONF_DMAC_TRANS_TYPE_9
  1575. #define CONF_DMAC_TRANS_TYPE_9 0x0
  1576. #endif
  1577. // <o> Trigger source
  1578. // <0xFF=> Software Trigger
  1579. // <0x00=> HSMCI TX/RX Trigger
  1580. // <0x01=> SPI0 TX Trigger
  1581. // <0x02=> SPI0 RX Trigger
  1582. // <0x03=> SPI1 TX Trigger
  1583. // <0x04=> SPI1 RX Trigger
  1584. // <0x05=> QSPI TX Trigger
  1585. // <0x06=> QSPI RX Trigger
  1586. // <0x07=> USART0 TX Trigger
  1587. // <0x08=> USART0 RX Trigger
  1588. // <0x09=> USART1 TX Trigger
  1589. // <0x0A=> USART1 RX Trigger
  1590. // <0x0B=> USART2 TX Trigger
  1591. // <0x0C=> USART2 RX Trigger
  1592. // <0x0D=> PWM0 TX Trigger
  1593. // <0x0E=> TWIHS0 TX Trigger
  1594. // <0x0F=> TWIHS0 RX Trigger
  1595. // <0x10=> TWIHS1 TX Trigger
  1596. // <0x11=> TWIHS1 RX Trigger
  1597. // <0x12=> TWIHS2 TX Trigger
  1598. // <0x13=> TWIHS2 RX Trigger
  1599. // <0x14=> UART0 TX Trigger
  1600. // <0x15=> UART0 RX Trigger
  1601. // <0x16=> UART1 TX Trigger
  1602. // <0x17=> UART1 RX Trigger
  1603. // <0x18=> UART2 TX Trigger
  1604. // <0x19=> UART2 RX Trigger
  1605. // <0x1A=> UART3 TX Trigger
  1606. // <0x1B=> UART3 RX Trigger
  1607. // <0x1C=> UART4 TX Trigger
  1608. // <0x1D=> UART4 RX Trigger
  1609. // <0x1E=> DACC TX Trigger
  1610. // <0x20=> SSC TX Trigger
  1611. // <0x21=> SSC RX Trigger
  1612. // <0x22=> PIOA RX Trigger
  1613. // <0x23=> AFEC0 RX Trigger
  1614. // <0x24=> AFEC1 RX Trigger
  1615. // <0x25=> AES TX Trigger
  1616. // <0x26=> AES RX Trigger
  1617. // <0x27=> PWM1 TX Trigger
  1618. // <0x28=> TC0 RX Trigger
  1619. // <0x29=> TC3 RX Trigger
  1620. // <0x2A=> TC6 RX Trigger
  1621. // <0x2B=> TC9 RX Trigger
  1622. // <0x2C=> I2SC0 TX Left Trigger
  1623. // <0x2D=> I2SC0 RX Left Trigger
  1624. // <0x2E=> I2SC1 TX Left Trigger
  1625. // <0x2F=> I2SC1 RX Left Trigger
  1626. // <0x30=> I2SC0 TX Right Trigger
  1627. // <0x31=> I2SC0 RX Right Trigger
  1628. // <0x32=> I2SC1 TX Right Trigger
  1629. // <0x33=> I2SC1 RX Right Trigger
  1630. // <i> Define the DMA trigger source
  1631. // <id> dmac_trifsrc_9
  1632. #ifndef CONF_DMAC_TRIGSRC_9
  1633. #define CONF_DMAC_TRIGSRC_9 0xff
  1634. #endif
  1635. // </e>
  1636. #if CONF_DMAC_TRANS_TYPE_9 == 0
  1637. #define CONF_DMAC_TYPE_9 0
  1638. #define CONF_DMAC_DSYNC_9 0
  1639. #elif CONF_DMAC_TRANS_TYPE_9 == 1
  1640. #define CONF_DMAC_TYPE_9 1
  1641. #define CONF_DMAC_DSYNC_9 0
  1642. #elif CONF_DMAC_TRANS_TYPE_9 == 2
  1643. #define CONF_DMAC_TYPE_9 1
  1644. #define CONF_DMAC_DSYNC_9 1
  1645. #endif
  1646. #if CONF_DMAC_TRIGSRC_9 == 0xFF
  1647. #define CONF_DMAC_SWREQ_9 1
  1648. #else
  1649. #define CONF_DMAC_SWREQ_9 0
  1650. #endif
  1651. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1652. * or fixed destination address mode, source and destination addresses are incremented
  1653. * by 8-bit or 16-bit.
  1654. * Workaround: The user can fix the problem by setting the source addressing mode to
  1655. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1656. */
  1657. #if (CONF_DMAC_CHANNEL_9_SETTINGS == 1 && CONF_DMAC_BEATSIZE_9 != 2 && ((!CONF_DMAC_SRCINC_9) || (!CONF_DMAC_DSTINC_9)))
  1658. #if (!CONF_DMAC_SRCINC_9)
  1659. #define CONF_DMAC_SRC_STRIDE_9 ((int16_t)(-1))
  1660. #endif
  1661. #if (!CONF_DMAC_DSTINC_9)
  1662. #define CONF_DMAC_DES_STRIDE_9 ((int16_t)(-1))
  1663. #endif
  1664. #endif
  1665. #ifndef CONF_DMAC_SRC_STRIDE_9
  1666. #define CONF_DMAC_SRC_STRIDE_9 0
  1667. #endif
  1668. #ifndef CONF_DMAC_DES_STRIDE_9
  1669. #define CONF_DMAC_DES_STRIDE_9 0
  1670. #endif
  1671. // <e> Channel 10 settings
  1672. // <id> dmac_channel_10_settings
  1673. #ifndef CONF_DMAC_CHANNEL_10_SETTINGS
  1674. #define CONF_DMAC_CHANNEL_10_SETTINGS 0
  1675. #endif
  1676. // <o> Burst Size
  1677. // <0x0=> 1 burst size
  1678. // <0x1=> 4 burst size
  1679. // <0x2=> 8 burst size
  1680. // <0x3=> 16 burst size
  1681. // <i> Define the memory burst size
  1682. // <id> dmac_burstsize_10
  1683. #ifndef CONF_DMAC_BURSTSIZE_10
  1684. #define CONF_DMAC_BURSTSIZE_10 0x0
  1685. #endif
  1686. // <o> Chunk Size
  1687. // <0x0=> 1 data transferred
  1688. // <0x1=> 2 data transferred
  1689. // <0x2=> 4 data transferred
  1690. // <0x3=> 8 data transferred
  1691. // <0x4=> 16 data transferred
  1692. // <i> Define the peripheral chunk size
  1693. // <id> dmac_chunksize_10
  1694. #ifndef CONF_DMAC_CHUNKSIZE_10
  1695. #define CONF_DMAC_CHUNKSIZE_10 0x0
  1696. #endif
  1697. // <o> Beat Size
  1698. // <0=> 8-bit bus transfer
  1699. // <1=> 16-bit bus transfer
  1700. // <2=> 32-bit bus transfer
  1701. // <i> Defines the size of one beat
  1702. // <id> dmac_beatsize_10
  1703. #ifndef CONF_DMAC_BEATSIZE_10
  1704. #define CONF_DMAC_BEATSIZE_10 0x0
  1705. #endif
  1706. // <o> Source Interface Identifier
  1707. // <0x0=> AHB_IF0
  1708. // <0x1=> AHB_IF1
  1709. // <i> Define the data is read through the system bus interface 0 or 1
  1710. // <id> dma_src_interface_10
  1711. #ifndef CONF_DMAC_SRC_INTERFACE_10
  1712. #define CONF_DMAC_SRC_INTERFACE_10 0x0
  1713. #endif
  1714. // <o> Destination Interface Identifier
  1715. // <0x0=> AHB_IF0
  1716. // <0x1=> AHB_IF1
  1717. // <i> Define the data is written through the system bus interface 0 or 1
  1718. // <id> dma_des_interface_10
  1719. #ifndef CONF_DMAC_DES_INTERFACE_10
  1720. #define CONF_DMAC_DES_INTERFACE_10 0x0
  1721. #endif
  1722. // <q> Source Address Increment
  1723. // <i> Indicates whether the source address incremented as beat size or not
  1724. // <id> dmac_srcinc_10
  1725. #ifndef CONF_DMAC_SRCINC_10
  1726. #define CONF_DMAC_SRCINC_10 0
  1727. #endif
  1728. // <q> Destination Address Increment
  1729. // <i> Indicates whether the destination address incremented as beat size or not
  1730. // <id> dmac_dstinc_10
  1731. #ifndef CONF_DMAC_DSTINC_10
  1732. #define CONF_DMAC_DSTINC_10 0
  1733. #endif
  1734. // <o> Transfer Type
  1735. // <0x0=> Memory to Memory Transfer
  1736. // <0x1=> Peripheral to Memory Transfer
  1737. // <0x2=> Memory to Peripheral Transfer
  1738. // <i> Define the data transfer type
  1739. // <id> dma_trans_type_10
  1740. #ifndef CONF_DMAC_TRANS_TYPE_10
  1741. #define CONF_DMAC_TRANS_TYPE_10 0x0
  1742. #endif
  1743. // <o> Trigger source
  1744. // <0xFF=> Software Trigger
  1745. // <0x00=> HSMCI TX/RX Trigger
  1746. // <0x01=> SPI0 TX Trigger
  1747. // <0x02=> SPI0 RX Trigger
  1748. // <0x03=> SPI1 TX Trigger
  1749. // <0x04=> SPI1 RX Trigger
  1750. // <0x05=> QSPI TX Trigger
  1751. // <0x06=> QSPI RX Trigger
  1752. // <0x07=> USART0 TX Trigger
  1753. // <0x08=> USART0 RX Trigger
  1754. // <0x09=> USART1 TX Trigger
  1755. // <0x0A=> USART1 RX Trigger
  1756. // <0x0B=> USART2 TX Trigger
  1757. // <0x0C=> USART2 RX Trigger
  1758. // <0x0D=> PWM0 TX Trigger
  1759. // <0x0E=> TWIHS0 TX Trigger
  1760. // <0x0F=> TWIHS0 RX Trigger
  1761. // <0x10=> TWIHS1 TX Trigger
  1762. // <0x11=> TWIHS1 RX Trigger
  1763. // <0x12=> TWIHS2 TX Trigger
  1764. // <0x13=> TWIHS2 RX Trigger
  1765. // <0x14=> UART0 TX Trigger
  1766. // <0x15=> UART0 RX Trigger
  1767. // <0x16=> UART1 TX Trigger
  1768. // <0x17=> UART1 RX Trigger
  1769. // <0x18=> UART2 TX Trigger
  1770. // <0x19=> UART2 RX Trigger
  1771. // <0x1A=> UART3 TX Trigger
  1772. // <0x1B=> UART3 RX Trigger
  1773. // <0x1C=> UART4 TX Trigger
  1774. // <0x1D=> UART4 RX Trigger
  1775. // <0x1E=> DACC TX Trigger
  1776. // <0x20=> SSC TX Trigger
  1777. // <0x21=> SSC RX Trigger
  1778. // <0x22=> PIOA RX Trigger
  1779. // <0x23=> AFEC0 RX Trigger
  1780. // <0x24=> AFEC1 RX Trigger
  1781. // <0x25=> AES TX Trigger
  1782. // <0x26=> AES RX Trigger
  1783. // <0x27=> PWM1 TX Trigger
  1784. // <0x28=> TC0 RX Trigger
  1785. // <0x29=> TC3 RX Trigger
  1786. // <0x2A=> TC6 RX Trigger
  1787. // <0x2B=> TC9 RX Trigger
  1788. // <0x2C=> I2SC0 TX Left Trigger
  1789. // <0x2D=> I2SC0 RX Left Trigger
  1790. // <0x2E=> I2SC1 TX Left Trigger
  1791. // <0x2F=> I2SC1 RX Left Trigger
  1792. // <0x30=> I2SC0 TX Right Trigger
  1793. // <0x31=> I2SC0 RX Right Trigger
  1794. // <0x32=> I2SC1 TX Right Trigger
  1795. // <0x33=> I2SC1 RX Right Trigger
  1796. // <i> Define the DMA trigger source
  1797. // <id> dmac_trifsrc_10
  1798. #ifndef CONF_DMAC_TRIGSRC_10
  1799. #define CONF_DMAC_TRIGSRC_10 0xff
  1800. #endif
  1801. // </e>
  1802. #if CONF_DMAC_TRANS_TYPE_10 == 0
  1803. #define CONF_DMAC_TYPE_10 0
  1804. #define CONF_DMAC_DSYNC_10 0
  1805. #elif CONF_DMAC_TRANS_TYPE_10 == 1
  1806. #define CONF_DMAC_TYPE_10 1
  1807. #define CONF_DMAC_DSYNC_10 0
  1808. #elif CONF_DMAC_TRANS_TYPE_10 == 2
  1809. #define CONF_DMAC_TYPE_10 1
  1810. #define CONF_DMAC_DSYNC_10 1
  1811. #endif
  1812. #if CONF_DMAC_TRIGSRC_10 == 0xFF
  1813. #define CONF_DMAC_SWREQ_10 1
  1814. #else
  1815. #define CONF_DMAC_SWREQ_10 0
  1816. #endif
  1817. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1818. * or fixed destination address mode, source and destination addresses are incremented
  1819. * by 8-bit or 16-bit.
  1820. * Workaround: The user can fix the problem by setting the source addressing mode to
  1821. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1822. */
  1823. #if (CONF_DMAC_CHANNEL_10_SETTINGS == 1 && CONF_DMAC_BEATSIZE_10 != 2 \
  1824. && ((!CONF_DMAC_SRCINC_10) || (!CONF_DMAC_DSTINC_10)))
  1825. #if (!CONF_DMAC_SRCINC_10)
  1826. #define CONF_DMAC_SRC_STRIDE_10 ((int16_t)(-1))
  1827. #endif
  1828. #if (!CONF_DMAC_DSTINC_10)
  1829. #define CONF_DMAC_DES_STRIDE_10 ((int16_t)(-1))
  1830. #endif
  1831. #endif
  1832. #ifndef CONF_DMAC_SRC_STRIDE_10
  1833. #define CONF_DMAC_SRC_STRIDE_10 0
  1834. #endif
  1835. #ifndef CONF_DMAC_DES_STRIDE_10
  1836. #define CONF_DMAC_DES_STRIDE_10 0
  1837. #endif
  1838. // <e> Channel 11 settings
  1839. // <id> dmac_channel_11_settings
  1840. #ifndef CONF_DMAC_CHANNEL_11_SETTINGS
  1841. #define CONF_DMAC_CHANNEL_11_SETTINGS 0
  1842. #endif
  1843. // <o> Burst Size
  1844. // <0x0=> 1 burst size
  1845. // <0x1=> 4 burst size
  1846. // <0x2=> 8 burst size
  1847. // <0x3=> 16 burst size
  1848. // <i> Define the memory burst size
  1849. // <id> dmac_burstsize_11
  1850. #ifndef CONF_DMAC_BURSTSIZE_11
  1851. #define CONF_DMAC_BURSTSIZE_11 0x0
  1852. #endif
  1853. // <o> Chunk Size
  1854. // <0x0=> 1 data transferred
  1855. // <0x1=> 2 data transferred
  1856. // <0x2=> 4 data transferred
  1857. // <0x3=> 8 data transferred
  1858. // <0x4=> 16 data transferred
  1859. // <i> Define the peripheral chunk size
  1860. // <id> dmac_chunksize_11
  1861. #ifndef CONF_DMAC_CHUNKSIZE_11
  1862. #define CONF_DMAC_CHUNKSIZE_11 0x0
  1863. #endif
  1864. // <o> Beat Size
  1865. // <0=> 8-bit bus transfer
  1866. // <1=> 16-bit bus transfer
  1867. // <2=> 32-bit bus transfer
  1868. // <i> Defines the size of one beat
  1869. // <id> dmac_beatsize_11
  1870. #ifndef CONF_DMAC_BEATSIZE_11
  1871. #define CONF_DMAC_BEATSIZE_11 0x0
  1872. #endif
  1873. // <o> Source Interface Identifier
  1874. // <0x0=> AHB_IF0
  1875. // <0x1=> AHB_IF1
  1876. // <i> Define the data is read through the system bus interface 0 or 1
  1877. // <id> dma_src_interface_11
  1878. #ifndef CONF_DMAC_SRC_INTERFACE_11
  1879. #define CONF_DMAC_SRC_INTERFACE_11 0x0
  1880. #endif
  1881. // <o> Destination Interface Identifier
  1882. // <0x0=> AHB_IF0
  1883. // <0x1=> AHB_IF1
  1884. // <i> Define the data is written through the system bus interface 0 or 1
  1885. // <id> dma_des_interface_11
  1886. #ifndef CONF_DMAC_DES_INTERFACE_11
  1887. #define CONF_DMAC_DES_INTERFACE_11 0x0
  1888. #endif
  1889. // <q> Source Address Increment
  1890. // <i> Indicates whether the source address incremented as beat size or not
  1891. // <id> dmac_srcinc_11
  1892. #ifndef CONF_DMAC_SRCINC_11
  1893. #define CONF_DMAC_SRCINC_11 0
  1894. #endif
  1895. // <q> Destination Address Increment
  1896. // <i> Indicates whether the destination address incremented as beat size or not
  1897. // <id> dmac_dstinc_11
  1898. #ifndef CONF_DMAC_DSTINC_11
  1899. #define CONF_DMAC_DSTINC_11 0
  1900. #endif
  1901. // <o> Transfer Type
  1902. // <0x0=> Memory to Memory Transfer
  1903. // <0x1=> Peripheral to Memory Transfer
  1904. // <0x2=> Memory to Peripheral Transfer
  1905. // <i> Define the data transfer type
  1906. // <id> dma_trans_type_11
  1907. #ifndef CONF_DMAC_TRANS_TYPE_11
  1908. #define CONF_DMAC_TRANS_TYPE_11 0x0
  1909. #endif
  1910. // <o> Trigger source
  1911. // <0xFF=> Software Trigger
  1912. // <0x00=> HSMCI TX/RX Trigger
  1913. // <0x01=> SPI0 TX Trigger
  1914. // <0x02=> SPI0 RX Trigger
  1915. // <0x03=> SPI1 TX Trigger
  1916. // <0x04=> SPI1 RX Trigger
  1917. // <0x05=> QSPI TX Trigger
  1918. // <0x06=> QSPI RX Trigger
  1919. // <0x07=> USART0 TX Trigger
  1920. // <0x08=> USART0 RX Trigger
  1921. // <0x09=> USART1 TX Trigger
  1922. // <0x0A=> USART1 RX Trigger
  1923. // <0x0B=> USART2 TX Trigger
  1924. // <0x0C=> USART2 RX Trigger
  1925. // <0x0D=> PWM0 TX Trigger
  1926. // <0x0E=> TWIHS0 TX Trigger
  1927. // <0x0F=> TWIHS0 RX Trigger
  1928. // <0x10=> TWIHS1 TX Trigger
  1929. // <0x11=> TWIHS1 RX Trigger
  1930. // <0x12=> TWIHS2 TX Trigger
  1931. // <0x13=> TWIHS2 RX Trigger
  1932. // <0x14=> UART0 TX Trigger
  1933. // <0x15=> UART0 RX Trigger
  1934. // <0x16=> UART1 TX Trigger
  1935. // <0x17=> UART1 RX Trigger
  1936. // <0x18=> UART2 TX Trigger
  1937. // <0x19=> UART2 RX Trigger
  1938. // <0x1A=> UART3 TX Trigger
  1939. // <0x1B=> UART3 RX Trigger
  1940. // <0x1C=> UART4 TX Trigger
  1941. // <0x1D=> UART4 RX Trigger
  1942. // <0x1E=> DACC TX Trigger
  1943. // <0x20=> SSC TX Trigger
  1944. // <0x21=> SSC RX Trigger
  1945. // <0x22=> PIOA RX Trigger
  1946. // <0x23=> AFEC0 RX Trigger
  1947. // <0x24=> AFEC1 RX Trigger
  1948. // <0x25=> AES TX Trigger
  1949. // <0x26=> AES RX Trigger
  1950. // <0x27=> PWM1 TX Trigger
  1951. // <0x28=> TC0 RX Trigger
  1952. // <0x29=> TC3 RX Trigger
  1953. // <0x2A=> TC6 RX Trigger
  1954. // <0x2B=> TC9 RX Trigger
  1955. // <0x2C=> I2SC0 TX Left Trigger
  1956. // <0x2D=> I2SC0 RX Left Trigger
  1957. // <0x2E=> I2SC1 TX Left Trigger
  1958. // <0x2F=> I2SC1 RX Left Trigger
  1959. // <0x30=> I2SC0 TX Right Trigger
  1960. // <0x31=> I2SC0 RX Right Trigger
  1961. // <0x32=> I2SC1 TX Right Trigger
  1962. // <0x33=> I2SC1 RX Right Trigger
  1963. // <i> Define the DMA trigger source
  1964. // <id> dmac_trifsrc_11
  1965. #ifndef CONF_DMAC_TRIGSRC_11
  1966. #define CONF_DMAC_TRIGSRC_11 0xff
  1967. #endif
  1968. // </e>
  1969. #if CONF_DMAC_TRANS_TYPE_11 == 0
  1970. #define CONF_DMAC_TYPE_11 0
  1971. #define CONF_DMAC_DSYNC_11 0
  1972. #elif CONF_DMAC_TRANS_TYPE_11 == 1
  1973. #define CONF_DMAC_TYPE_11 1
  1974. #define CONF_DMAC_DSYNC_11 0
  1975. #elif CONF_DMAC_TRANS_TYPE_11 == 2
  1976. #define CONF_DMAC_TYPE_11 1
  1977. #define CONF_DMAC_DSYNC_11 1
  1978. #endif
  1979. #if CONF_DMAC_TRIGSRC_11 == 0xFF
  1980. #define CONF_DMAC_SWREQ_11 1
  1981. #else
  1982. #define CONF_DMAC_SWREQ_11 0
  1983. #endif
  1984. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  1985. * or fixed destination address mode, source and destination addresses are incremented
  1986. * by 8-bit or 16-bit.
  1987. * Workaround: The user can fix the problem by setting the source addressing mode to
  1988. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  1989. */
  1990. #if (CONF_DMAC_CHANNEL_11_SETTINGS == 1 && CONF_DMAC_BEATSIZE_11 != 2 \
  1991. && ((!CONF_DMAC_SRCINC_11) || (!CONF_DMAC_DSTINC_11)))
  1992. #if (!CONF_DMAC_SRCINC_11)
  1993. #define CONF_DMAC_SRC_STRIDE_11 ((int16_t)(-1))
  1994. #endif
  1995. #if (!CONF_DMAC_DSTINC_11)
  1996. #define CONF_DMAC_DES_STRIDE_11 ((int16_t)(-1))
  1997. #endif
  1998. #endif
  1999. #ifndef CONF_DMAC_SRC_STRIDE_11
  2000. #define CONF_DMAC_SRC_STRIDE_11 0
  2001. #endif
  2002. #ifndef CONF_DMAC_DES_STRIDE_11
  2003. #define CONF_DMAC_DES_STRIDE_11 0
  2004. #endif
  2005. // <e> Channel 12 settings
  2006. // <id> dmac_channel_12_settings
  2007. #ifndef CONF_DMAC_CHANNEL_12_SETTINGS
  2008. #define CONF_DMAC_CHANNEL_12_SETTINGS 0
  2009. #endif
  2010. // <o> Burst Size
  2011. // <0x0=> 1 burst size
  2012. // <0x1=> 4 burst size
  2013. // <0x2=> 8 burst size
  2014. // <0x3=> 16 burst size
  2015. // <i> Define the memory burst size
  2016. // <id> dmac_burstsize_12
  2017. #ifndef CONF_DMAC_BURSTSIZE_12
  2018. #define CONF_DMAC_BURSTSIZE_12 0x0
  2019. #endif
  2020. // <o> Chunk Size
  2021. // <0x0=> 1 data transferred
  2022. // <0x1=> 2 data transferred
  2023. // <0x2=> 4 data transferred
  2024. // <0x3=> 8 data transferred
  2025. // <0x4=> 16 data transferred
  2026. // <i> Define the peripheral chunk size
  2027. // <id> dmac_chunksize_12
  2028. #ifndef CONF_DMAC_CHUNKSIZE_12
  2029. #define CONF_DMAC_CHUNKSIZE_12 0x0
  2030. #endif
  2031. // <o> Beat Size
  2032. // <0=> 8-bit bus transfer
  2033. // <1=> 16-bit bus transfer
  2034. // <2=> 32-bit bus transfer
  2035. // <i> Defines the size of one beat
  2036. // <id> dmac_beatsize_12
  2037. #ifndef CONF_DMAC_BEATSIZE_12
  2038. #define CONF_DMAC_BEATSIZE_12 0x0
  2039. #endif
  2040. // <o> Source Interface Identifier
  2041. // <0x0=> AHB_IF0
  2042. // <0x1=> AHB_IF1
  2043. // <i> Define the data is read through the system bus interface 0 or 1
  2044. // <id> dma_src_interface_12
  2045. #ifndef CONF_DMAC_SRC_INTERFACE_12
  2046. #define CONF_DMAC_SRC_INTERFACE_12 0x0
  2047. #endif
  2048. // <o> Destination Interface Identifier
  2049. // <0x0=> AHB_IF0
  2050. // <0x1=> AHB_IF1
  2051. // <i> Define the data is written through the system bus interface 0 or 1
  2052. // <id> dma_des_interface_12
  2053. #ifndef CONF_DMAC_DES_INTERFACE_12
  2054. #define CONF_DMAC_DES_INTERFACE_12 0x0
  2055. #endif
  2056. // <q> Source Address Increment
  2057. // <i> Indicates whether the source address incremented as beat size or not
  2058. // <id> dmac_srcinc_12
  2059. #ifndef CONF_DMAC_SRCINC_12
  2060. #define CONF_DMAC_SRCINC_12 0
  2061. #endif
  2062. // <q> Destination Address Increment
  2063. // <i> Indicates whether the destination address incremented as beat size or not
  2064. // <id> dmac_dstinc_12
  2065. #ifndef CONF_DMAC_DSTINC_12
  2066. #define CONF_DMAC_DSTINC_12 0
  2067. #endif
  2068. // <o> Transfer Type
  2069. // <0x0=> Memory to Memory Transfer
  2070. // <0x1=> Peripheral to Memory Transfer
  2071. // <0x2=> Memory to Peripheral Transfer
  2072. // <i> Define the data transfer type
  2073. // <id> dma_trans_type_12
  2074. #ifndef CONF_DMAC_TRANS_TYPE_12
  2075. #define CONF_DMAC_TRANS_TYPE_12 0x0
  2076. #endif
  2077. // <o> Trigger source
  2078. // <0xFF=> Software Trigger
  2079. // <0x00=> HSMCI TX/RX Trigger
  2080. // <0x01=> SPI0 TX Trigger
  2081. // <0x02=> SPI0 RX Trigger
  2082. // <0x03=> SPI1 TX Trigger
  2083. // <0x04=> SPI1 RX Trigger
  2084. // <0x05=> QSPI TX Trigger
  2085. // <0x06=> QSPI RX Trigger
  2086. // <0x07=> USART0 TX Trigger
  2087. // <0x08=> USART0 RX Trigger
  2088. // <0x09=> USART1 TX Trigger
  2089. // <0x0A=> USART1 RX Trigger
  2090. // <0x0B=> USART2 TX Trigger
  2091. // <0x0C=> USART2 RX Trigger
  2092. // <0x0D=> PWM0 TX Trigger
  2093. // <0x0E=> TWIHS0 TX Trigger
  2094. // <0x0F=> TWIHS0 RX Trigger
  2095. // <0x10=> TWIHS1 TX Trigger
  2096. // <0x11=> TWIHS1 RX Trigger
  2097. // <0x12=> TWIHS2 TX Trigger
  2098. // <0x13=> TWIHS2 RX Trigger
  2099. // <0x14=> UART0 TX Trigger
  2100. // <0x15=> UART0 RX Trigger
  2101. // <0x16=> UART1 TX Trigger
  2102. // <0x17=> UART1 RX Trigger
  2103. // <0x18=> UART2 TX Trigger
  2104. // <0x19=> UART2 RX Trigger
  2105. // <0x1A=> UART3 TX Trigger
  2106. // <0x1B=> UART3 RX Trigger
  2107. // <0x1C=> UART4 TX Trigger
  2108. // <0x1D=> UART4 RX Trigger
  2109. // <0x1E=> DACC TX Trigger
  2110. // <0x20=> SSC TX Trigger
  2111. // <0x21=> SSC RX Trigger
  2112. // <0x22=> PIOA RX Trigger
  2113. // <0x23=> AFEC0 RX Trigger
  2114. // <0x24=> AFEC1 RX Trigger
  2115. // <0x25=> AES TX Trigger
  2116. // <0x26=> AES RX Trigger
  2117. // <0x27=> PWM1 TX Trigger
  2118. // <0x28=> TC0 RX Trigger
  2119. // <0x29=> TC3 RX Trigger
  2120. // <0x2A=> TC6 RX Trigger
  2121. // <0x2B=> TC9 RX Trigger
  2122. // <0x2C=> I2SC0 TX Left Trigger
  2123. // <0x2D=> I2SC0 RX Left Trigger
  2124. // <0x2E=> I2SC1 TX Left Trigger
  2125. // <0x2F=> I2SC1 RX Left Trigger
  2126. // <0x30=> I2SC0 TX Right Trigger
  2127. // <0x31=> I2SC0 RX Right Trigger
  2128. // <0x32=> I2SC1 TX Right Trigger
  2129. // <0x33=> I2SC1 RX Right Trigger
  2130. // <i> Define the DMA trigger source
  2131. // <id> dmac_trifsrc_12
  2132. #ifndef CONF_DMAC_TRIGSRC_12
  2133. #define CONF_DMAC_TRIGSRC_12 0xff
  2134. #endif
  2135. // </e>
  2136. #if CONF_DMAC_TRANS_TYPE_12 == 0
  2137. #define CONF_DMAC_TYPE_12 0
  2138. #define CONF_DMAC_DSYNC_12 0
  2139. #elif CONF_DMAC_TRANS_TYPE_12 == 1
  2140. #define CONF_DMAC_TYPE_12 1
  2141. #define CONF_DMAC_DSYNC_12 0
  2142. #elif CONF_DMAC_TRANS_TYPE_12 == 2
  2143. #define CONF_DMAC_TYPE_12 1
  2144. #define CONF_DMAC_DSYNC_12 1
  2145. #endif
  2146. #if CONF_DMAC_TRIGSRC_12 == 0xFF
  2147. #define CONF_DMAC_SWREQ_12 1
  2148. #else
  2149. #define CONF_DMAC_SWREQ_12 0
  2150. #endif
  2151. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2152. * or fixed destination address mode, source and destination addresses are incremented
  2153. * by 8-bit or 16-bit.
  2154. * Workaround: The user can fix the problem by setting the source addressing mode to
  2155. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2156. */
  2157. #if (CONF_DMAC_CHANNEL_12_SETTINGS == 1 && CONF_DMAC_BEATSIZE_12 != 2 \
  2158. && ((!CONF_DMAC_SRCINC_12) || (!CONF_DMAC_DSTINC_12)))
  2159. #if (!CONF_DMAC_SRCINC_12)
  2160. #define CONF_DMAC_SRC_STRIDE_12 ((int16_t)(-1))
  2161. #endif
  2162. #if (!CONF_DMAC_DSTINC_12)
  2163. #define CONF_DMAC_DES_STRIDE_12 ((int16_t)(-1))
  2164. #endif
  2165. #endif
  2166. #ifndef CONF_DMAC_SRC_STRIDE_12
  2167. #define CONF_DMAC_SRC_STRIDE_12 0
  2168. #endif
  2169. #ifndef CONF_DMAC_DES_STRIDE_12
  2170. #define CONF_DMAC_DES_STRIDE_12 0
  2171. #endif
  2172. // <e> Channel 13 settings
  2173. // <id> dmac_channel_13_settings
  2174. #ifndef CONF_DMAC_CHANNEL_13_SETTINGS
  2175. #define CONF_DMAC_CHANNEL_13_SETTINGS 0
  2176. #endif
  2177. // <o> Burst Size
  2178. // <0x0=> 1 burst size
  2179. // <0x1=> 4 burst size
  2180. // <0x2=> 8 burst size
  2181. // <0x3=> 16 burst size
  2182. // <i> Define the memory burst size
  2183. // <id> dmac_burstsize_13
  2184. #ifndef CONF_DMAC_BURSTSIZE_13
  2185. #define CONF_DMAC_BURSTSIZE_13 0x0
  2186. #endif
  2187. // <o> Chunk Size
  2188. // <0x0=> 1 data transferred
  2189. // <0x1=> 2 data transferred
  2190. // <0x2=> 4 data transferred
  2191. // <0x3=> 8 data transferred
  2192. // <0x4=> 16 data transferred
  2193. // <i> Define the peripheral chunk size
  2194. // <id> dmac_chunksize_13
  2195. #ifndef CONF_DMAC_CHUNKSIZE_13
  2196. #define CONF_DMAC_CHUNKSIZE_13 0x0
  2197. #endif
  2198. // <o> Beat Size
  2199. // <0=> 8-bit bus transfer
  2200. // <1=> 16-bit bus transfer
  2201. // <2=> 32-bit bus transfer
  2202. // <i> Defines the size of one beat
  2203. // <id> dmac_beatsize_13
  2204. #ifndef CONF_DMAC_BEATSIZE_13
  2205. #define CONF_DMAC_BEATSIZE_13 0x0
  2206. #endif
  2207. // <o> Source Interface Identifier
  2208. // <0x0=> AHB_IF0
  2209. // <0x1=> AHB_IF1
  2210. // <i> Define the data is read through the system bus interface 0 or 1
  2211. // <id> dma_src_interface_13
  2212. #ifndef CONF_DMAC_SRC_INTERFACE_13
  2213. #define CONF_DMAC_SRC_INTERFACE_13 0x0
  2214. #endif
  2215. // <o> Destination Interface Identifier
  2216. // <0x0=> AHB_IF0
  2217. // <0x1=> AHB_IF1
  2218. // <i> Define the data is written through the system bus interface 0 or 1
  2219. // <id> dma_des_interface_13
  2220. #ifndef CONF_DMAC_DES_INTERFACE_13
  2221. #define CONF_DMAC_DES_INTERFACE_13 0x0
  2222. #endif
  2223. // <q> Source Address Increment
  2224. // <i> Indicates whether the source address incremented as beat size or not
  2225. // <id> dmac_srcinc_13
  2226. #ifndef CONF_DMAC_SRCINC_13
  2227. #define CONF_DMAC_SRCINC_13 0
  2228. #endif
  2229. // <q> Destination Address Increment
  2230. // <i> Indicates whether the destination address incremented as beat size or not
  2231. // <id> dmac_dstinc_13
  2232. #ifndef CONF_DMAC_DSTINC_13
  2233. #define CONF_DMAC_DSTINC_13 0
  2234. #endif
  2235. // <o> Transfer Type
  2236. // <0x0=> Memory to Memory Transfer
  2237. // <0x1=> Peripheral to Memory Transfer
  2238. // <0x2=> Memory to Peripheral Transfer
  2239. // <i> Define the data transfer type
  2240. // <id> dma_trans_type_13
  2241. #ifndef CONF_DMAC_TRANS_TYPE_13
  2242. #define CONF_DMAC_TRANS_TYPE_13 0x0
  2243. #endif
  2244. // <o> Trigger source
  2245. // <0xFF=> Software Trigger
  2246. // <0x00=> HSMCI TX/RX Trigger
  2247. // <0x01=> SPI0 TX Trigger
  2248. // <0x02=> SPI0 RX Trigger
  2249. // <0x03=> SPI1 TX Trigger
  2250. // <0x04=> SPI1 RX Trigger
  2251. // <0x05=> QSPI TX Trigger
  2252. // <0x06=> QSPI RX Trigger
  2253. // <0x07=> USART0 TX Trigger
  2254. // <0x08=> USART0 RX Trigger
  2255. // <0x09=> USART1 TX Trigger
  2256. // <0x0A=> USART1 RX Trigger
  2257. // <0x0B=> USART2 TX Trigger
  2258. // <0x0C=> USART2 RX Trigger
  2259. // <0x0D=> PWM0 TX Trigger
  2260. // <0x0E=> TWIHS0 TX Trigger
  2261. // <0x0F=> TWIHS0 RX Trigger
  2262. // <0x10=> TWIHS1 TX Trigger
  2263. // <0x11=> TWIHS1 RX Trigger
  2264. // <0x12=> TWIHS2 TX Trigger
  2265. // <0x13=> TWIHS2 RX Trigger
  2266. // <0x14=> UART0 TX Trigger
  2267. // <0x15=> UART0 RX Trigger
  2268. // <0x16=> UART1 TX Trigger
  2269. // <0x17=> UART1 RX Trigger
  2270. // <0x18=> UART2 TX Trigger
  2271. // <0x19=> UART2 RX Trigger
  2272. // <0x1A=> UART3 TX Trigger
  2273. // <0x1B=> UART3 RX Trigger
  2274. // <0x1C=> UART4 TX Trigger
  2275. // <0x1D=> UART4 RX Trigger
  2276. // <0x1E=> DACC TX Trigger
  2277. // <0x20=> SSC TX Trigger
  2278. // <0x21=> SSC RX Trigger
  2279. // <0x22=> PIOA RX Trigger
  2280. // <0x23=> AFEC0 RX Trigger
  2281. // <0x24=> AFEC1 RX Trigger
  2282. // <0x25=> AES TX Trigger
  2283. // <0x26=> AES RX Trigger
  2284. // <0x27=> PWM1 TX Trigger
  2285. // <0x28=> TC0 RX Trigger
  2286. // <0x29=> TC3 RX Trigger
  2287. // <0x2A=> TC6 RX Trigger
  2288. // <0x2B=> TC9 RX Trigger
  2289. // <0x2C=> I2SC0 TX Left Trigger
  2290. // <0x2D=> I2SC0 RX Left Trigger
  2291. // <0x2E=> I2SC1 TX Left Trigger
  2292. // <0x2F=> I2SC1 RX Left Trigger
  2293. // <0x30=> I2SC0 TX Right Trigger
  2294. // <0x31=> I2SC0 RX Right Trigger
  2295. // <0x32=> I2SC1 TX Right Trigger
  2296. // <0x33=> I2SC1 RX Right Trigger
  2297. // <i> Define the DMA trigger source
  2298. // <id> dmac_trifsrc_13
  2299. #ifndef CONF_DMAC_TRIGSRC_13
  2300. #define CONF_DMAC_TRIGSRC_13 0xff
  2301. #endif
  2302. // </e>
  2303. #if CONF_DMAC_TRANS_TYPE_13 == 0
  2304. #define CONF_DMAC_TYPE_13 0
  2305. #define CONF_DMAC_DSYNC_13 0
  2306. #elif CONF_DMAC_TRANS_TYPE_13 == 1
  2307. #define CONF_DMAC_TYPE_13 1
  2308. #define CONF_DMAC_DSYNC_13 0
  2309. #elif CONF_DMAC_TRANS_TYPE_13 == 2
  2310. #define CONF_DMAC_TYPE_13 1
  2311. #define CONF_DMAC_DSYNC_13 1
  2312. #endif
  2313. #if CONF_DMAC_TRIGSRC_13 == 0xFF
  2314. #define CONF_DMAC_SWREQ_13 1
  2315. #else
  2316. #define CONF_DMAC_SWREQ_13 0
  2317. #endif
  2318. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2319. * or fixed destination address mode, source and destination addresses are incremented
  2320. * by 8-bit or 16-bit.
  2321. * Workaround: The user can fix the problem by setting the source addressing mode to
  2322. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2323. */
  2324. #if (CONF_DMAC_CHANNEL_13_SETTINGS == 1 && CONF_DMAC_BEATSIZE_13 != 2 \
  2325. && ((!CONF_DMAC_SRCINC_13) || (!CONF_DMAC_DSTINC_13)))
  2326. #if (!CONF_DMAC_SRCINC_13)
  2327. #define CONF_DMAC_SRC_STRIDE_13 ((int16_t)(-1))
  2328. #endif
  2329. #if (!CONF_DMAC_DSTINC_13)
  2330. #define CONF_DMAC_DES_STRIDE_13 ((int16_t)(-1))
  2331. #endif
  2332. #endif
  2333. #ifndef CONF_DMAC_SRC_STRIDE_13
  2334. #define CONF_DMAC_SRC_STRIDE_13 0
  2335. #endif
  2336. #ifndef CONF_DMAC_DES_STRIDE_13
  2337. #define CONF_DMAC_DES_STRIDE_13 0
  2338. #endif
  2339. // <e> Channel 14 settings
  2340. // <id> dmac_channel_14_settings
  2341. #ifndef CONF_DMAC_CHANNEL_14_SETTINGS
  2342. #define CONF_DMAC_CHANNEL_14_SETTINGS 0
  2343. #endif
  2344. // <o> Burst Size
  2345. // <0x0=> 1 burst size
  2346. // <0x1=> 4 burst size
  2347. // <0x2=> 8 burst size
  2348. // <0x3=> 16 burst size
  2349. // <i> Define the memory burst size
  2350. // <id> dmac_burstsize_14
  2351. #ifndef CONF_DMAC_BURSTSIZE_14
  2352. #define CONF_DMAC_BURSTSIZE_14 0x0
  2353. #endif
  2354. // <o> Chunk Size
  2355. // <0x0=> 1 data transferred
  2356. // <0x1=> 2 data transferred
  2357. // <0x2=> 4 data transferred
  2358. // <0x3=> 8 data transferred
  2359. // <0x4=> 16 data transferred
  2360. // <i> Define the peripheral chunk size
  2361. // <id> dmac_chunksize_14
  2362. #ifndef CONF_DMAC_CHUNKSIZE_14
  2363. #define CONF_DMAC_CHUNKSIZE_14 0x0
  2364. #endif
  2365. // <o> Beat Size
  2366. // <0=> 8-bit bus transfer
  2367. // <1=> 16-bit bus transfer
  2368. // <2=> 32-bit bus transfer
  2369. // <i> Defines the size of one beat
  2370. // <id> dmac_beatsize_14
  2371. #ifndef CONF_DMAC_BEATSIZE_14
  2372. #define CONF_DMAC_BEATSIZE_14 0x0
  2373. #endif
  2374. // <o> Source Interface Identifier
  2375. // <0x0=> AHB_IF0
  2376. // <0x1=> AHB_IF1
  2377. // <i> Define the data is read through the system bus interface 0 or 1
  2378. // <id> dma_src_interface_14
  2379. #ifndef CONF_DMAC_SRC_INTERFACE_14
  2380. #define CONF_DMAC_SRC_INTERFACE_14 0x0
  2381. #endif
  2382. // <o> Destination Interface Identifier
  2383. // <0x0=> AHB_IF0
  2384. // <0x1=> AHB_IF1
  2385. // <i> Define the data is written through the system bus interface 0 or 1
  2386. // <id> dma_des_interface_14
  2387. #ifndef CONF_DMAC_DES_INTERFACE_14
  2388. #define CONF_DMAC_DES_INTERFACE_14 0x0
  2389. #endif
  2390. // <q> Source Address Increment
  2391. // <i> Indicates whether the source address incremented as beat size or not
  2392. // <id> dmac_srcinc_14
  2393. #ifndef CONF_DMAC_SRCINC_14
  2394. #define CONF_DMAC_SRCINC_14 0
  2395. #endif
  2396. // <q> Destination Address Increment
  2397. // <i> Indicates whether the destination address incremented as beat size or not
  2398. // <id> dmac_dstinc_14
  2399. #ifndef CONF_DMAC_DSTINC_14
  2400. #define CONF_DMAC_DSTINC_14 0
  2401. #endif
  2402. // <o> Transfer Type
  2403. // <0x0=> Memory to Memory Transfer
  2404. // <0x1=> Peripheral to Memory Transfer
  2405. // <0x2=> Memory to Peripheral Transfer
  2406. // <i> Define the data transfer type
  2407. // <id> dma_trans_type_14
  2408. #ifndef CONF_DMAC_TRANS_TYPE_14
  2409. #define CONF_DMAC_TRANS_TYPE_14 0x0
  2410. #endif
  2411. // <o> Trigger source
  2412. // <0xFF=> Software Trigger
  2413. // <0x00=> HSMCI TX/RX Trigger
  2414. // <0x01=> SPI0 TX Trigger
  2415. // <0x02=> SPI0 RX Trigger
  2416. // <0x03=> SPI1 TX Trigger
  2417. // <0x04=> SPI1 RX Trigger
  2418. // <0x05=> QSPI TX Trigger
  2419. // <0x06=> QSPI RX Trigger
  2420. // <0x07=> USART0 TX Trigger
  2421. // <0x08=> USART0 RX Trigger
  2422. // <0x09=> USART1 TX Trigger
  2423. // <0x0A=> USART1 RX Trigger
  2424. // <0x0B=> USART2 TX Trigger
  2425. // <0x0C=> USART2 RX Trigger
  2426. // <0x0D=> PWM0 TX Trigger
  2427. // <0x0E=> TWIHS0 TX Trigger
  2428. // <0x0F=> TWIHS0 RX Trigger
  2429. // <0x10=> TWIHS1 TX Trigger
  2430. // <0x11=> TWIHS1 RX Trigger
  2431. // <0x12=> TWIHS2 TX Trigger
  2432. // <0x13=> TWIHS2 RX Trigger
  2433. // <0x14=> UART0 TX Trigger
  2434. // <0x15=> UART0 RX Trigger
  2435. // <0x16=> UART1 TX Trigger
  2436. // <0x17=> UART1 RX Trigger
  2437. // <0x18=> UART2 TX Trigger
  2438. // <0x19=> UART2 RX Trigger
  2439. // <0x1A=> UART3 TX Trigger
  2440. // <0x1B=> UART3 RX Trigger
  2441. // <0x1C=> UART4 TX Trigger
  2442. // <0x1D=> UART4 RX Trigger
  2443. // <0x1E=> DACC TX Trigger
  2444. // <0x20=> SSC TX Trigger
  2445. // <0x21=> SSC RX Trigger
  2446. // <0x22=> PIOA RX Trigger
  2447. // <0x23=> AFEC0 RX Trigger
  2448. // <0x24=> AFEC1 RX Trigger
  2449. // <0x25=> AES TX Trigger
  2450. // <0x26=> AES RX Trigger
  2451. // <0x27=> PWM1 TX Trigger
  2452. // <0x28=> TC0 RX Trigger
  2453. // <0x29=> TC3 RX Trigger
  2454. // <0x2A=> TC6 RX Trigger
  2455. // <0x2B=> TC9 RX Trigger
  2456. // <0x2C=> I2SC0 TX Left Trigger
  2457. // <0x2D=> I2SC0 RX Left Trigger
  2458. // <0x2E=> I2SC1 TX Left Trigger
  2459. // <0x2F=> I2SC1 RX Left Trigger
  2460. // <0x30=> I2SC0 TX Right Trigger
  2461. // <0x31=> I2SC0 RX Right Trigger
  2462. // <0x32=> I2SC1 TX Right Trigger
  2463. // <0x33=> I2SC1 RX Right Trigger
  2464. // <i> Define the DMA trigger source
  2465. // <id> dmac_trifsrc_14
  2466. #ifndef CONF_DMAC_TRIGSRC_14
  2467. #define CONF_DMAC_TRIGSRC_14 0xff
  2468. #endif
  2469. // </e>
  2470. #if CONF_DMAC_TRANS_TYPE_14 == 0
  2471. #define CONF_DMAC_TYPE_14 0
  2472. #define CONF_DMAC_DSYNC_14 0
  2473. #elif CONF_DMAC_TRANS_TYPE_14 == 1
  2474. #define CONF_DMAC_TYPE_14 1
  2475. #define CONF_DMAC_DSYNC_14 0
  2476. #elif CONF_DMAC_TRANS_TYPE_14 == 2
  2477. #define CONF_DMAC_TYPE_14 1
  2478. #define CONF_DMAC_DSYNC_14 1
  2479. #endif
  2480. #if CONF_DMAC_TRIGSRC_14 == 0xFF
  2481. #define CONF_DMAC_SWREQ_14 1
  2482. #else
  2483. #define CONF_DMAC_SWREQ_14 0
  2484. #endif
  2485. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2486. * or fixed destination address mode, source and destination addresses are incremented
  2487. * by 8-bit or 16-bit.
  2488. * Workaround: The user can fix the problem by setting the source addressing mode to
  2489. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2490. */
  2491. #if (CONF_DMAC_CHANNEL_14_SETTINGS == 1 && CONF_DMAC_BEATSIZE_14 != 2 \
  2492. && ((!CONF_DMAC_SRCINC_14) || (!CONF_DMAC_DSTINC_14)))
  2493. #if (!CONF_DMAC_SRCINC_14)
  2494. #define CONF_DMAC_SRC_STRIDE_14 ((int16_t)(-1))
  2495. #endif
  2496. #if (!CONF_DMAC_DSTINC_14)
  2497. #define CONF_DMAC_DES_STRIDE_14 ((int16_t)(-1))
  2498. #endif
  2499. #endif
  2500. #ifndef CONF_DMAC_SRC_STRIDE_14
  2501. #define CONF_DMAC_SRC_STRIDE_14 0
  2502. #endif
  2503. #ifndef CONF_DMAC_DES_STRIDE_14
  2504. #define CONF_DMAC_DES_STRIDE_14 0
  2505. #endif
  2506. // <e> Channel 15 settings
  2507. // <id> dmac_channel_15_settings
  2508. #ifndef CONF_DMAC_CHANNEL_15_SETTINGS
  2509. #define CONF_DMAC_CHANNEL_15_SETTINGS 0
  2510. #endif
  2511. // <o> Burst Size
  2512. // <0x0=> 1 burst size
  2513. // <0x1=> 4 burst size
  2514. // <0x2=> 8 burst size
  2515. // <0x3=> 16 burst size
  2516. // <i> Define the memory burst size
  2517. // <id> dmac_burstsize_15
  2518. #ifndef CONF_DMAC_BURSTSIZE_15
  2519. #define CONF_DMAC_BURSTSIZE_15 0x0
  2520. #endif
  2521. // <o> Chunk Size
  2522. // <0x0=> 1 data transferred
  2523. // <0x1=> 2 data transferred
  2524. // <0x2=> 4 data transferred
  2525. // <0x3=> 8 data transferred
  2526. // <0x4=> 16 data transferred
  2527. // <i> Define the peripheral chunk size
  2528. // <id> dmac_chunksize_15
  2529. #ifndef CONF_DMAC_CHUNKSIZE_15
  2530. #define CONF_DMAC_CHUNKSIZE_15 0x0
  2531. #endif
  2532. // <o> Beat Size
  2533. // <0=> 8-bit bus transfer
  2534. // <1=> 16-bit bus transfer
  2535. // <2=> 32-bit bus transfer
  2536. // <i> Defines the size of one beat
  2537. // <id> dmac_beatsize_15
  2538. #ifndef CONF_DMAC_BEATSIZE_15
  2539. #define CONF_DMAC_BEATSIZE_15 0x0
  2540. #endif
  2541. // <o> Source Interface Identifier
  2542. // <0x0=> AHB_IF0
  2543. // <0x1=> AHB_IF1
  2544. // <i> Define the data is read through the system bus interface 0 or 1
  2545. // <id> dma_src_interface_15
  2546. #ifndef CONF_DMAC_SRC_INTERFACE_15
  2547. #define CONF_DMAC_SRC_INTERFACE_15 0x0
  2548. #endif
  2549. // <o> Destination Interface Identifier
  2550. // <0x0=> AHB_IF0
  2551. // <0x1=> AHB_IF1
  2552. // <i> Define the data is written through the system bus interface 0 or 1
  2553. // <id> dma_des_interface_15
  2554. #ifndef CONF_DMAC_DES_INTERFACE_15
  2555. #define CONF_DMAC_DES_INTERFACE_15 0x0
  2556. #endif
  2557. // <q> Source Address Increment
  2558. // <i> Indicates whether the source address incremented as beat size or not
  2559. // <id> dmac_srcinc_15
  2560. #ifndef CONF_DMAC_SRCINC_15
  2561. #define CONF_DMAC_SRCINC_15 0
  2562. #endif
  2563. // <q> Destination Address Increment
  2564. // <i> Indicates whether the destination address incremented as beat size or not
  2565. // <id> dmac_dstinc_15
  2566. #ifndef CONF_DMAC_DSTINC_15
  2567. #define CONF_DMAC_DSTINC_15 0
  2568. #endif
  2569. // <o> Transfer Type
  2570. // <0x0=> Memory to Memory Transfer
  2571. // <0x1=> Peripheral to Memory Transfer
  2572. // <0x2=> Memory to Peripheral Transfer
  2573. // <i> Define the data transfer type
  2574. // <id> dma_trans_type_15
  2575. #ifndef CONF_DMAC_TRANS_TYPE_15
  2576. #define CONF_DMAC_TRANS_TYPE_15 0x0
  2577. #endif
  2578. // <o> Trigger source
  2579. // <0xFF=> Software Trigger
  2580. // <0x00=> HSMCI TX/RX Trigger
  2581. // <0x01=> SPI0 TX Trigger
  2582. // <0x02=> SPI0 RX Trigger
  2583. // <0x03=> SPI1 TX Trigger
  2584. // <0x04=> SPI1 RX Trigger
  2585. // <0x05=> QSPI TX Trigger
  2586. // <0x06=> QSPI RX Trigger
  2587. // <0x07=> USART0 TX Trigger
  2588. // <0x08=> USART0 RX Trigger
  2589. // <0x09=> USART1 TX Trigger
  2590. // <0x0A=> USART1 RX Trigger
  2591. // <0x0B=> USART2 TX Trigger
  2592. // <0x0C=> USART2 RX Trigger
  2593. // <0x0D=> PWM0 TX Trigger
  2594. // <0x0E=> TWIHS0 TX Trigger
  2595. // <0x0F=> TWIHS0 RX Trigger
  2596. // <0x10=> TWIHS1 TX Trigger
  2597. // <0x11=> TWIHS1 RX Trigger
  2598. // <0x12=> TWIHS2 TX Trigger
  2599. // <0x13=> TWIHS2 RX Trigger
  2600. // <0x14=> UART0 TX Trigger
  2601. // <0x15=> UART0 RX Trigger
  2602. // <0x16=> UART1 TX Trigger
  2603. // <0x17=> UART1 RX Trigger
  2604. // <0x18=> UART2 TX Trigger
  2605. // <0x19=> UART2 RX Trigger
  2606. // <0x1A=> UART3 TX Trigger
  2607. // <0x1B=> UART3 RX Trigger
  2608. // <0x1C=> UART4 TX Trigger
  2609. // <0x1D=> UART4 RX Trigger
  2610. // <0x1E=> DACC TX Trigger
  2611. // <0x20=> SSC TX Trigger
  2612. // <0x21=> SSC RX Trigger
  2613. // <0x22=> PIOA RX Trigger
  2614. // <0x23=> AFEC0 RX Trigger
  2615. // <0x24=> AFEC1 RX Trigger
  2616. // <0x25=> AES TX Trigger
  2617. // <0x26=> AES RX Trigger
  2618. // <0x27=> PWM1 TX Trigger
  2619. // <0x28=> TC0 RX Trigger
  2620. // <0x29=> TC3 RX Trigger
  2621. // <0x2A=> TC6 RX Trigger
  2622. // <0x2B=> TC9 RX Trigger
  2623. // <0x2C=> I2SC0 TX Left Trigger
  2624. // <0x2D=> I2SC0 RX Left Trigger
  2625. // <0x2E=> I2SC1 TX Left Trigger
  2626. // <0x2F=> I2SC1 RX Left Trigger
  2627. // <0x30=> I2SC0 TX Right Trigger
  2628. // <0x31=> I2SC0 RX Right Trigger
  2629. // <0x32=> I2SC1 TX Right Trigger
  2630. // <0x33=> I2SC1 RX Right Trigger
  2631. // <i> Define the DMA trigger source
  2632. // <id> dmac_trifsrc_15
  2633. #ifndef CONF_DMAC_TRIGSRC_15
  2634. #define CONF_DMAC_TRIGSRC_15 0xff
  2635. #endif
  2636. // </e>
  2637. #if CONF_DMAC_TRANS_TYPE_15 == 0
  2638. #define CONF_DMAC_TYPE_15 0
  2639. #define CONF_DMAC_DSYNC_15 0
  2640. #elif CONF_DMAC_TRANS_TYPE_15 == 1
  2641. #define CONF_DMAC_TYPE_15 1
  2642. #define CONF_DMAC_DSYNC_15 0
  2643. #elif CONF_DMAC_TRANS_TYPE_15 == 2
  2644. #define CONF_DMAC_TYPE_15 1
  2645. #define CONF_DMAC_DSYNC_15 1
  2646. #endif
  2647. #if CONF_DMAC_TRIGSRC_15 == 0xFF
  2648. #define CONF_DMAC_SWREQ_15 1
  2649. #else
  2650. #define CONF_DMAC_SWREQ_15 0
  2651. #endif
  2652. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2653. * or fixed destination address mode, source and destination addresses are incremented
  2654. * by 8-bit or 16-bit.
  2655. * Workaround: The user can fix the problem by setting the source addressing mode to
  2656. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2657. */
  2658. #if (CONF_DMAC_CHANNEL_15_SETTINGS == 1 && CONF_DMAC_BEATSIZE_15 != 2 \
  2659. && ((!CONF_DMAC_SRCINC_15) || (!CONF_DMAC_DSTINC_15)))
  2660. #if (!CONF_DMAC_SRCINC_15)
  2661. #define CONF_DMAC_SRC_STRIDE_15 ((int16_t)(-1))
  2662. #endif
  2663. #if (!CONF_DMAC_DSTINC_15)
  2664. #define CONF_DMAC_DES_STRIDE_15 ((int16_t)(-1))
  2665. #endif
  2666. #endif
  2667. #ifndef CONF_DMAC_SRC_STRIDE_15
  2668. #define CONF_DMAC_SRC_STRIDE_15 0
  2669. #endif
  2670. #ifndef CONF_DMAC_DES_STRIDE_15
  2671. #define CONF_DMAC_DES_STRIDE_15 0
  2672. #endif
  2673. // <e> Channel 16 settings
  2674. // <id> dmac_channel_16_settings
  2675. #ifndef CONF_DMAC_CHANNEL_16_SETTINGS
  2676. #define CONF_DMAC_CHANNEL_16_SETTINGS 0
  2677. #endif
  2678. // <o> Burst Size
  2679. // <0x0=> 1 burst size
  2680. // <0x1=> 4 burst size
  2681. // <0x2=> 8 burst size
  2682. // <0x3=> 16 burst size
  2683. // <i> Define the memory burst size
  2684. // <id> dmac_burstsize_16
  2685. #ifndef CONF_DMAC_BURSTSIZE_16
  2686. #define CONF_DMAC_BURSTSIZE_16 0x0
  2687. #endif
  2688. // <o> Chunk Size
  2689. // <0x0=> 1 data transferred
  2690. // <0x1=> 2 data transferred
  2691. // <0x2=> 4 data transferred
  2692. // <0x3=> 8 data transferred
  2693. // <0x4=> 16 data transferred
  2694. // <i> Define the peripheral chunk size
  2695. // <id> dmac_chunksize_16
  2696. #ifndef CONF_DMAC_CHUNKSIZE_16
  2697. #define CONF_DMAC_CHUNKSIZE_16 0x0
  2698. #endif
  2699. // <o> Beat Size
  2700. // <0=> 8-bit bus transfer
  2701. // <1=> 16-bit bus transfer
  2702. // <2=> 32-bit bus transfer
  2703. // <i> Defines the size of one beat
  2704. // <id> dmac_beatsize_16
  2705. #ifndef CONF_DMAC_BEATSIZE_16
  2706. #define CONF_DMAC_BEATSIZE_16 0x0
  2707. #endif
  2708. // <o> Source Interface Identifier
  2709. // <0x0=> AHB_IF0
  2710. // <0x1=> AHB_IF1
  2711. // <i> Define the data is read through the system bus interface 0 or 1
  2712. // <id> dma_src_interface_16
  2713. #ifndef CONF_DMAC_SRC_INTERFACE_16
  2714. #define CONF_DMAC_SRC_INTERFACE_16 0x0
  2715. #endif
  2716. // <o> Destination Interface Identifier
  2717. // <0x0=> AHB_IF0
  2718. // <0x1=> AHB_IF1
  2719. // <i> Define the data is written through the system bus interface 0 or 1
  2720. // <id> dma_des_interface_16
  2721. #ifndef CONF_DMAC_DES_INTERFACE_16
  2722. #define CONF_DMAC_DES_INTERFACE_16 0x0
  2723. #endif
  2724. // <q> Source Address Increment
  2725. // <i> Indicates whether the source address incremented as beat size or not
  2726. // <id> dmac_srcinc_16
  2727. #ifndef CONF_DMAC_SRCINC_16
  2728. #define CONF_DMAC_SRCINC_16 0
  2729. #endif
  2730. // <q> Destination Address Increment
  2731. // <i> Indicates whether the destination address incremented as beat size or not
  2732. // <id> dmac_dstinc_16
  2733. #ifndef CONF_DMAC_DSTINC_16
  2734. #define CONF_DMAC_DSTINC_16 0
  2735. #endif
  2736. // <o> Transfer Type
  2737. // <0x0=> Memory to Memory Transfer
  2738. // <0x1=> Peripheral to Memory Transfer
  2739. // <0x2=> Memory to Peripheral Transfer
  2740. // <i> Define the data transfer type
  2741. // <id> dma_trans_type_16
  2742. #ifndef CONF_DMAC_TRANS_TYPE_16
  2743. #define CONF_DMAC_TRANS_TYPE_16 0x0
  2744. #endif
  2745. // <o> Trigger source
  2746. // <0xFF=> Software Trigger
  2747. // <0x00=> HSMCI TX/RX Trigger
  2748. // <0x01=> SPI0 TX Trigger
  2749. // <0x02=> SPI0 RX Trigger
  2750. // <0x03=> SPI1 TX Trigger
  2751. // <0x04=> SPI1 RX Trigger
  2752. // <0x05=> QSPI TX Trigger
  2753. // <0x06=> QSPI RX Trigger
  2754. // <0x07=> USART0 TX Trigger
  2755. // <0x08=> USART0 RX Trigger
  2756. // <0x09=> USART1 TX Trigger
  2757. // <0x0A=> USART1 RX Trigger
  2758. // <0x0B=> USART2 TX Trigger
  2759. // <0x0C=> USART2 RX Trigger
  2760. // <0x0D=> PWM0 TX Trigger
  2761. // <0x0E=> TWIHS0 TX Trigger
  2762. // <0x0F=> TWIHS0 RX Trigger
  2763. // <0x10=> TWIHS1 TX Trigger
  2764. // <0x11=> TWIHS1 RX Trigger
  2765. // <0x12=> TWIHS2 TX Trigger
  2766. // <0x13=> TWIHS2 RX Trigger
  2767. // <0x14=> UART0 TX Trigger
  2768. // <0x15=> UART0 RX Trigger
  2769. // <0x16=> UART1 TX Trigger
  2770. // <0x17=> UART1 RX Trigger
  2771. // <0x18=> UART2 TX Trigger
  2772. // <0x19=> UART2 RX Trigger
  2773. // <0x1A=> UART3 TX Trigger
  2774. // <0x1B=> UART3 RX Trigger
  2775. // <0x1C=> UART4 TX Trigger
  2776. // <0x1D=> UART4 RX Trigger
  2777. // <0x1E=> DACC TX Trigger
  2778. // <0x20=> SSC TX Trigger
  2779. // <0x21=> SSC RX Trigger
  2780. // <0x22=> PIOA RX Trigger
  2781. // <0x23=> AFEC0 RX Trigger
  2782. // <0x24=> AFEC1 RX Trigger
  2783. // <0x25=> AES TX Trigger
  2784. // <0x26=> AES RX Trigger
  2785. // <0x27=> PWM1 TX Trigger
  2786. // <0x28=> TC0 RX Trigger
  2787. // <0x29=> TC3 RX Trigger
  2788. // <0x2A=> TC6 RX Trigger
  2789. // <0x2B=> TC9 RX Trigger
  2790. // <0x2C=> I2SC0 TX Left Trigger
  2791. // <0x2D=> I2SC0 RX Left Trigger
  2792. // <0x2E=> I2SC1 TX Left Trigger
  2793. // <0x2F=> I2SC1 RX Left Trigger
  2794. // <0x30=> I2SC0 TX Right Trigger
  2795. // <0x31=> I2SC0 RX Right Trigger
  2796. // <0x32=> I2SC1 TX Right Trigger
  2797. // <0x33=> I2SC1 RX Right Trigger
  2798. // <i> Define the DMA trigger source
  2799. // <id> dmac_trifsrc_16
  2800. #ifndef CONF_DMAC_TRIGSRC_16
  2801. #define CONF_DMAC_TRIGSRC_16 0xff
  2802. #endif
  2803. // </e>
  2804. #if CONF_DMAC_TRANS_TYPE_16 == 0
  2805. #define CONF_DMAC_TYPE_16 0
  2806. #define CONF_DMAC_DSYNC_16 0
  2807. #elif CONF_DMAC_TRANS_TYPE_16 == 1
  2808. #define CONF_DMAC_TYPE_16 1
  2809. #define CONF_DMAC_DSYNC_16 0
  2810. #elif CONF_DMAC_TRANS_TYPE_16 == 2
  2811. #define CONF_DMAC_TYPE_16 1
  2812. #define CONF_DMAC_DSYNC_16 1
  2813. #endif
  2814. #if CONF_DMAC_TRIGSRC_16 == 0xFF
  2815. #define CONF_DMAC_SWREQ_16 1
  2816. #else
  2817. #define CONF_DMAC_SWREQ_16 0
  2818. #endif
  2819. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2820. * or fixed destination address mode, source and destination addresses are incremented
  2821. * by 8-bit or 16-bit.
  2822. * Workaround: The user can fix the problem by setting the source addressing mode to
  2823. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2824. */
  2825. #if (CONF_DMAC_CHANNEL_16_SETTINGS == 1 && CONF_DMAC_BEATSIZE_16 != 2 \
  2826. && ((!CONF_DMAC_SRCINC_16) || (!CONF_DMAC_DSTINC_16)))
  2827. #if (!CONF_DMAC_SRCINC_16)
  2828. #define CONF_DMAC_SRC_STRIDE_16 ((int16_t)(-1))
  2829. #endif
  2830. #if (!CONF_DMAC_DSTINC_16)
  2831. #define CONF_DMAC_DES_STRIDE_16 ((int16_t)(-1))
  2832. #endif
  2833. #endif
  2834. #ifndef CONF_DMAC_SRC_STRIDE_16
  2835. #define CONF_DMAC_SRC_STRIDE_16 0
  2836. #endif
  2837. #ifndef CONF_DMAC_DES_STRIDE_16
  2838. #define CONF_DMAC_DES_STRIDE_16 0
  2839. #endif
  2840. // <e> Channel 17 settings
  2841. // <id> dmac_channel_17_settings
  2842. #ifndef CONF_DMAC_CHANNEL_17_SETTINGS
  2843. #define CONF_DMAC_CHANNEL_17_SETTINGS 0
  2844. #endif
  2845. // <o> Burst Size
  2846. // <0x0=> 1 burst size
  2847. // <0x1=> 4 burst size
  2848. // <0x2=> 8 burst size
  2849. // <0x3=> 16 burst size
  2850. // <i> Define the memory burst size
  2851. // <id> dmac_burstsize_17
  2852. #ifndef CONF_DMAC_BURSTSIZE_17
  2853. #define CONF_DMAC_BURSTSIZE_17 0x0
  2854. #endif
  2855. // <o> Chunk Size
  2856. // <0x0=> 1 data transferred
  2857. // <0x1=> 2 data transferred
  2858. // <0x2=> 4 data transferred
  2859. // <0x3=> 8 data transferred
  2860. // <0x4=> 16 data transferred
  2861. // <i> Define the peripheral chunk size
  2862. // <id> dmac_chunksize_17
  2863. #ifndef CONF_DMAC_CHUNKSIZE_17
  2864. #define CONF_DMAC_CHUNKSIZE_17 0x0
  2865. #endif
  2866. // <o> Beat Size
  2867. // <0=> 8-bit bus transfer
  2868. // <1=> 16-bit bus transfer
  2869. // <2=> 32-bit bus transfer
  2870. // <i> Defines the size of one beat
  2871. // <id> dmac_beatsize_17
  2872. #ifndef CONF_DMAC_BEATSIZE_17
  2873. #define CONF_DMAC_BEATSIZE_17 0x0
  2874. #endif
  2875. // <o> Source Interface Identifier
  2876. // <0x0=> AHB_IF0
  2877. // <0x1=> AHB_IF1
  2878. // <i> Define the data is read through the system bus interface 0 or 1
  2879. // <id> dma_src_interface_17
  2880. #ifndef CONF_DMAC_SRC_INTERFACE_17
  2881. #define CONF_DMAC_SRC_INTERFACE_17 0x0
  2882. #endif
  2883. // <o> Destination Interface Identifier
  2884. // <0x0=> AHB_IF0
  2885. // <0x1=> AHB_IF1
  2886. // <i> Define the data is written through the system bus interface 0 or 1
  2887. // <id> dma_des_interface_17
  2888. #ifndef CONF_DMAC_DES_INTERFACE_17
  2889. #define CONF_DMAC_DES_INTERFACE_17 0x0
  2890. #endif
  2891. // <q> Source Address Increment
  2892. // <i> Indicates whether the source address incremented as beat size or not
  2893. // <id> dmac_srcinc_17
  2894. #ifndef CONF_DMAC_SRCINC_17
  2895. #define CONF_DMAC_SRCINC_17 0
  2896. #endif
  2897. // <q> Destination Address Increment
  2898. // <i> Indicates whether the destination address incremented as beat size or not
  2899. // <id> dmac_dstinc_17
  2900. #ifndef CONF_DMAC_DSTINC_17
  2901. #define CONF_DMAC_DSTINC_17 0
  2902. #endif
  2903. // <o> Transfer Type
  2904. // <0x0=> Memory to Memory Transfer
  2905. // <0x1=> Peripheral to Memory Transfer
  2906. // <0x2=> Memory to Peripheral Transfer
  2907. // <i> Define the data transfer type
  2908. // <id> dma_trans_type_17
  2909. #ifndef CONF_DMAC_TRANS_TYPE_17
  2910. #define CONF_DMAC_TRANS_TYPE_17 0x0
  2911. #endif
  2912. // <o> Trigger source
  2913. // <0xFF=> Software Trigger
  2914. // <0x00=> HSMCI TX/RX Trigger
  2915. // <0x01=> SPI0 TX Trigger
  2916. // <0x02=> SPI0 RX Trigger
  2917. // <0x03=> SPI1 TX Trigger
  2918. // <0x04=> SPI1 RX Trigger
  2919. // <0x05=> QSPI TX Trigger
  2920. // <0x06=> QSPI RX Trigger
  2921. // <0x07=> USART0 TX Trigger
  2922. // <0x08=> USART0 RX Trigger
  2923. // <0x09=> USART1 TX Trigger
  2924. // <0x0A=> USART1 RX Trigger
  2925. // <0x0B=> USART2 TX Trigger
  2926. // <0x0C=> USART2 RX Trigger
  2927. // <0x0D=> PWM0 TX Trigger
  2928. // <0x0E=> TWIHS0 TX Trigger
  2929. // <0x0F=> TWIHS0 RX Trigger
  2930. // <0x10=> TWIHS1 TX Trigger
  2931. // <0x11=> TWIHS1 RX Trigger
  2932. // <0x12=> TWIHS2 TX Trigger
  2933. // <0x13=> TWIHS2 RX Trigger
  2934. // <0x14=> UART0 TX Trigger
  2935. // <0x15=> UART0 RX Trigger
  2936. // <0x16=> UART1 TX Trigger
  2937. // <0x17=> UART1 RX Trigger
  2938. // <0x18=> UART2 TX Trigger
  2939. // <0x19=> UART2 RX Trigger
  2940. // <0x1A=> UART3 TX Trigger
  2941. // <0x1B=> UART3 RX Trigger
  2942. // <0x1C=> UART4 TX Trigger
  2943. // <0x1D=> UART4 RX Trigger
  2944. // <0x1E=> DACC TX Trigger
  2945. // <0x20=> SSC TX Trigger
  2946. // <0x21=> SSC RX Trigger
  2947. // <0x22=> PIOA RX Trigger
  2948. // <0x23=> AFEC0 RX Trigger
  2949. // <0x24=> AFEC1 RX Trigger
  2950. // <0x25=> AES TX Trigger
  2951. // <0x26=> AES RX Trigger
  2952. // <0x27=> PWM1 TX Trigger
  2953. // <0x28=> TC0 RX Trigger
  2954. // <0x29=> TC3 RX Trigger
  2955. // <0x2A=> TC6 RX Trigger
  2956. // <0x2B=> TC9 RX Trigger
  2957. // <0x2C=> I2SC0 TX Left Trigger
  2958. // <0x2D=> I2SC0 RX Left Trigger
  2959. // <0x2E=> I2SC1 TX Left Trigger
  2960. // <0x2F=> I2SC1 RX Left Trigger
  2961. // <0x30=> I2SC0 TX Right Trigger
  2962. // <0x31=> I2SC0 RX Right Trigger
  2963. // <0x32=> I2SC1 TX Right Trigger
  2964. // <0x33=> I2SC1 RX Right Trigger
  2965. // <i> Define the DMA trigger source
  2966. // <id> dmac_trifsrc_17
  2967. #ifndef CONF_DMAC_TRIGSRC_17
  2968. #define CONF_DMAC_TRIGSRC_17 0xff
  2969. #endif
  2970. // </e>
  2971. #if CONF_DMAC_TRANS_TYPE_17 == 0
  2972. #define CONF_DMAC_TYPE_17 0
  2973. #define CONF_DMAC_DSYNC_17 0
  2974. #elif CONF_DMAC_TRANS_TYPE_17 == 1
  2975. #define CONF_DMAC_TYPE_17 1
  2976. #define CONF_DMAC_DSYNC_17 0
  2977. #elif CONF_DMAC_TRANS_TYPE_17 == 2
  2978. #define CONF_DMAC_TYPE_17 1
  2979. #define CONF_DMAC_DSYNC_17 1
  2980. #endif
  2981. #if CONF_DMAC_TRIGSRC_17 == 0xFF
  2982. #define CONF_DMAC_SWREQ_17 1
  2983. #else
  2984. #define CONF_DMAC_SWREQ_17 0
  2985. #endif
  2986. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  2987. * or fixed destination address mode, source and destination addresses are incremented
  2988. * by 8-bit or 16-bit.
  2989. * Workaround: The user can fix the problem by setting the source addressing mode to
  2990. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  2991. */
  2992. #if (CONF_DMAC_CHANNEL_17_SETTINGS == 1 && CONF_DMAC_BEATSIZE_17 != 2 \
  2993. && ((!CONF_DMAC_SRCINC_17) || (!CONF_DMAC_DSTINC_17)))
  2994. #if (!CONF_DMAC_SRCINC_17)
  2995. #define CONF_DMAC_SRC_STRIDE_17 ((int16_t)(-1))
  2996. #endif
  2997. #if (!CONF_DMAC_DSTINC_17)
  2998. #define CONF_DMAC_DES_STRIDE_17 ((int16_t)(-1))
  2999. #endif
  3000. #endif
  3001. #ifndef CONF_DMAC_SRC_STRIDE_17
  3002. #define CONF_DMAC_SRC_STRIDE_17 0
  3003. #endif
  3004. #ifndef CONF_DMAC_DES_STRIDE_17
  3005. #define CONF_DMAC_DES_STRIDE_17 0
  3006. #endif
  3007. // <e> Channel 18 settings
  3008. // <id> dmac_channel_18_settings
  3009. #ifndef CONF_DMAC_CHANNEL_18_SETTINGS
  3010. #define CONF_DMAC_CHANNEL_18_SETTINGS 0
  3011. #endif
  3012. // <o> Burst Size
  3013. // <0x0=> 1 burst size
  3014. // <0x1=> 4 burst size
  3015. // <0x2=> 8 burst size
  3016. // <0x3=> 16 burst size
  3017. // <i> Define the memory burst size
  3018. // <id> dmac_burstsize_18
  3019. #ifndef CONF_DMAC_BURSTSIZE_18
  3020. #define CONF_DMAC_BURSTSIZE_18 0x0
  3021. #endif
  3022. // <o> Chunk Size
  3023. // <0x0=> 1 data transferred
  3024. // <0x1=> 2 data transferred
  3025. // <0x2=> 4 data transferred
  3026. // <0x3=> 8 data transferred
  3027. // <0x4=> 16 data transferred
  3028. // <i> Define the peripheral chunk size
  3029. // <id> dmac_chunksize_18
  3030. #ifndef CONF_DMAC_CHUNKSIZE_18
  3031. #define CONF_DMAC_CHUNKSIZE_18 0x0
  3032. #endif
  3033. // <o> Beat Size
  3034. // <0=> 8-bit bus transfer
  3035. // <1=> 16-bit bus transfer
  3036. // <2=> 32-bit bus transfer
  3037. // <i> Defines the size of one beat
  3038. // <id> dmac_beatsize_18
  3039. #ifndef CONF_DMAC_BEATSIZE_18
  3040. #define CONF_DMAC_BEATSIZE_18 0x0
  3041. #endif
  3042. // <o> Source Interface Identifier
  3043. // <0x0=> AHB_IF0
  3044. // <0x1=> AHB_IF1
  3045. // <i> Define the data is read through the system bus interface 0 or 1
  3046. // <id> dma_src_interface_18
  3047. #ifndef CONF_DMAC_SRC_INTERFACE_18
  3048. #define CONF_DMAC_SRC_INTERFACE_18 0x0
  3049. #endif
  3050. // <o> Destination Interface Identifier
  3051. // <0x0=> AHB_IF0
  3052. // <0x1=> AHB_IF1
  3053. // <i> Define the data is written through the system bus interface 0 or 1
  3054. // <id> dma_des_interface_18
  3055. #ifndef CONF_DMAC_DES_INTERFACE_18
  3056. #define CONF_DMAC_DES_INTERFACE_18 0x0
  3057. #endif
  3058. // <q> Source Address Increment
  3059. // <i> Indicates whether the source address incremented as beat size or not
  3060. // <id> dmac_srcinc_18
  3061. #ifndef CONF_DMAC_SRCINC_18
  3062. #define CONF_DMAC_SRCINC_18 0
  3063. #endif
  3064. // <q> Destination Address Increment
  3065. // <i> Indicates whether the destination address incremented as beat size or not
  3066. // <id> dmac_dstinc_18
  3067. #ifndef CONF_DMAC_DSTINC_18
  3068. #define CONF_DMAC_DSTINC_18 0
  3069. #endif
  3070. // <o> Transfer Type
  3071. // <0x0=> Memory to Memory Transfer
  3072. // <0x1=> Peripheral to Memory Transfer
  3073. // <0x2=> Memory to Peripheral Transfer
  3074. // <i> Define the data transfer type
  3075. // <id> dma_trans_type_18
  3076. #ifndef CONF_DMAC_TRANS_TYPE_18
  3077. #define CONF_DMAC_TRANS_TYPE_18 0x0
  3078. #endif
  3079. // <o> Trigger source
  3080. // <0xFF=> Software Trigger
  3081. // <0x00=> HSMCI TX/RX Trigger
  3082. // <0x01=> SPI0 TX Trigger
  3083. // <0x02=> SPI0 RX Trigger
  3084. // <0x03=> SPI1 TX Trigger
  3085. // <0x04=> SPI1 RX Trigger
  3086. // <0x05=> QSPI TX Trigger
  3087. // <0x06=> QSPI RX Trigger
  3088. // <0x07=> USART0 TX Trigger
  3089. // <0x08=> USART0 RX Trigger
  3090. // <0x09=> USART1 TX Trigger
  3091. // <0x0A=> USART1 RX Trigger
  3092. // <0x0B=> USART2 TX Trigger
  3093. // <0x0C=> USART2 RX Trigger
  3094. // <0x0D=> PWM0 TX Trigger
  3095. // <0x0E=> TWIHS0 TX Trigger
  3096. // <0x0F=> TWIHS0 RX Trigger
  3097. // <0x10=> TWIHS1 TX Trigger
  3098. // <0x11=> TWIHS1 RX Trigger
  3099. // <0x12=> TWIHS2 TX Trigger
  3100. // <0x13=> TWIHS2 RX Trigger
  3101. // <0x14=> UART0 TX Trigger
  3102. // <0x15=> UART0 RX Trigger
  3103. // <0x16=> UART1 TX Trigger
  3104. // <0x17=> UART1 RX Trigger
  3105. // <0x18=> UART2 TX Trigger
  3106. // <0x19=> UART2 RX Trigger
  3107. // <0x1A=> UART3 TX Trigger
  3108. // <0x1B=> UART3 RX Trigger
  3109. // <0x1C=> UART4 TX Trigger
  3110. // <0x1D=> UART4 RX Trigger
  3111. // <0x1E=> DACC TX Trigger
  3112. // <0x20=> SSC TX Trigger
  3113. // <0x21=> SSC RX Trigger
  3114. // <0x22=> PIOA RX Trigger
  3115. // <0x23=> AFEC0 RX Trigger
  3116. // <0x24=> AFEC1 RX Trigger
  3117. // <0x25=> AES TX Trigger
  3118. // <0x26=> AES RX Trigger
  3119. // <0x27=> PWM1 TX Trigger
  3120. // <0x28=> TC0 RX Trigger
  3121. // <0x29=> TC3 RX Trigger
  3122. // <0x2A=> TC6 RX Trigger
  3123. // <0x2B=> TC9 RX Trigger
  3124. // <0x2C=> I2SC0 TX Left Trigger
  3125. // <0x2D=> I2SC0 RX Left Trigger
  3126. // <0x2E=> I2SC1 TX Left Trigger
  3127. // <0x2F=> I2SC1 RX Left Trigger
  3128. // <0x30=> I2SC0 TX Right Trigger
  3129. // <0x31=> I2SC0 RX Right Trigger
  3130. // <0x32=> I2SC1 TX Right Trigger
  3131. // <0x33=> I2SC1 RX Right Trigger
  3132. // <i> Define the DMA trigger source
  3133. // <id> dmac_trifsrc_18
  3134. #ifndef CONF_DMAC_TRIGSRC_18
  3135. #define CONF_DMAC_TRIGSRC_18 0xff
  3136. #endif
  3137. // </e>
  3138. #if CONF_DMAC_TRANS_TYPE_18 == 0
  3139. #define CONF_DMAC_TYPE_18 0
  3140. #define CONF_DMAC_DSYNC_18 0
  3141. #elif CONF_DMAC_TRANS_TYPE_18 == 1
  3142. #define CONF_DMAC_TYPE_18 1
  3143. #define CONF_DMAC_DSYNC_18 0
  3144. #elif CONF_DMAC_TRANS_TYPE_18 == 2
  3145. #define CONF_DMAC_TYPE_18 1
  3146. #define CONF_DMAC_DSYNC_18 1
  3147. #endif
  3148. #if CONF_DMAC_TRIGSRC_18 == 0xFF
  3149. #define CONF_DMAC_SWREQ_18 1
  3150. #else
  3151. #define CONF_DMAC_SWREQ_18 0
  3152. #endif
  3153. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3154. * or fixed destination address mode, source and destination addresses are incremented
  3155. * by 8-bit or 16-bit.
  3156. * Workaround: The user can fix the problem by setting the source addressing mode to
  3157. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3158. */
  3159. #if (CONF_DMAC_CHANNEL_18_SETTINGS == 1 && CONF_DMAC_BEATSIZE_18 != 2 \
  3160. && ((!CONF_DMAC_SRCINC_18) || (!CONF_DMAC_DSTINC_18)))
  3161. #if (!CONF_DMAC_SRCINC_18)
  3162. #define CONF_DMAC_SRC_STRIDE_18 ((int16_t)(-1))
  3163. #endif
  3164. #if (!CONF_DMAC_DSTINC_18)
  3165. #define CONF_DMAC_DES_STRIDE_18 ((int16_t)(-1))
  3166. #endif
  3167. #endif
  3168. #ifndef CONF_DMAC_SRC_STRIDE_18
  3169. #define CONF_DMAC_SRC_STRIDE_18 0
  3170. #endif
  3171. #ifndef CONF_DMAC_DES_STRIDE_18
  3172. #define CONF_DMAC_DES_STRIDE_18 0
  3173. #endif
  3174. // <e> Channel 19 settings
  3175. // <id> dmac_channel_19_settings
  3176. #ifndef CONF_DMAC_CHANNEL_19_SETTINGS
  3177. #define CONF_DMAC_CHANNEL_19_SETTINGS 0
  3178. #endif
  3179. // <o> Burst Size
  3180. // <0x0=> 1 burst size
  3181. // <0x1=> 4 burst size
  3182. // <0x2=> 8 burst size
  3183. // <0x3=> 16 burst size
  3184. // <i> Define the memory burst size
  3185. // <id> dmac_burstsize_19
  3186. #ifndef CONF_DMAC_BURSTSIZE_19
  3187. #define CONF_DMAC_BURSTSIZE_19 0x0
  3188. #endif
  3189. // <o> Chunk Size
  3190. // <0x0=> 1 data transferred
  3191. // <0x1=> 2 data transferred
  3192. // <0x2=> 4 data transferred
  3193. // <0x3=> 8 data transferred
  3194. // <0x4=> 16 data transferred
  3195. // <i> Define the peripheral chunk size
  3196. // <id> dmac_chunksize_19
  3197. #ifndef CONF_DMAC_CHUNKSIZE_19
  3198. #define CONF_DMAC_CHUNKSIZE_19 0x0
  3199. #endif
  3200. // <o> Beat Size
  3201. // <0=> 8-bit bus transfer
  3202. // <1=> 16-bit bus transfer
  3203. // <2=> 32-bit bus transfer
  3204. // <i> Defines the size of one beat
  3205. // <id> dmac_beatsize_19
  3206. #ifndef CONF_DMAC_BEATSIZE_19
  3207. #define CONF_DMAC_BEATSIZE_19 0x0
  3208. #endif
  3209. // <o> Source Interface Identifier
  3210. // <0x0=> AHB_IF0
  3211. // <0x1=> AHB_IF1
  3212. // <i> Define the data is read through the system bus interface 0 or 1
  3213. // <id> dma_src_interface_19
  3214. #ifndef CONF_DMAC_SRC_INTERFACE_19
  3215. #define CONF_DMAC_SRC_INTERFACE_19 0x0
  3216. #endif
  3217. // <o> Destination Interface Identifier
  3218. // <0x0=> AHB_IF0
  3219. // <0x1=> AHB_IF1
  3220. // <i> Define the data is written through the system bus interface 0 or 1
  3221. // <id> dma_des_interface_19
  3222. #ifndef CONF_DMAC_DES_INTERFACE_19
  3223. #define CONF_DMAC_DES_INTERFACE_19 0x0
  3224. #endif
  3225. // <q> Source Address Increment
  3226. // <i> Indicates whether the source address incremented as beat size or not
  3227. // <id> dmac_srcinc_19
  3228. #ifndef CONF_DMAC_SRCINC_19
  3229. #define CONF_DMAC_SRCINC_19 0
  3230. #endif
  3231. // <q> Destination Address Increment
  3232. // <i> Indicates whether the destination address incremented as beat size or not
  3233. // <id> dmac_dstinc_19
  3234. #ifndef CONF_DMAC_DSTINC_19
  3235. #define CONF_DMAC_DSTINC_19 0
  3236. #endif
  3237. // <o> Transfer Type
  3238. // <0x0=> Memory to Memory Transfer
  3239. // <0x1=> Peripheral to Memory Transfer
  3240. // <0x2=> Memory to Peripheral Transfer
  3241. // <i> Define the data transfer type
  3242. // <id> dma_trans_type_19
  3243. #ifndef CONF_DMAC_TRANS_TYPE_19
  3244. #define CONF_DMAC_TRANS_TYPE_19 0x0
  3245. #endif
  3246. // <o> Trigger source
  3247. // <0xFF=> Software Trigger
  3248. // <0x00=> HSMCI TX/RX Trigger
  3249. // <0x01=> SPI0 TX Trigger
  3250. // <0x02=> SPI0 RX Trigger
  3251. // <0x03=> SPI1 TX Trigger
  3252. // <0x04=> SPI1 RX Trigger
  3253. // <0x05=> QSPI TX Trigger
  3254. // <0x06=> QSPI RX Trigger
  3255. // <0x07=> USART0 TX Trigger
  3256. // <0x08=> USART0 RX Trigger
  3257. // <0x09=> USART1 TX Trigger
  3258. // <0x0A=> USART1 RX Trigger
  3259. // <0x0B=> USART2 TX Trigger
  3260. // <0x0C=> USART2 RX Trigger
  3261. // <0x0D=> PWM0 TX Trigger
  3262. // <0x0E=> TWIHS0 TX Trigger
  3263. // <0x0F=> TWIHS0 RX Trigger
  3264. // <0x10=> TWIHS1 TX Trigger
  3265. // <0x11=> TWIHS1 RX Trigger
  3266. // <0x12=> TWIHS2 TX Trigger
  3267. // <0x13=> TWIHS2 RX Trigger
  3268. // <0x14=> UART0 TX Trigger
  3269. // <0x15=> UART0 RX Trigger
  3270. // <0x16=> UART1 TX Trigger
  3271. // <0x17=> UART1 RX Trigger
  3272. // <0x18=> UART2 TX Trigger
  3273. // <0x19=> UART2 RX Trigger
  3274. // <0x1A=> UART3 TX Trigger
  3275. // <0x1B=> UART3 RX Trigger
  3276. // <0x1C=> UART4 TX Trigger
  3277. // <0x1D=> UART4 RX Trigger
  3278. // <0x1E=> DACC TX Trigger
  3279. // <0x20=> SSC TX Trigger
  3280. // <0x21=> SSC RX Trigger
  3281. // <0x22=> PIOA RX Trigger
  3282. // <0x23=> AFEC0 RX Trigger
  3283. // <0x24=> AFEC1 RX Trigger
  3284. // <0x25=> AES TX Trigger
  3285. // <0x26=> AES RX Trigger
  3286. // <0x27=> PWM1 TX Trigger
  3287. // <0x28=> TC0 RX Trigger
  3288. // <0x29=> TC3 RX Trigger
  3289. // <0x2A=> TC6 RX Trigger
  3290. // <0x2B=> TC9 RX Trigger
  3291. // <0x2C=> I2SC0 TX Left Trigger
  3292. // <0x2D=> I2SC0 RX Left Trigger
  3293. // <0x2E=> I2SC1 TX Left Trigger
  3294. // <0x2F=> I2SC1 RX Left Trigger
  3295. // <0x30=> I2SC0 TX Right Trigger
  3296. // <0x31=> I2SC0 RX Right Trigger
  3297. // <0x32=> I2SC1 TX Right Trigger
  3298. // <0x33=> I2SC1 RX Right Trigger
  3299. // <i> Define the DMA trigger source
  3300. // <id> dmac_trifsrc_19
  3301. #ifndef CONF_DMAC_TRIGSRC_19
  3302. #define CONF_DMAC_TRIGSRC_19 0xff
  3303. #endif
  3304. // </e>
  3305. #if CONF_DMAC_TRANS_TYPE_19 == 0
  3306. #define CONF_DMAC_TYPE_19 0
  3307. #define CONF_DMAC_DSYNC_19 0
  3308. #elif CONF_DMAC_TRANS_TYPE_19 == 1
  3309. #define CONF_DMAC_TYPE_19 1
  3310. #define CONF_DMAC_DSYNC_19 0
  3311. #elif CONF_DMAC_TRANS_TYPE_19 == 2
  3312. #define CONF_DMAC_TYPE_19 1
  3313. #define CONF_DMAC_DSYNC_19 1
  3314. #endif
  3315. #if CONF_DMAC_TRIGSRC_19 == 0xFF
  3316. #define CONF_DMAC_SWREQ_19 1
  3317. #else
  3318. #define CONF_DMAC_SWREQ_19 0
  3319. #endif
  3320. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3321. * or fixed destination address mode, source and destination addresses are incremented
  3322. * by 8-bit or 16-bit.
  3323. * Workaround: The user can fix the problem by setting the source addressing mode to
  3324. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3325. */
  3326. #if (CONF_DMAC_CHANNEL_19_SETTINGS == 1 && CONF_DMAC_BEATSIZE_19 != 2 \
  3327. && ((!CONF_DMAC_SRCINC_19) || (!CONF_DMAC_DSTINC_19)))
  3328. #if (!CONF_DMAC_SRCINC_19)
  3329. #define CONF_DMAC_SRC_STRIDE_19 ((int16_t)(-1))
  3330. #endif
  3331. #if (!CONF_DMAC_DSTINC_19)
  3332. #define CONF_DMAC_DES_STRIDE_19 ((int16_t)(-1))
  3333. #endif
  3334. #endif
  3335. #ifndef CONF_DMAC_SRC_STRIDE_19
  3336. #define CONF_DMAC_SRC_STRIDE_19 0
  3337. #endif
  3338. #ifndef CONF_DMAC_DES_STRIDE_19
  3339. #define CONF_DMAC_DES_STRIDE_19 0
  3340. #endif
  3341. // <e> Channel 20 settings
  3342. // <id> dmac_channel_20_settings
  3343. #ifndef CONF_DMAC_CHANNEL_20_SETTINGS
  3344. #define CONF_DMAC_CHANNEL_20_SETTINGS 0
  3345. #endif
  3346. // <o> Burst Size
  3347. // <0x0=> 1 burst size
  3348. // <0x1=> 4 burst size
  3349. // <0x2=> 8 burst size
  3350. // <0x3=> 16 burst size
  3351. // <i> Define the memory burst size
  3352. // <id> dmac_burstsize_20
  3353. #ifndef CONF_DMAC_BURSTSIZE_20
  3354. #define CONF_DMAC_BURSTSIZE_20 0x0
  3355. #endif
  3356. // <o> Chunk Size
  3357. // <0x0=> 1 data transferred
  3358. // <0x1=> 2 data transferred
  3359. // <0x2=> 4 data transferred
  3360. // <0x3=> 8 data transferred
  3361. // <0x4=> 16 data transferred
  3362. // <i> Define the peripheral chunk size
  3363. // <id> dmac_chunksize_20
  3364. #ifndef CONF_DMAC_CHUNKSIZE_20
  3365. #define CONF_DMAC_CHUNKSIZE_20 0x0
  3366. #endif
  3367. // <o> Beat Size
  3368. // <0=> 8-bit bus transfer
  3369. // <1=> 16-bit bus transfer
  3370. // <2=> 32-bit bus transfer
  3371. // <i> Defines the size of one beat
  3372. // <id> dmac_beatsize_20
  3373. #ifndef CONF_DMAC_BEATSIZE_20
  3374. #define CONF_DMAC_BEATSIZE_20 0x0
  3375. #endif
  3376. // <o> Source Interface Identifier
  3377. // <0x0=> AHB_IF0
  3378. // <0x1=> AHB_IF1
  3379. // <i> Define the data is read through the system bus interface 0 or 1
  3380. // <id> dma_src_interface_20
  3381. #ifndef CONF_DMAC_SRC_INTERFACE_20
  3382. #define CONF_DMAC_SRC_INTERFACE_20 0x0
  3383. #endif
  3384. // <o> Destination Interface Identifier
  3385. // <0x0=> AHB_IF0
  3386. // <0x1=> AHB_IF1
  3387. // <i> Define the data is written through the system bus interface 0 or 1
  3388. // <id> dma_des_interface_20
  3389. #ifndef CONF_DMAC_DES_INTERFACE_20
  3390. #define CONF_DMAC_DES_INTERFACE_20 0x0
  3391. #endif
  3392. // <q> Source Address Increment
  3393. // <i> Indicates whether the source address incremented as beat size or not
  3394. // <id> dmac_srcinc_20
  3395. #ifndef CONF_DMAC_SRCINC_20
  3396. #define CONF_DMAC_SRCINC_20 0
  3397. #endif
  3398. // <q> Destination Address Increment
  3399. // <i> Indicates whether the destination address incremented as beat size or not
  3400. // <id> dmac_dstinc_20
  3401. #ifndef CONF_DMAC_DSTINC_20
  3402. #define CONF_DMAC_DSTINC_20 0
  3403. #endif
  3404. // <o> Transfer Type
  3405. // <0x0=> Memory to Memory Transfer
  3406. // <0x1=> Peripheral to Memory Transfer
  3407. // <0x2=> Memory to Peripheral Transfer
  3408. // <i> Define the data transfer type
  3409. // <id> dma_trans_type_20
  3410. #ifndef CONF_DMAC_TRANS_TYPE_20
  3411. #define CONF_DMAC_TRANS_TYPE_20 0x0
  3412. #endif
  3413. // <o> Trigger source
  3414. // <0xFF=> Software Trigger
  3415. // <0x00=> HSMCI TX/RX Trigger
  3416. // <0x01=> SPI0 TX Trigger
  3417. // <0x02=> SPI0 RX Trigger
  3418. // <0x03=> SPI1 TX Trigger
  3419. // <0x04=> SPI1 RX Trigger
  3420. // <0x05=> QSPI TX Trigger
  3421. // <0x06=> QSPI RX Trigger
  3422. // <0x07=> USART0 TX Trigger
  3423. // <0x08=> USART0 RX Trigger
  3424. // <0x09=> USART1 TX Trigger
  3425. // <0x0A=> USART1 RX Trigger
  3426. // <0x0B=> USART2 TX Trigger
  3427. // <0x0C=> USART2 RX Trigger
  3428. // <0x0D=> PWM0 TX Trigger
  3429. // <0x0E=> TWIHS0 TX Trigger
  3430. // <0x0F=> TWIHS0 RX Trigger
  3431. // <0x10=> TWIHS1 TX Trigger
  3432. // <0x11=> TWIHS1 RX Trigger
  3433. // <0x12=> TWIHS2 TX Trigger
  3434. // <0x13=> TWIHS2 RX Trigger
  3435. // <0x14=> UART0 TX Trigger
  3436. // <0x15=> UART0 RX Trigger
  3437. // <0x16=> UART1 TX Trigger
  3438. // <0x17=> UART1 RX Trigger
  3439. // <0x18=> UART2 TX Trigger
  3440. // <0x19=> UART2 RX Trigger
  3441. // <0x1A=> UART3 TX Trigger
  3442. // <0x1B=> UART3 RX Trigger
  3443. // <0x1C=> UART4 TX Trigger
  3444. // <0x1D=> UART4 RX Trigger
  3445. // <0x1E=> DACC TX Trigger
  3446. // <0x20=> SSC TX Trigger
  3447. // <0x21=> SSC RX Trigger
  3448. // <0x22=> PIOA RX Trigger
  3449. // <0x23=> AFEC0 RX Trigger
  3450. // <0x24=> AFEC1 RX Trigger
  3451. // <0x25=> AES TX Trigger
  3452. // <0x26=> AES RX Trigger
  3453. // <0x27=> PWM1 TX Trigger
  3454. // <0x28=> TC0 RX Trigger
  3455. // <0x29=> TC3 RX Trigger
  3456. // <0x2A=> TC6 RX Trigger
  3457. // <0x2B=> TC9 RX Trigger
  3458. // <0x2C=> I2SC0 TX Left Trigger
  3459. // <0x2D=> I2SC0 RX Left Trigger
  3460. // <0x2E=> I2SC1 TX Left Trigger
  3461. // <0x2F=> I2SC1 RX Left Trigger
  3462. // <0x30=> I2SC0 TX Right Trigger
  3463. // <0x31=> I2SC0 RX Right Trigger
  3464. // <0x32=> I2SC1 TX Right Trigger
  3465. // <0x33=> I2SC1 RX Right Trigger
  3466. // <i> Define the DMA trigger source
  3467. // <id> dmac_trifsrc_20
  3468. #ifndef CONF_DMAC_TRIGSRC_20
  3469. #define CONF_DMAC_TRIGSRC_20 0xff
  3470. #endif
  3471. // </e>
  3472. #if CONF_DMAC_TRANS_TYPE_20 == 0
  3473. #define CONF_DMAC_TYPE_20 0
  3474. #define CONF_DMAC_DSYNC_20 0
  3475. #elif CONF_DMAC_TRANS_TYPE_20 == 1
  3476. #define CONF_DMAC_TYPE_20 1
  3477. #define CONF_DMAC_DSYNC_20 0
  3478. #elif CONF_DMAC_TRANS_TYPE_20 == 2
  3479. #define CONF_DMAC_TYPE_20 1
  3480. #define CONF_DMAC_DSYNC_20 1
  3481. #endif
  3482. #if CONF_DMAC_TRIGSRC_20 == 0xFF
  3483. #define CONF_DMAC_SWREQ_20 1
  3484. #else
  3485. #define CONF_DMAC_SWREQ_20 0
  3486. #endif
  3487. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3488. * or fixed destination address mode, source and destination addresses are incremented
  3489. * by 8-bit or 16-bit.
  3490. * Workaround: The user can fix the problem by setting the source addressing mode to
  3491. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3492. */
  3493. #if (CONF_DMAC_CHANNEL_20_SETTINGS == 1 && CONF_DMAC_BEATSIZE_20 != 2 \
  3494. && ((!CONF_DMAC_SRCINC_20) || (!CONF_DMAC_DSTINC_20)))
  3495. #if (!CONF_DMAC_SRCINC_20)
  3496. #define CONF_DMAC_SRC_STRIDE_20 ((int16_t)(-1))
  3497. #endif
  3498. #if (!CONF_DMAC_DSTINC_20)
  3499. #define CONF_DMAC_DES_STRIDE_20 ((int16_t)(-1))
  3500. #endif
  3501. #endif
  3502. #ifndef CONF_DMAC_SRC_STRIDE_20
  3503. #define CONF_DMAC_SRC_STRIDE_20 0
  3504. #endif
  3505. #ifndef CONF_DMAC_DES_STRIDE_20
  3506. #define CONF_DMAC_DES_STRIDE_20 0
  3507. #endif
  3508. // <e> Channel 21 settings
  3509. // <id> dmac_channel_21_settings
  3510. #ifndef CONF_DMAC_CHANNEL_21_SETTINGS
  3511. #define CONF_DMAC_CHANNEL_21_SETTINGS 0
  3512. #endif
  3513. // <o> Burst Size
  3514. // <0x0=> 1 burst size
  3515. // <0x1=> 4 burst size
  3516. // <0x2=> 8 burst size
  3517. // <0x3=> 16 burst size
  3518. // <i> Define the memory burst size
  3519. // <id> dmac_burstsize_21
  3520. #ifndef CONF_DMAC_BURSTSIZE_21
  3521. #define CONF_DMAC_BURSTSIZE_21 0x0
  3522. #endif
  3523. // <o> Chunk Size
  3524. // <0x0=> 1 data transferred
  3525. // <0x1=> 2 data transferred
  3526. // <0x2=> 4 data transferred
  3527. // <0x3=> 8 data transferred
  3528. // <0x4=> 16 data transferred
  3529. // <i> Define the peripheral chunk size
  3530. // <id> dmac_chunksize_21
  3531. #ifndef CONF_DMAC_CHUNKSIZE_21
  3532. #define CONF_DMAC_CHUNKSIZE_21 0x0
  3533. #endif
  3534. // <o> Beat Size
  3535. // <0=> 8-bit bus transfer
  3536. // <1=> 16-bit bus transfer
  3537. // <2=> 32-bit bus transfer
  3538. // <i> Defines the size of one beat
  3539. // <id> dmac_beatsize_21
  3540. #ifndef CONF_DMAC_BEATSIZE_21
  3541. #define CONF_DMAC_BEATSIZE_21 0x0
  3542. #endif
  3543. // <o> Source Interface Identifier
  3544. // <0x0=> AHB_IF0
  3545. // <0x1=> AHB_IF1
  3546. // <i> Define the data is read through the system bus interface 0 or 1
  3547. // <id> dma_src_interface_21
  3548. #ifndef CONF_DMAC_SRC_INTERFACE_21
  3549. #define CONF_DMAC_SRC_INTERFACE_21 0x0
  3550. #endif
  3551. // <o> Destination Interface Identifier
  3552. // <0x0=> AHB_IF0
  3553. // <0x1=> AHB_IF1
  3554. // <i> Define the data is written through the system bus interface 0 or 1
  3555. // <id> dma_des_interface_21
  3556. #ifndef CONF_DMAC_DES_INTERFACE_21
  3557. #define CONF_DMAC_DES_INTERFACE_21 0x0
  3558. #endif
  3559. // <q> Source Address Increment
  3560. // <i> Indicates whether the source address incremented as beat size or not
  3561. // <id> dmac_srcinc_21
  3562. #ifndef CONF_DMAC_SRCINC_21
  3563. #define CONF_DMAC_SRCINC_21 0
  3564. #endif
  3565. // <q> Destination Address Increment
  3566. // <i> Indicates whether the destination address incremented as beat size or not
  3567. // <id> dmac_dstinc_21
  3568. #ifndef CONF_DMAC_DSTINC_21
  3569. #define CONF_DMAC_DSTINC_21 0
  3570. #endif
  3571. // <o> Transfer Type
  3572. // <0x0=> Memory to Memory Transfer
  3573. // <0x1=> Peripheral to Memory Transfer
  3574. // <0x2=> Memory to Peripheral Transfer
  3575. // <i> Define the data transfer type
  3576. // <id> dma_trans_type_21
  3577. #ifndef CONF_DMAC_TRANS_TYPE_21
  3578. #define CONF_DMAC_TRANS_TYPE_21 0x0
  3579. #endif
  3580. // <o> Trigger source
  3581. // <0xFF=> Software Trigger
  3582. // <0x00=> HSMCI TX/RX Trigger
  3583. // <0x01=> SPI0 TX Trigger
  3584. // <0x02=> SPI0 RX Trigger
  3585. // <0x03=> SPI1 TX Trigger
  3586. // <0x04=> SPI1 RX Trigger
  3587. // <0x05=> QSPI TX Trigger
  3588. // <0x06=> QSPI RX Trigger
  3589. // <0x07=> USART0 TX Trigger
  3590. // <0x08=> USART0 RX Trigger
  3591. // <0x09=> USART1 TX Trigger
  3592. // <0x0A=> USART1 RX Trigger
  3593. // <0x0B=> USART2 TX Trigger
  3594. // <0x0C=> USART2 RX Trigger
  3595. // <0x0D=> PWM0 TX Trigger
  3596. // <0x0E=> TWIHS0 TX Trigger
  3597. // <0x0F=> TWIHS0 RX Trigger
  3598. // <0x10=> TWIHS1 TX Trigger
  3599. // <0x11=> TWIHS1 RX Trigger
  3600. // <0x12=> TWIHS2 TX Trigger
  3601. // <0x13=> TWIHS2 RX Trigger
  3602. // <0x14=> UART0 TX Trigger
  3603. // <0x15=> UART0 RX Trigger
  3604. // <0x16=> UART1 TX Trigger
  3605. // <0x17=> UART1 RX Trigger
  3606. // <0x18=> UART2 TX Trigger
  3607. // <0x19=> UART2 RX Trigger
  3608. // <0x1A=> UART3 TX Trigger
  3609. // <0x1B=> UART3 RX Trigger
  3610. // <0x1C=> UART4 TX Trigger
  3611. // <0x1D=> UART4 RX Trigger
  3612. // <0x1E=> DACC TX Trigger
  3613. // <0x20=> SSC TX Trigger
  3614. // <0x21=> SSC RX Trigger
  3615. // <0x22=> PIOA RX Trigger
  3616. // <0x23=> AFEC0 RX Trigger
  3617. // <0x24=> AFEC1 RX Trigger
  3618. // <0x25=> AES TX Trigger
  3619. // <0x26=> AES RX Trigger
  3620. // <0x27=> PWM1 TX Trigger
  3621. // <0x28=> TC0 RX Trigger
  3622. // <0x29=> TC3 RX Trigger
  3623. // <0x2A=> TC6 RX Trigger
  3624. // <0x2B=> TC9 RX Trigger
  3625. // <0x2C=> I2SC0 TX Left Trigger
  3626. // <0x2D=> I2SC0 RX Left Trigger
  3627. // <0x2E=> I2SC1 TX Left Trigger
  3628. // <0x2F=> I2SC1 RX Left Trigger
  3629. // <0x30=> I2SC0 TX Right Trigger
  3630. // <0x31=> I2SC0 RX Right Trigger
  3631. // <0x32=> I2SC1 TX Right Trigger
  3632. // <0x33=> I2SC1 RX Right Trigger
  3633. // <i> Define the DMA trigger source
  3634. // <id> dmac_trifsrc_21
  3635. #ifndef CONF_DMAC_TRIGSRC_21
  3636. #define CONF_DMAC_TRIGSRC_21 0xff
  3637. #endif
  3638. // </e>
  3639. #if CONF_DMAC_TRANS_TYPE_21 == 0
  3640. #define CONF_DMAC_TYPE_21 0
  3641. #define CONF_DMAC_DSYNC_21 0
  3642. #elif CONF_DMAC_TRANS_TYPE_21 == 1
  3643. #define CONF_DMAC_TYPE_21 1
  3644. #define CONF_DMAC_DSYNC_21 0
  3645. #elif CONF_DMAC_TRANS_TYPE_21 == 2
  3646. #define CONF_DMAC_TYPE_21 1
  3647. #define CONF_DMAC_DSYNC_21 1
  3648. #endif
  3649. #if CONF_DMAC_TRIGSRC_21 == 0xFF
  3650. #define CONF_DMAC_SWREQ_21 1
  3651. #else
  3652. #define CONF_DMAC_SWREQ_21 0
  3653. #endif
  3654. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3655. * or fixed destination address mode, source and destination addresses are incremented
  3656. * by 8-bit or 16-bit.
  3657. * Workaround: The user can fix the problem by setting the source addressing mode to
  3658. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3659. */
  3660. #if (CONF_DMAC_CHANNEL_21_SETTINGS == 1 && CONF_DMAC_BEATSIZE_21 != 2 \
  3661. && ((!CONF_DMAC_SRCINC_21) || (!CONF_DMAC_DSTINC_21)))
  3662. #if (!CONF_DMAC_SRCINC_21)
  3663. #define CONF_DMAC_SRC_STRIDE_21 ((int16_t)(-1))
  3664. #endif
  3665. #if (!CONF_DMAC_DSTINC_21)
  3666. #define CONF_DMAC_DES_STRIDE_21 ((int16_t)(-1))
  3667. #endif
  3668. #endif
  3669. #ifndef CONF_DMAC_SRC_STRIDE_21
  3670. #define CONF_DMAC_SRC_STRIDE_21 0
  3671. #endif
  3672. #ifndef CONF_DMAC_DES_STRIDE_21
  3673. #define CONF_DMAC_DES_STRIDE_21 0
  3674. #endif
  3675. // <e> Channel 22 settings
  3676. // <id> dmac_channel_22_settings
  3677. #ifndef CONF_DMAC_CHANNEL_22_SETTINGS
  3678. #define CONF_DMAC_CHANNEL_22_SETTINGS 0
  3679. #endif
  3680. // <o> Burst Size
  3681. // <0x0=> 1 burst size
  3682. // <0x1=> 4 burst size
  3683. // <0x2=> 8 burst size
  3684. // <0x3=> 16 burst size
  3685. // <i> Define the memory burst size
  3686. // <id> dmac_burstsize_22
  3687. #ifndef CONF_DMAC_BURSTSIZE_22
  3688. #define CONF_DMAC_BURSTSIZE_22 0x0
  3689. #endif
  3690. // <o> Chunk Size
  3691. // <0x0=> 1 data transferred
  3692. // <0x1=> 2 data transferred
  3693. // <0x2=> 4 data transferred
  3694. // <0x3=> 8 data transferred
  3695. // <0x4=> 16 data transferred
  3696. // <i> Define the peripheral chunk size
  3697. // <id> dmac_chunksize_22
  3698. #ifndef CONF_DMAC_CHUNKSIZE_22
  3699. #define CONF_DMAC_CHUNKSIZE_22 0x0
  3700. #endif
  3701. // <o> Beat Size
  3702. // <0=> 8-bit bus transfer
  3703. // <1=> 16-bit bus transfer
  3704. // <2=> 32-bit bus transfer
  3705. // <i> Defines the size of one beat
  3706. // <id> dmac_beatsize_22
  3707. #ifndef CONF_DMAC_BEATSIZE_22
  3708. #define CONF_DMAC_BEATSIZE_22 0x0
  3709. #endif
  3710. // <o> Source Interface Identifier
  3711. // <0x0=> AHB_IF0
  3712. // <0x1=> AHB_IF1
  3713. // <i> Define the data is read through the system bus interface 0 or 1
  3714. // <id> dma_src_interface_22
  3715. #ifndef CONF_DMAC_SRC_INTERFACE_22
  3716. #define CONF_DMAC_SRC_INTERFACE_22 0x0
  3717. #endif
  3718. // <o> Destination Interface Identifier
  3719. // <0x0=> AHB_IF0
  3720. // <0x1=> AHB_IF1
  3721. // <i> Define the data is written through the system bus interface 0 or 1
  3722. // <id> dma_des_interface_22
  3723. #ifndef CONF_DMAC_DES_INTERFACE_22
  3724. #define CONF_DMAC_DES_INTERFACE_22 0x0
  3725. #endif
  3726. // <q> Source Address Increment
  3727. // <i> Indicates whether the source address incremented as beat size or not
  3728. // <id> dmac_srcinc_22
  3729. #ifndef CONF_DMAC_SRCINC_22
  3730. #define CONF_DMAC_SRCINC_22 0
  3731. #endif
  3732. // <q> Destination Address Increment
  3733. // <i> Indicates whether the destination address incremented as beat size or not
  3734. // <id> dmac_dstinc_22
  3735. #ifndef CONF_DMAC_DSTINC_22
  3736. #define CONF_DMAC_DSTINC_22 0
  3737. #endif
  3738. // <o> Transfer Type
  3739. // <0x0=> Memory to Memory Transfer
  3740. // <0x1=> Peripheral to Memory Transfer
  3741. // <0x2=> Memory to Peripheral Transfer
  3742. // <i> Define the data transfer type
  3743. // <id> dma_trans_type_22
  3744. #ifndef CONF_DMAC_TRANS_TYPE_22
  3745. #define CONF_DMAC_TRANS_TYPE_22 0x0
  3746. #endif
  3747. // <o> Trigger source
  3748. // <0xFF=> Software Trigger
  3749. // <0x00=> HSMCI TX/RX Trigger
  3750. // <0x01=> SPI0 TX Trigger
  3751. // <0x02=> SPI0 RX Trigger
  3752. // <0x03=> SPI1 TX Trigger
  3753. // <0x04=> SPI1 RX Trigger
  3754. // <0x05=> QSPI TX Trigger
  3755. // <0x06=> QSPI RX Trigger
  3756. // <0x07=> USART0 TX Trigger
  3757. // <0x08=> USART0 RX Trigger
  3758. // <0x09=> USART1 TX Trigger
  3759. // <0x0A=> USART1 RX Trigger
  3760. // <0x0B=> USART2 TX Trigger
  3761. // <0x0C=> USART2 RX Trigger
  3762. // <0x0D=> PWM0 TX Trigger
  3763. // <0x0E=> TWIHS0 TX Trigger
  3764. // <0x0F=> TWIHS0 RX Trigger
  3765. // <0x10=> TWIHS1 TX Trigger
  3766. // <0x11=> TWIHS1 RX Trigger
  3767. // <0x12=> TWIHS2 TX Trigger
  3768. // <0x13=> TWIHS2 RX Trigger
  3769. // <0x14=> UART0 TX Trigger
  3770. // <0x15=> UART0 RX Trigger
  3771. // <0x16=> UART1 TX Trigger
  3772. // <0x17=> UART1 RX Trigger
  3773. // <0x18=> UART2 TX Trigger
  3774. // <0x19=> UART2 RX Trigger
  3775. // <0x1A=> UART3 TX Trigger
  3776. // <0x1B=> UART3 RX Trigger
  3777. // <0x1C=> UART4 TX Trigger
  3778. // <0x1D=> UART4 RX Trigger
  3779. // <0x1E=> DACC TX Trigger
  3780. // <0x20=> SSC TX Trigger
  3781. // <0x21=> SSC RX Trigger
  3782. // <0x22=> PIOA RX Trigger
  3783. // <0x23=> AFEC0 RX Trigger
  3784. // <0x24=> AFEC1 RX Trigger
  3785. // <0x25=> AES TX Trigger
  3786. // <0x26=> AES RX Trigger
  3787. // <0x27=> PWM1 TX Trigger
  3788. // <0x28=> TC0 RX Trigger
  3789. // <0x29=> TC3 RX Trigger
  3790. // <0x2A=> TC6 RX Trigger
  3791. // <0x2B=> TC9 RX Trigger
  3792. // <0x2C=> I2SC0 TX Left Trigger
  3793. // <0x2D=> I2SC0 RX Left Trigger
  3794. // <0x2E=> I2SC1 TX Left Trigger
  3795. // <0x2F=> I2SC1 RX Left Trigger
  3796. // <0x30=> I2SC0 TX Right Trigger
  3797. // <0x31=> I2SC0 RX Right Trigger
  3798. // <0x32=> I2SC1 TX Right Trigger
  3799. // <0x33=> I2SC1 RX Right Trigger
  3800. // <i> Define the DMA trigger source
  3801. // <id> dmac_trifsrc_22
  3802. #ifndef CONF_DMAC_TRIGSRC_22
  3803. #define CONF_DMAC_TRIGSRC_22 0xff
  3804. #endif
  3805. // </e>
  3806. #if CONF_DMAC_TRANS_TYPE_22 == 0
  3807. #define CONF_DMAC_TYPE_22 0
  3808. #define CONF_DMAC_DSYNC_22 0
  3809. #elif CONF_DMAC_TRANS_TYPE_22 == 1
  3810. #define CONF_DMAC_TYPE_22 1
  3811. #define CONF_DMAC_DSYNC_22 0
  3812. #elif CONF_DMAC_TRANS_TYPE_22 == 2
  3813. #define CONF_DMAC_TYPE_22 1
  3814. #define CONF_DMAC_DSYNC_22 1
  3815. #endif
  3816. #if CONF_DMAC_TRIGSRC_22 == 0xFF
  3817. #define CONF_DMAC_SWREQ_22 1
  3818. #else
  3819. #define CONF_DMAC_SWREQ_22 0
  3820. #endif
  3821. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3822. * or fixed destination address mode, source and destination addresses are incremented
  3823. * by 8-bit or 16-bit.
  3824. * Workaround: The user can fix the problem by setting the source addressing mode to
  3825. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3826. */
  3827. #if (CONF_DMAC_CHANNEL_22_SETTINGS == 1 && CONF_DMAC_BEATSIZE_22 != 2 \
  3828. && ((!CONF_DMAC_SRCINC_22) || (!CONF_DMAC_DSTINC_22)))
  3829. #if (!CONF_DMAC_SRCINC_22)
  3830. #define CONF_DMAC_SRC_STRIDE_22 ((int16_t)(-1))
  3831. #endif
  3832. #if (!CONF_DMAC_DSTINC_22)
  3833. #define CONF_DMAC_DES_STRIDE_22 ((int16_t)(-1))
  3834. #endif
  3835. #endif
  3836. #ifndef CONF_DMAC_SRC_STRIDE_22
  3837. #define CONF_DMAC_SRC_STRIDE_22 0
  3838. #endif
  3839. #ifndef CONF_DMAC_DES_STRIDE_22
  3840. #define CONF_DMAC_DES_STRIDE_22 0
  3841. #endif
  3842. // <e> Channel 23 settings
  3843. // <id> dmac_channel_23_settings
  3844. #ifndef CONF_DMAC_CHANNEL_23_SETTINGS
  3845. #define CONF_DMAC_CHANNEL_23_SETTINGS 0
  3846. #endif
  3847. // <o> Burst Size
  3848. // <0x0=> 1 burst size
  3849. // <0x1=> 4 burst size
  3850. // <0x2=> 8 burst size
  3851. // <0x3=> 16 burst size
  3852. // <i> Define the memory burst size
  3853. // <id> dmac_burstsize_23
  3854. #ifndef CONF_DMAC_BURSTSIZE_23
  3855. #define CONF_DMAC_BURSTSIZE_23 0x0
  3856. #endif
  3857. // <o> Chunk Size
  3858. // <0x0=> 1 data transferred
  3859. // <0x1=> 2 data transferred
  3860. // <0x2=> 4 data transferred
  3861. // <0x3=> 8 data transferred
  3862. // <0x4=> 16 data transferred
  3863. // <i> Define the peripheral chunk size
  3864. // <id> dmac_chunksize_23
  3865. #ifndef CONF_DMAC_CHUNKSIZE_23
  3866. #define CONF_DMAC_CHUNKSIZE_23 0x0
  3867. #endif
  3868. // <o> Beat Size
  3869. // <0=> 8-bit bus transfer
  3870. // <1=> 16-bit bus transfer
  3871. // <2=> 32-bit bus transfer
  3872. // <i> Defines the size of one beat
  3873. // <id> dmac_beatsize_23
  3874. #ifndef CONF_DMAC_BEATSIZE_23
  3875. #define CONF_DMAC_BEATSIZE_23 0x0
  3876. #endif
  3877. // <o> Source Interface Identifier
  3878. // <0x0=> AHB_IF0
  3879. // <0x1=> AHB_IF1
  3880. // <i> Define the data is read through the system bus interface 0 or 1
  3881. // <id> dma_src_interface_23
  3882. #ifndef CONF_DMAC_SRC_INTERFACE_23
  3883. #define CONF_DMAC_SRC_INTERFACE_23 0x0
  3884. #endif
  3885. // <o> Destination Interface Identifier
  3886. // <0x0=> AHB_IF0
  3887. // <0x1=> AHB_IF1
  3888. // <i> Define the data is written through the system bus interface 0 or 1
  3889. // <id> dma_des_interface_23
  3890. #ifndef CONF_DMAC_DES_INTERFACE_23
  3891. #define CONF_DMAC_DES_INTERFACE_23 0x0
  3892. #endif
  3893. // <q> Source Address Increment
  3894. // <i> Indicates whether the source address incremented as beat size or not
  3895. // <id> dmac_srcinc_23
  3896. #ifndef CONF_DMAC_SRCINC_23
  3897. #define CONF_DMAC_SRCINC_23 0
  3898. #endif
  3899. // <q> Destination Address Increment
  3900. // <i> Indicates whether the destination address incremented as beat size or not
  3901. // <id> dmac_dstinc_23
  3902. #ifndef CONF_DMAC_DSTINC_23
  3903. #define CONF_DMAC_DSTINC_23 0
  3904. #endif
  3905. // <o> Transfer Type
  3906. // <0x0=> Memory to Memory Transfer
  3907. // <0x1=> Peripheral to Memory Transfer
  3908. // <0x2=> Memory to Peripheral Transfer
  3909. // <i> Define the data transfer type
  3910. // <id> dma_trans_type_23
  3911. #ifndef CONF_DMAC_TRANS_TYPE_23
  3912. #define CONF_DMAC_TRANS_TYPE_23 0x0
  3913. #endif
  3914. // <o> Trigger source
  3915. // <0xFF=> Software Trigger
  3916. // <0x00=> HSMCI TX/RX Trigger
  3917. // <0x01=> SPI0 TX Trigger
  3918. // <0x02=> SPI0 RX Trigger
  3919. // <0x03=> SPI1 TX Trigger
  3920. // <0x04=> SPI1 RX Trigger
  3921. // <0x05=> QSPI TX Trigger
  3922. // <0x06=> QSPI RX Trigger
  3923. // <0x07=> USART0 TX Trigger
  3924. // <0x08=> USART0 RX Trigger
  3925. // <0x09=> USART1 TX Trigger
  3926. // <0x0A=> USART1 RX Trigger
  3927. // <0x0B=> USART2 TX Trigger
  3928. // <0x0C=> USART2 RX Trigger
  3929. // <0x0D=> PWM0 TX Trigger
  3930. // <0x0E=> TWIHS0 TX Trigger
  3931. // <0x0F=> TWIHS0 RX Trigger
  3932. // <0x10=> TWIHS1 TX Trigger
  3933. // <0x11=> TWIHS1 RX Trigger
  3934. // <0x12=> TWIHS2 TX Trigger
  3935. // <0x13=> TWIHS2 RX Trigger
  3936. // <0x14=> UART0 TX Trigger
  3937. // <0x15=> UART0 RX Trigger
  3938. // <0x16=> UART1 TX Trigger
  3939. // <0x17=> UART1 RX Trigger
  3940. // <0x18=> UART2 TX Trigger
  3941. // <0x19=> UART2 RX Trigger
  3942. // <0x1A=> UART3 TX Trigger
  3943. // <0x1B=> UART3 RX Trigger
  3944. // <0x1C=> UART4 TX Trigger
  3945. // <0x1D=> UART4 RX Trigger
  3946. // <0x1E=> DACC TX Trigger
  3947. // <0x20=> SSC TX Trigger
  3948. // <0x21=> SSC RX Trigger
  3949. // <0x22=> PIOA RX Trigger
  3950. // <0x23=> AFEC0 RX Trigger
  3951. // <0x24=> AFEC1 RX Trigger
  3952. // <0x25=> AES TX Trigger
  3953. // <0x26=> AES RX Trigger
  3954. // <0x27=> PWM1 TX Trigger
  3955. // <0x28=> TC0 RX Trigger
  3956. // <0x29=> TC3 RX Trigger
  3957. // <0x2A=> TC6 RX Trigger
  3958. // <0x2B=> TC9 RX Trigger
  3959. // <0x2C=> I2SC0 TX Left Trigger
  3960. // <0x2D=> I2SC0 RX Left Trigger
  3961. // <0x2E=> I2SC1 TX Left Trigger
  3962. // <0x2F=> I2SC1 RX Left Trigger
  3963. // <0x30=> I2SC0 TX Right Trigger
  3964. // <0x31=> I2SC0 RX Right Trigger
  3965. // <0x32=> I2SC1 TX Right Trigger
  3966. // <0x33=> I2SC1 RX Right Trigger
  3967. // <i> Define the DMA trigger source
  3968. // <id> dmac_trifsrc_23
  3969. #ifndef CONF_DMAC_TRIGSRC_23
  3970. #define CONF_DMAC_TRIGSRC_23 0xff
  3971. #endif
  3972. // </e>
  3973. #if CONF_DMAC_TRANS_TYPE_23 == 0
  3974. #define CONF_DMAC_TYPE_23 0
  3975. #define CONF_DMAC_DSYNC_23 0
  3976. #elif CONF_DMAC_TRANS_TYPE_23 == 1
  3977. #define CONF_DMAC_TYPE_23 1
  3978. #define CONF_DMAC_DSYNC_23 0
  3979. #elif CONF_DMAC_TRANS_TYPE_23 == 2
  3980. #define CONF_DMAC_TYPE_23 1
  3981. #define CONF_DMAC_DSYNC_23 1
  3982. #endif
  3983. #if CONF_DMAC_TRIGSRC_23 == 0xFF
  3984. #define CONF_DMAC_SWREQ_23 1
  3985. #else
  3986. #define CONF_DMAC_SWREQ_23 0
  3987. #endif
  3988. /* Errata: If XDMA is used to transfer 8-bit or 16-bit data in fixed source address
  3989. * or fixed destination address mode, source and destination addresses are incremented
  3990. * by 8-bit or 16-bit.
  3991. * Workaround: The user can fix the problem by setting the source addressing mode to
  3992. * use microblock and data striding with microblock stride set to 0 and data stride set to -1.
  3993. */
  3994. #if (CONF_DMAC_CHANNEL_23_SETTINGS == 1 && CONF_DMAC_BEATSIZE_23 != 2 \
  3995. && ((!CONF_DMAC_SRCINC_23) || (!CONF_DMAC_DSTINC_23)))
  3996. #if (!CONF_DMAC_SRCINC_23)
  3997. #define CONF_DMAC_SRC_STRIDE_23 ((int16_t)(-1))
  3998. #endif
  3999. #if (!CONF_DMAC_DSTINC_23)
  4000. #define CONF_DMAC_DES_STRIDE_23 ((int16_t)(-1))
  4001. #endif
  4002. #endif
  4003. #ifndef CONF_DMAC_SRC_STRIDE_23
  4004. #define CONF_DMAC_SRC_STRIDE_23 0
  4005. #endif
  4006. #ifndef CONF_DMAC_DES_STRIDE_23
  4007. #define CONF_DMAC_DES_STRIDE_23 0
  4008. #endif
  4009. // </e>
  4010. // <<< end of configuration section >>>
  4011. #endif // HPL_XDMAC_CONFIG_H