1include_guard(GLOBAL)
2
3
4if (CONFIG_USE_middleware_baremetal)
5# Add set(CONFIG_USE_middleware_baremetal true) in config.cmake to use this component
6
7message("middleware_baremetal component is included from ${CMAKE_CURRENT_LIST_FILE}.")
8
9if(CONFIG_USE_COMPONENT_CONFIGURATION)
10  message("===>Import configuration from ${CMAKE_CURRENT_LIST_FILE}")
11
12  target_compile_definitions(${MCUX_SDK_PROJECT_NAME} PUBLIC
13    -DSDK_OS_BAREMETAL
14  )
15
16endif()
17
18
19endif()
20
21
22if (CONFIG_USE_utilities_misc_utilities)
23# Add set(CONFIG_USE_utilities_misc_utilities true) in config.cmake to use this component
24
25message("utilities_misc_utilities component is included from ${CMAKE_CURRENT_LIST_FILE}.")
26
27if(CONFIG_TOOLCHAIN STREQUAL armgcc)
28  target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
29      ${CMAKE_CURRENT_LIST_DIR}/../../utilities/misc_utilities/fsl_sbrk.c
30      ${CMAKE_CURRENT_LIST_DIR}/../../utilities/misc_utilities/fsl_syscall_stub.c
31  )
32endif()
33
34
35endif()
36
37
38if (CONFIG_USE_DEVICES_Project_Template_LPC824)
39# Add set(CONFIG_USE_DEVICES_Project_Template_LPC824 true) in config.cmake to use this component
40
41message("DEVICES_Project_Template_LPC824 component is included from ${CMAKE_CURRENT_LIST_FILE}.")
42
43if(CONFIG_USE_component_miniusart_adapter AND (CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_device_LPC824_startup AND CONFIG_USE_driver_clock AND CONFIG_USE_driver_common AND CONFIG_USE_driver_lpc_gpio AND CONFIG_USE_driver_lpc_iocon_lite AND CONFIG_USE_driver_lpc_miniusart AND CONFIG_USE_driver_power_no_lib AND CONFIG_USE_driver_reset AND CONFIG_USE_driver_swm AND CONFIG_USE_utility_assert_lite AND CONFIG_USE_utility_debug_console_lite)
44
45add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/clock_config.h "" DEVICES_Project_Template_LPC824.LPC824)
46add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/clock_config.c "" DEVICES_Project_Template_LPC824.LPC824)
47add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/pin_mux.h "" DEVICES_Project_Template_LPC824.LPC824)
48add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/pin_mux.c "" DEVICES_Project_Template_LPC824.LPC824)
49add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/peripherals.h "" DEVICES_Project_Template_LPC824.LPC824)
50add_config_file(${CMAKE_CURRENT_LIST_DIR}/project_template/peripherals.c "" DEVICES_Project_Template_LPC824.LPC824)
51
52target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
53  ${CMAKE_CURRENT_LIST_DIR}/project_template/.
54)
55
56else()
57
58message(SEND_ERROR "DEVICES_Project_Template_LPC824.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
59
60endif()
61
62endif()
63
64
65if (CONFIG_USE_device_LPC824_startup)
66# Add set(CONFIG_USE_device_LPC824_startup true) in config.cmake to use this component
67
68message("device_LPC824_startup component is included from ${CMAKE_CURRENT_LIST_FILE}.")
69
70if(CONFIG_USE_device_LPC824_system)
71
72if(CONFIG_TOOLCHAIN STREQUAL armgcc)
73  add_config_file(${CMAKE_CURRENT_LIST_DIR}/./gcc/startup_LPC824.S "" device_LPC824_startup.LPC824)
74endif()
75
76if(CONFIG_TOOLCHAIN STREQUAL mcux)
77  add_config_file(${CMAKE_CURRENT_LIST_DIR}/./mcuxpresso/startup_lpc824.c "" device_LPC824_startup.LPC824)
78  add_config_file(${CMAKE_CURRENT_LIST_DIR}/./mcuxpresso/startup_lpc824.cpp "" device_LPC824_startup.LPC824)
79endif()
80
81else()
82
83message(SEND_ERROR "device_LPC824_startup.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
84
85endif()
86
87endif()
88
89
90if (CONFIG_USE_device_LPC824_CMSIS)
91# Add set(CONFIG_USE_device_LPC824_CMSIS true) in config.cmake to use this component
92
93message("device_LPC824_CMSIS component is included from ${CMAKE_CURRENT_LIST_FILE}.")
94
95if(CONFIG_USE_CMSIS_Include_core_cm AND (CONFIG_DEVICE_ID STREQUAL LPC824))
96
97target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
98  ${CMAKE_CURRENT_LIST_DIR}/./.
99)
100
101else()
102
103message(SEND_ERROR "device_LPC824_CMSIS.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
104
105endif()
106
107endif()
108
109
110if (CONFIG_USE_driver_clock)
111# Add set(CONFIG_USE_driver_clock true) in config.cmake to use this component
112
113message("driver_clock component is included from ${CMAKE_CURRENT_LIST_FILE}.")
114
115if(CONFIG_USE_driver_power_no_lib AND CONFIG_USE_driver_common)
116
117target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
118  ${CMAKE_CURRENT_LIST_DIR}/drivers/fsl_clock.c
119)
120
121target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
122  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
123)
124
125else()
126
127message(SEND_ERROR "driver_clock.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
128
129endif()
130
131endif()
132
133
134if (CONFIG_USE_utility_assert_lite)
135# Add set(CONFIG_USE_utility_assert_lite true) in config.cmake to use this component
136
137message("utility_assert_lite component is included from ${CMAKE_CURRENT_LIST_FILE}.")
138
139if(CONFIG_USE_component_miniusart_adapter AND CONFIG_USE_utility_debug_console_lite AND CONFIG_USE_driver_common)
140
141target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
142  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/assert/fsl_assert.c
143)
144
145target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
146  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/assert/.
147)
148
149else()
150
151message(SEND_ERROR "utility_assert_lite.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
152
153endif()
154
155endif()
156
157
158if (CONFIG_USE_component_lpc_gpio_adapter)
159# Add set(CONFIG_USE_component_lpc_gpio_adapter true) in config.cmake to use this component
160
161message("component_lpc_gpio_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
162
163if(CONFIG_USE_driver_syscon AND CONFIG_USE_driver_lpc_gpio AND CONFIG_USE_driver_inputmux AND CONFIG_USE_driver_pint)
164
165target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
166  ${CMAKE_CURRENT_LIST_DIR}/../../components/gpio/fsl_adapter_lpc_gpio.c
167)
168
169target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
170  ${CMAKE_CURRENT_LIST_DIR}/../../components/gpio/.
171)
172
173else()
174
175message(SEND_ERROR "component_lpc_gpio_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
176
177endif()
178
179endif()
180
181
182if (CONFIG_USE_utility_debug_console_lite)
183# Add set(CONFIG_USE_utility_debug_console_lite true) in config.cmake to use this component
184
185message("utility_debug_console_lite component is included from ${CMAKE_CURRENT_LIST_FILE}.")
186
187if(CONFIG_USE_component_miniusart_adapter AND (CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common AND CONFIG_USE_utility_str)
188
189target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
190  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/debug_console_lite/fsl_debug_console.c
191)
192
193target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
194  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/debug_console_lite
195)
196
197else()
198
199message(SEND_ERROR "utility_debug_console_lite.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
200
201endif()
202
203endif()
204
205
206if (CONFIG_USE_driver_inputmux_connections)
207# Add set(CONFIG_USE_driver_inputmux_connections true) in config.cmake to use this component
208
209message("driver_inputmux_connections component is included from ${CMAKE_CURRENT_LIST_FILE}.")
210
211if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
212
213target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
214  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
215)
216
217else()
218
219message(SEND_ERROR "driver_inputmux_connections.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
220
221endif()
222
223endif()
224
225
226if (CONFIG_USE_driver_swm_connections)
227# Add set(CONFIG_USE_driver_swm_connections true) in config.cmake to use this component
228
229message("driver_swm_connections component is included from ${CMAKE_CURRENT_LIST_FILE}.")
230
231if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
232
233target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
234  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
235)
236
237else()
238
239message(SEND_ERROR "driver_swm_connections.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
240
241endif()
242
243endif()
244
245
246if (CONFIG_USE_driver_syscon_connections)
247# Add set(CONFIG_USE_driver_syscon_connections true) in config.cmake to use this component
248
249message("driver_syscon_connections component is included from ${CMAKE_CURRENT_LIST_FILE}.")
250
251if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
252
253target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
254  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
255)
256
257else()
258
259message(SEND_ERROR "driver_syscon_connections.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
260
261endif()
262
263endif()
264
265
266if (CONFIG_USE_driver_power_no_lib)
267# Add set(CONFIG_USE_driver_power_no_lib true) in config.cmake to use this component
268
269message("driver_power_no_lib component is included from ${CMAKE_CURRENT_LIST_FILE}.")
270
271if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
272
273target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
274  ${CMAKE_CURRENT_LIST_DIR}/drivers/fsl_power.c
275)
276
277target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
278  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
279)
280
281else()
282
283message(SEND_ERROR "driver_power_no_lib.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
284
285endif()
286
287endif()
288
289
290if (CONFIG_USE_driver_common)
291# Add set(CONFIG_USE_driver_common true) in config.cmake to use this component
292
293message("driver_common component is included from ${CMAKE_CURRENT_LIST_FILE}.")
294
295if(CONFIG_USE_driver_reset AND CONFIG_USE_driver_clock AND CONFIG_USE_device_LPC824_CMSIS)
296
297target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
298  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/common/fsl_common.c
299)
300
301if(CONFIG_CORE STREQUAL cm0p)
302  target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
303      ${CMAKE_CURRENT_LIST_DIR}/../../drivers/common/fsl_common_arm.c
304  )
305endif()
306
307target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
308  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/common/.
309)
310
311else()
312
313message(SEND_ERROR "driver_common.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
314
315endif()
316
317endif()
318
319
320if (CONFIG_USE_device_LPC824_system)
321# Add set(CONFIG_USE_device_LPC824_system true) in config.cmake to use this component
322
323message("device_LPC824_system component is included from ${CMAKE_CURRENT_LIST_FILE}.")
324
325if(CONFIG_USE_device_LPC824_CMSIS)
326
327target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
328  ${CMAKE_CURRENT_LIST_DIR}/./system_LPC824.c
329)
330
331target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
332  ${CMAKE_CURRENT_LIST_DIR}/./.
333)
334
335else()
336
337message(SEND_ERROR "device_LPC824_system.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
338
339endif()
340
341endif()
342
343
344if (CONFIG_USE_utility_str)
345# Add set(CONFIG_USE_utility_str true) in config.cmake to use this component
346
347message("utility_str component is included from ${CMAKE_CURRENT_LIST_FILE}.")
348
349if(CONFIG_USE_driver_common)
350
351target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
352  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/str/fsl_str.c
353)
354
355target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
356  ${CMAKE_CURRENT_LIST_DIR}/../../utilities/str
357)
358
359else()
360
361message(SEND_ERROR "utility_str.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
362
363endif()
364
365endif()
366
367
368if (CONFIG_USE_component_button)
369# Add set(CONFIG_USE_component_button true) in config.cmake to use this component
370
371message("component_button component is included from ${CMAKE_CURRENT_LIST_FILE}.")
372
373if(CONFIG_USE_driver_common AND CONFIG_USE_component_timer_manager AND (CONFIG_USE_component_lpc_gpio_adapter))
374
375target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
376  ${CMAKE_CURRENT_LIST_DIR}/../../components/button/fsl_component_button.c
377)
378
379target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
380  ${CMAKE_CURRENT_LIST_DIR}/../../components/button/.
381)
382
383else()
384
385message(SEND_ERROR "component_button.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
386
387endif()
388
389endif()
390
391
392if (CONFIG_USE_component_lpc_crc_adapter)
393# Add set(CONFIG_USE_component_lpc_crc_adapter true) in config.cmake to use this component
394
395message("component_lpc_crc_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
396
397if(CONFIG_USE_driver_common AND CONFIG_USE_driver_lpc_crc)
398
399target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
400  ${CMAKE_CURRENT_LIST_DIR}/../../components/crc/fsl_adapter_lpc_crc.c
401)
402
403target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
404  ${CMAKE_CURRENT_LIST_DIR}/../../components/crc/.
405)
406
407else()
408
409message(SEND_ERROR "component_lpc_crc_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
410
411endif()
412
413endif()
414
415
416if (CONFIG_USE_component_software_crc_adapter)
417# Add set(CONFIG_USE_component_software_crc_adapter true) in config.cmake to use this component
418
419message("component_software_crc_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
420
421if(CONFIG_USE_driver_common)
422
423target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
424  ${CMAKE_CURRENT_LIST_DIR}/../../components/crc/fsl_adapter_software_crc.c
425)
426
427target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
428  ${CMAKE_CURRENT_LIST_DIR}/../../components/crc/.
429)
430
431else()
432
433message(SEND_ERROR "component_software_crc_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
434
435endif()
436
437endif()
438
439
440if (CONFIG_USE_component_lpc_i2c_adapter)
441# Add set(CONFIG_USE_component_lpc_i2c_adapter true) in config.cmake to use this component
442
443message("component_lpc_i2c_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
444
445if(CONFIG_USE_driver_common AND CONFIG_USE_driver_lpc_i2c)
446
447target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
448  ${CMAKE_CURRENT_LIST_DIR}/../../components/i2c/fsl_adapter_lpc_i2c.c
449)
450
451target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
452  ${CMAKE_CURRENT_LIST_DIR}/../../components/i2c/.
453)
454
455else()
456
457message(SEND_ERROR "component_lpc_i2c_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
458
459endif()
460
461endif()
462
463
464if (CONFIG_USE_component_led)
465# Add set(CONFIG_USE_component_led true) in config.cmake to use this component
466
467message("component_led component is included from ${CMAKE_CURRENT_LIST_FILE}.")
468
469if(CONFIG_USE_driver_common AND CONFIG_USE_component_timer_manager AND (CONFIG_USE_component_lpc_gpio_adapter))
470
471target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
472  ${CMAKE_CURRENT_LIST_DIR}/../../components/led/fsl_component_led.c
473)
474
475target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
476  ${CMAKE_CURRENT_LIST_DIR}/../../components/led/.
477)
478
479else()
480
481message(SEND_ERROR "component_led.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
482
483endif()
484
485endif()
486
487
488if (CONFIG_USE_component_lists)
489# Add set(CONFIG_USE_component_lists true) in config.cmake to use this component
490
491message("component_lists component is included from ${CMAKE_CURRENT_LIST_FILE}.")
492
493if(CONFIG_USE_driver_common)
494
495target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
496  ${CMAKE_CURRENT_LIST_DIR}/../../components/lists/fsl_component_generic_list.c
497)
498
499target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
500  ${CMAKE_CURRENT_LIST_DIR}/../../components/lists/.
501)
502
503else()
504
505message(SEND_ERROR "component_lists.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
506
507endif()
508
509endif()
510
511
512if (CONFIG_USE_component_mem_manager)
513# Add set(CONFIG_USE_component_mem_manager true) in config.cmake to use this component
514
515message("component_mem_manager component is included from ${CMAKE_CURRENT_LIST_FILE}.")
516
517if(CONFIG_USE_driver_common AND CONFIG_USE_component_lists)
518
519target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
520  ${CMAKE_CURRENT_LIST_DIR}/../../components/mem_manager/fsl_component_mem_manager.c
521)
522
523target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
524  ${CMAKE_CURRENT_LIST_DIR}/../../components/mem_manager/.
525)
526
527else()
528
529message(SEND_ERROR "component_mem_manager.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
530
531endif()
532
533endif()
534
535
536if (CONFIG_USE_component_mem_manager_light)
537# Add set(CONFIG_USE_component_mem_manager_light true) in config.cmake to use this component
538
539message("component_mem_manager_light component is included from ${CMAKE_CURRENT_LIST_FILE}.")
540
541if(CONFIG_USE_driver_common AND CONFIG_USE_component_lists)
542
543target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
544  ${CMAKE_CURRENT_LIST_DIR}/../../components/mem_manager/fsl_component_mem_manager_light.c
545)
546
547target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
548  ${CMAKE_CURRENT_LIST_DIR}/../../components/mem_manager/.
549)
550
551else()
552
553message(SEND_ERROR "component_mem_manager_light.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
554
555endif()
556
557endif()
558
559
560if (CONFIG_USE_component_panic)
561# Add set(CONFIG_USE_component_panic true) in config.cmake to use this component
562
563message("component_panic component is included from ${CMAKE_CURRENT_LIST_FILE}.")
564
565if(CONFIG_USE_driver_common)
566
567target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
568  ${CMAKE_CURRENT_LIST_DIR}/../../components/panic/fsl_component_panic.c
569)
570
571target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
572  ${CMAKE_CURRENT_LIST_DIR}/../../components/panic/.
573)
574
575else()
576
577message(SEND_ERROR "component_panic.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
578
579endif()
580
581endif()
582
583
584if (CONFIG_USE_component_reset_adapter)
585# Add set(CONFIG_USE_component_reset_adapter true) in config.cmake to use this component
586
587message("component_reset_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
588
589if(CONFIG_USE_driver_common)
590
591target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
592  ${CMAKE_CURRENT_LIST_DIR}/../../components/reset/fsl_adapter_reset.c
593)
594
595target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
596  ${CMAKE_CURRENT_LIST_DIR}/../../components/reset/.
597)
598
599else()
600
601message(SEND_ERROR "component_reset_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
602
603endif()
604
605endif()
606
607
608if (CONFIG_USE_component_software_rng_adapter)
609# Add set(CONFIG_USE_component_software_rng_adapter true) in config.cmake to use this component
610
611message("component_software_rng_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
612
613if(CONFIG_USE_driver_common)
614
615target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
616  ${CMAKE_CURRENT_LIST_DIR}/../../components/rng/fsl_adapter_software_rng.c
617)
618
619target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
620  ${CMAKE_CURRENT_LIST_DIR}/../../components/rng/.
621)
622
623else()
624
625message(SEND_ERROR "component_software_rng_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
626
627endif()
628
629endif()
630
631
632if (CONFIG_USE_component_mrt_adapter)
633# Add set(CONFIG_USE_component_mrt_adapter true) in config.cmake to use this component
634
635message("component_mrt_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
636
637if(CONFIG_USE_driver_common AND CONFIG_USE_driver_mrt)
638
639target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
640  ${CMAKE_CURRENT_LIST_DIR}/../../components/timer/fsl_adapter_mrt.c
641)
642
643target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
644  ${CMAKE_CURRENT_LIST_DIR}/../../components/timer/.
645)
646
647if(CONFIG_USE_COMPONENT_CONFIGURATION)
648  message("===>Import configuration from ${CMAKE_CURRENT_LIST_FILE}")
649
650  target_compile_definitions(${MCUX_SDK_PROJECT_NAME} PUBLIC
651    -DTIMER_PORT_TYPE_MRT=1
652  )
653
654endif()
655
656else()
657
658message(SEND_ERROR "component_mrt_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
659
660endif()
661
662endif()
663
664
665if (CONFIG_USE_component_timer_manager)
666# Add set(CONFIG_USE_component_timer_manager true) in config.cmake to use this component
667
668message("component_timer_manager component is included from ${CMAKE_CURRENT_LIST_FILE}.")
669
670if(CONFIG_USE_driver_common AND CONFIG_USE_component_lists AND (CONFIG_USE_component_mrt_adapter))
671
672target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
673  ${CMAKE_CURRENT_LIST_DIR}/../../components/timer_manager/fsl_component_timer_manager.c
674)
675
676target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
677  ${CMAKE_CURRENT_LIST_DIR}/../../components/timer_manager/.
678)
679
680else()
681
682message(SEND_ERROR "component_timer_manager.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
683
684endif()
685
686endif()
687
688
689if (CONFIG_USE_component_miniusart_adapter)
690# Add set(CONFIG_USE_component_miniusart_adapter true) in config.cmake to use this component
691
692message("component_miniusart_adapter component is included from ${CMAKE_CURRENT_LIST_FILE}.")
693
694if(CONFIG_USE_driver_common AND CONFIG_USE_driver_lpc_miniusart)
695
696target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
697  ${CMAKE_CURRENT_LIST_DIR}/../../components/uart/fsl_adapter_miniusart.c
698)
699
700target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
701  ${CMAKE_CURRENT_LIST_DIR}/../../components/uart/.
702)
703
704else()
705
706message(SEND_ERROR "component_miniusart_adapter.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
707
708endif()
709
710endif()
711
712
713if (CONFIG_USE_driver_lpc_crc)
714# Add set(CONFIG_USE_driver_lpc_crc true) in config.cmake to use this component
715
716message("driver_lpc_crc component is included from ${CMAKE_CURRENT_LIST_FILE}.")
717
718if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
719
720target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
721  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_crc/fsl_crc.c
722)
723
724target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
725  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_crc/.
726)
727
728else()
729
730message(SEND_ERROR "driver_lpc_crc.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
731
732endif()
733
734endif()
735
736
737if (CONFIG_USE_driver_iap)
738# Add set(CONFIG_USE_driver_iap true) in config.cmake to use this component
739
740message("driver_iap component is included from ${CMAKE_CURRENT_LIST_FILE}.")
741
742if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
743
744target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
745  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/iap/fsl_iap.c
746)
747
748target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
749  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/iap/.
750)
751
752else()
753
754message(SEND_ERROR "driver_iap.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
755
756endif()
757
758endif()
759
760
761if (CONFIG_USE_driver_inputmux)
762# Add set(CONFIG_USE_driver_inputmux true) in config.cmake to use this component
763
764message("driver_inputmux component is included from ${CMAKE_CURRENT_LIST_FILE}.")
765
766if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common AND CONFIG_USE_driver_inputmux_connections)
767
768target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
769  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/inputmux/fsl_inputmux.c
770)
771
772target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
773  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/inputmux/.
774)
775
776else()
777
778message(SEND_ERROR "driver_inputmux.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
779
780endif()
781
782endif()
783
784
785if (CONFIG_USE_driver_lpc_acomp)
786# Add set(CONFIG_USE_driver_lpc_acomp true) in config.cmake to use this component
787
788message("driver_lpc_acomp component is included from ${CMAKE_CURRENT_LIST_FILE}.")
789
790if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
791
792target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
793  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_acomp/fsl_acomp.c
794)
795
796target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
797  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_acomp/.
798)
799
800else()
801
802message(SEND_ERROR "driver_lpc_acomp.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
803
804endif()
805
806endif()
807
808
809if (CONFIG_USE_driver_lpc_adc)
810# Add set(CONFIG_USE_driver_lpc_adc true) in config.cmake to use this component
811
812message("driver_lpc_adc component is included from ${CMAKE_CURRENT_LIST_FILE}.")
813
814if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
815
816target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
817  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_adc/fsl_adc.c
818)
819
820target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
821  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_adc/.
822)
823
824else()
825
826message(SEND_ERROR "driver_lpc_adc.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
827
828endif()
829
830endif()
831
832
833if (CONFIG_USE_driver_lpc_dma)
834# Add set(CONFIG_USE_driver_lpc_dma true) in config.cmake to use this component
835
836message("driver_lpc_dma component is included from ${CMAKE_CURRENT_LIST_FILE}.")
837
838if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
839
840target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
841  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_dma/fsl_dma.c
842)
843
844target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
845  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_dma/.
846)
847
848else()
849
850message(SEND_ERROR "driver_lpc_dma.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
851
852endif()
853
854endif()
855
856
857if (CONFIG_USE_driver_lpc_gpio)
858# Add set(CONFIG_USE_driver_lpc_gpio true) in config.cmake to use this component
859
860message("driver_lpc_gpio component is included from ${CMAKE_CURRENT_LIST_FILE}.")
861
862if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
863
864target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
865  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_gpio/fsl_gpio.c
866)
867
868target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
869  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_gpio/.
870)
871
872else()
873
874message(SEND_ERROR "driver_lpc_gpio.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
875
876endif()
877
878endif()
879
880
881if (CONFIG_USE_driver_lpc_i2c)
882# Add set(CONFIG_USE_driver_lpc_i2c true) in config.cmake to use this component
883
884message("driver_lpc_i2c component is included from ${CMAKE_CURRENT_LIST_FILE}.")
885
886if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
887
888target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
889  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_i2c/fsl_i2c.c
890)
891
892target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
893  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_i2c/.
894)
895
896else()
897
898message(SEND_ERROR "driver_lpc_i2c.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
899
900endif()
901
902endif()
903
904
905if (CONFIG_USE_driver_lpc_iocon_lite)
906# Add set(CONFIG_USE_driver_lpc_iocon_lite true) in config.cmake to use this component
907
908message("driver_lpc_iocon_lite component is included from ${CMAKE_CURRENT_LIST_FILE}.")
909
910if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
911
912target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
913  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_iocon_lite/.
914)
915
916else()
917
918message(SEND_ERROR "driver_lpc_iocon_lite.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
919
920endif()
921
922endif()
923
924
925if (CONFIG_USE_driver_lpc_minispi)
926# Add set(CONFIG_USE_driver_lpc_minispi true) in config.cmake to use this component
927
928message("driver_lpc_minispi component is included from ${CMAKE_CURRENT_LIST_FILE}.")
929
930if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
931
932target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
933  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_minispi/fsl_spi.c
934)
935
936target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
937  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_minispi/.
938)
939
940else()
941
942message(SEND_ERROR "driver_lpc_minispi.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
943
944endif()
945
946endif()
947
948
949if (CONFIG_USE_driver_lpc_miniusart)
950# Add set(CONFIG_USE_driver_lpc_miniusart true) in config.cmake to use this component
951
952message("driver_lpc_miniusart component is included from ${CMAKE_CURRENT_LIST_FILE}.")
953
954if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
955
956target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
957  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_miniusart/fsl_usart.c
958)
959
960target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
961  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/lpc_miniusart/.
962)
963
964else()
965
966message(SEND_ERROR "driver_lpc_miniusart.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
967
968endif()
969
970endif()
971
972
973if (CONFIG_USE_driver_mrt)
974# Add set(CONFIG_USE_driver_mrt true) in config.cmake to use this component
975
976message("driver_mrt component is included from ${CMAKE_CURRENT_LIST_FILE}.")
977
978if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
979
980target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
981  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/mrt/fsl_mrt.c
982)
983
984target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
985  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/mrt/.
986)
987
988else()
989
990message(SEND_ERROR "driver_mrt.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
991
992endif()
993
994endif()
995
996
997if (CONFIG_USE_driver_pint)
998# Add set(CONFIG_USE_driver_pint true) in config.cmake to use this component
999
1000message("driver_pint component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1001
1002if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
1003
1004target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1005  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/pint/fsl_pint.c
1006)
1007
1008target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1009  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/pint/.
1010)
1011
1012else()
1013
1014message(SEND_ERROR "driver_pint.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1015
1016endif()
1017
1018endif()
1019
1020
1021if (CONFIG_USE_driver_reset)
1022# Add set(CONFIG_USE_driver_reset true) in config.cmake to use this component
1023
1024message("driver_reset component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1025
1026if(CONFIG_USE_driver_common AND (CONFIG_DEVICE_ID STREQUAL LPC824))
1027
1028target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1029  ${CMAKE_CURRENT_LIST_DIR}/drivers/fsl_reset.c
1030)
1031
1032target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1033  ${CMAKE_CURRENT_LIST_DIR}/drivers/.
1034)
1035
1036else()
1037
1038message(SEND_ERROR "driver_reset.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1039
1040endif()
1041
1042endif()
1043
1044
1045if (CONFIG_USE_driver_sctimer)
1046# Add set(CONFIG_USE_driver_sctimer true) in config.cmake to use this component
1047
1048message("driver_sctimer component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1049
1050if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
1051
1052target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1053  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/sctimer/fsl_sctimer.c
1054)
1055
1056target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1057  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/sctimer/.
1058)
1059
1060else()
1061
1062message(SEND_ERROR "driver_sctimer.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1063
1064endif()
1065
1066endif()
1067
1068
1069if (CONFIG_USE_driver_swm)
1070# Add set(CONFIG_USE_driver_swm true) in config.cmake to use this component
1071
1072message("driver_swm component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1073
1074if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common AND CONFIG_USE_driver_swm_connections)
1075
1076target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1077  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/swm/fsl_swm.c
1078)
1079
1080target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1081  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/swm/.
1082)
1083
1084else()
1085
1086message(SEND_ERROR "driver_swm.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1087
1088endif()
1089
1090endif()
1091
1092
1093if (CONFIG_USE_driver_syscon)
1094# Add set(CONFIG_USE_driver_syscon true) in config.cmake to use this component
1095
1096message("driver_syscon component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1097
1098if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common AND CONFIG_USE_driver_syscon_connections)
1099
1100target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1101  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/syscon/fsl_syscon.c
1102)
1103
1104target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1105  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/syscon/.
1106)
1107
1108else()
1109
1110message(SEND_ERROR "driver_syscon.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1111
1112endif()
1113
1114endif()
1115
1116
1117if (CONFIG_USE_driver_wkt)
1118# Add set(CONFIG_USE_driver_wkt true) in config.cmake to use this component
1119
1120message("driver_wkt component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1121
1122if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
1123
1124target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1125  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/wkt/fsl_wkt.c
1126)
1127
1128target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1129  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/wkt/.
1130)
1131
1132else()
1133
1134message(SEND_ERROR "driver_wkt.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1135
1136endif()
1137
1138endif()
1139
1140
1141if (CONFIG_USE_driver_wwdt)
1142# Add set(CONFIG_USE_driver_wwdt true) in config.cmake to use this component
1143
1144message("driver_wwdt component is included from ${CMAKE_CURRENT_LIST_FILE}.")
1145
1146if((CONFIG_DEVICE_ID STREQUAL LPC824) AND CONFIG_USE_driver_common)
1147
1148target_sources(${MCUX_SDK_PROJECT_NAME} PRIVATE
1149  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/wwdt/fsl_wwdt.c
1150)
1151
1152target_include_directories(${MCUX_SDK_PROJECT_NAME} PUBLIC
1153  ${CMAKE_CURRENT_LIST_DIR}/../../drivers/wwdt/.
1154)
1155
1156else()
1157
1158message(SEND_ERROR "driver_wwdt.LPC824 dependency does not meet, please check ${CMAKE_CURRENT_LIST_FILE}.")
1159
1160endif()
1161
1162endif()
1163
1164