ConOpSys V2970  P004.07
ANVILEX control operating system
Hardware_Platform_P017_39.h
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
2 // Runtime engine: P017.39 CB V1
3 //------------------------------------------------------------------------------
4 
5 #pragma once
6 
7 //------------------------------------------------------------------------------
8 // Macro for disable semihosting
9 //------------------------------------------------------------------------------
10 
11 #if __ARMCC_VERSION >= 6000000
12  __asm(".global __use_no_semihosting");
13 #elif __ARMCC_VERSION >= 5000000
14  #pragma import(__use_no_semihosting)
15 #else
16  #error Unsupported compiler
17 #endif
18 
19 //------------------------------------------------------------------------------
20 // Include STM32F429 on chip hardware module headers
21 //------------------------------------------------------------------------------
22 
23 //#include "stm32f429xx.h"
24 
25 //------------------------------------------------------------------------------
26 // Hardware platform
27 //------------------------------------------------------------------------------
28 
29 #define HARDWARE_VERSION ( (C8*)"P017.39 V1" )
30 #define HARDWARE_ID ( (U32)3 )
31 
32 #include "P017_39_KG3_CB.h"
33 
35 
36 //------------------------------------------------------------------------------
37 // CPU
38 //------------------------------------------------------------------------------
39 
40 #include "CPU_STM32F429.h"
41 
43 
44 //------------------------------------------------------------------------------
45 // On chip memory
46 //------------------------------------------------------------------------------
47 
48 #include "STACK_STM32F429.h"
49 #include "HEAP_STM32F429.h"
50 
53 
54 //------------------------------------------------------------------------------
55 // On chip interrupt controller
56 //------------------------------------------------------------------------------
57 
58 #include "NVIC_STM32F429.h"
59 
60 //------------------------------------------------------------------------------
61 // On chip high resolution system timer
62 //------------------------------------------------------------------------------
63 
64 #include "TIMER2_STM32F429.h"
65 
67 
69 
70 //------------------------------------------------------------------------------
71 // On chip 1ms system timer
72 //------------------------------------------------------------------------------
73 
74 #include "SYSTICK_STM32F429.h"
75 
77 
79 
80 //------------------------------------------------------------------------------
81 // On chip system WDT
82 //------------------------------------------------------------------------------
83 
84 #include "WDT_STM32F429.h"
85 
87 
88 //------------------------------------------------------------------------------
89 // On chip system RTC
90 //------------------------------------------------------------------------------
91 
92 #include "RTC_STM32F429.h"
93 
95 
96 //------------------------------------------------------------------------------
97 // On chip system LED
98 //------------------------------------------------------------------------------
99 
100 #include "LED_P017_39_KG3_CB.h"
101 
102 // Export system LED
104 
105 //------------------------------------------------------------------------------
106 // On chip SPI1
107 //------------------------------------------------------------------------------
108 
109 #include "SPI5_P017_39_KG3_CB.h"
110 
111 // System SPI1 communication link object
113 
114 //------------------------------------------------------------------------------
115 // On chip SPI2
116 //------------------------------------------------------------------------------
117 
118 // System SPI2 communication link
119 #define SPI2_MODULE_INSTALLED (true)
120 
121 #include "SPI2_P017_39_KG3_CB.h"
122 
124 // extern TSPI2_P017_39_KG3_CB object_System_SPI2;
125 // extern TSPI2_P017_39_KG3_CB *object_System_SPI2;
126 
127 //------------------------------------------------------------------------------
128 // On chip SPI3
129 //------------------------------------------------------------------------------
130 
131 // System SPI3 communication link
132 //#define SPI3_MODULE_INSTALLED (false)
133 
134 #include "SPI4_P017_39_KG3_CB.h"
135 
137 
138 //------------------------------------------------------------------------------
139 // On chip ADC
140 //------------------------------------------------------------------------------
141 
142 #ifndef ADC_MODULE_INSTALLED
143 
144  //----------------------------------------------------------------------------
145  // ERROR: Undefined compilation switch: ADC_MODULE_INSTALLED
146  //----------------------------------------------------------------------------
147 
148  // Show error message
149  #error ERROR: Undefined compilation switch: ADC_MODULE_INSTALLED
150 
151 #else
152 
153  //----------------------------------------------------------------------------
154  // Compilation switch setted
155  //----------------------------------------------------------------------------
156 
157 #endif
158 
159 //------------------------------------------------------------------------------
160 // On chip DAC
161 //------------------------------------------------------------------------------
162 
163 #ifndef DAC_MODULE_INSTALLED
164 
165  //----------------------------------------------------------------------------
166  // ERROR: Undefined compilation switch: DAC_MODULE_INSTALLED
167  //----------------------------------------------------------------------------
168 
169  // Show error message
170  #error "ERROR: Undefined compilation switch: DAC_MODULE_INSTALLED"
171 
172 #else
173 
174  //----------------------------------------------------------------------------
175  // Compilation switch setted
176  //----------------------------------------------------------------------------
177 
178 #endif
179 
180 //------------------------------------------------------------------------------
181 // On chip DIO module
182 //------------------------------------------------------------------------------
183 
184 #ifndef DIO_MODULE_INSTALLED
185 
186  //----------------------------------------------------------------------------
187  // ERROR: Undefined compilation switch: DIO_MODULE_INSTALLED
188  //----------------------------------------------------------------------------
189 
190  // Show error message
191  #error "ERROR: Undefined compilation switch: DIO_MODULE_INSTALLED"
192 
193 #else
194 
195  //----------------------------------------------------------------------------
196  // Compilation switch setted
197  //----------------------------------------------------------------------------
198 
199 #endif
200 
201 //------------------------------------------------------------------------------
202 // FPGA on board chip
203 //------------------------------------------------------------------------------
204 
205 #ifndef FPGA_MODULE_INSTALLED
206 
207  //----------------------------------------------------------------------------
208  // ERROR: Undefined compilation switch: FPGA_MODULE_INSTALLED
209  //----------------------------------------------------------------------------
210 
211  // Show error message
212  #error ERROR: Undefined compilation switch: FPGA_MODULE_INSTALLED
213 
214 #else
215 
216  //----------------------------------------------------------------------------
217  // Compilation switch setted
218  //----------------------------------------------------------------------------
219 
220  #include "FPGA_P017_39_KG3_CB.h"
221 
222  extern TFPGA_P017_39_KG3_CB object_System_FPGA;
223 
224  extern "C" VOID FPGA_Interrupt_Handler();
225 
226  // Test for FPGA module installed
227  #if ( FPGA_MODULE_INSTALLED == (true) )
228 
229  //--------------------------------------------------------------------------
230  // FPGA base address
231  //--------------------------------------------------------------------------
232 
233  // ANVILEX KM: Move this difinition to the scatter file as a section
234  #define FPGA_BASE ((U32)0x60000000)
235  //#define FPGA_SIZE (0x00010000)
236 
237  //--------------------------------------------------------------------------
238  // Slot base address definitions
239  //--------------------------------------------------------------------------
240 
241  // PDB address slot size
242  #define FPGA_ADDRESS_SLOT_SIZE (0x40)
243 
244  // Backlane slot segmentation
245  #define FPGA_BACKPLANE_SLOT_AREA_OFFSET (U32)0x00001000
246 
247  // Internal slot segmentation
248  #define FPGA_INTERNAL_SLOT_AREA_OFFSET (U32)0x00000000
249 
250  //--------------------------------------------------------------------------
251 
252  #define FPGA_BACKPLANE_SLOT_1 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 0 * FPGA_ADDRESS_SLOT_SIZE ) )
253  #define FPGA_BACKPLANE_SLOT_2 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 1 * FPGA_ADDRESS_SLOT_SIZE ) )
254  #define FPGA_BACKPLANE_SLOT_3 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 2 * FPGA_ADDRESS_SLOT_SIZE ) )
255  #define FPGA_BACKPLANE_SLOT_4 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 3 * FPGA_ADDRESS_SLOT_SIZE ) )
256  #define FPGA_BACKPLANE_SLOT_5 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 4 * FPGA_ADDRESS_SLOT_SIZE ) )
257  #define FPGA_BACKPLANE_SLOT_6 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 5 * FPGA_ADDRESS_SLOT_SIZE ) )
258  #define FPGA_BACKPLANE_SLOT_7 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 6 * FPGA_ADDRESS_SLOT_SIZE ) )
259  #define FPGA_BACKPLANE_SLOT_8 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 7 * FPGA_ADDRESS_SLOT_SIZE ) )
260  #define FPGA_BACKPLANE_SLOT_9 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 8 * FPGA_ADDRESS_SLOT_SIZE ) )
261  #define FPGA_BACKPLANE_SLOT_10 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 9 * FPGA_ADDRESS_SLOT_SIZE ) )
262  #define FPGA_BACKPLANE_SLOT_11 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 10 * FPGA_ADDRESS_SLOT_SIZE ) )
263  #define FPGA_BACKPLANE_SLOT_12 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 11 * FPGA_ADDRESS_SLOT_SIZE ) )
264  #define FPGA_BACKPLANE_SLOT_13 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 12 * FPGA_ADDRESS_SLOT_SIZE ) )
265  #define FPGA_BACKPLANE_SLOT_14 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 13 * FPGA_ADDRESS_SLOT_SIZE ) )
266  #define FPGA_BACKPLANE_SLOT_15 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 14 * FPGA_ADDRESS_SLOT_SIZE ) )
267  #define FPGA_BACKPLANE_SLOT_16 ( FPGA_BASE + FPGA_BACKPLANE_SLOT_AREA_OFFSET + ( 15 * FPGA_ADDRESS_SLOT_SIZE ) )
268 
269  #define FPGA_INTERNAL_SLOT_1 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 0 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
270  #define FPGA_INTERNAL_SLOT_2 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 1 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
271  #define FPGA_INTERNAL_SLOT_3 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 2 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
272  #define FPGA_INTERNAL_SLOT_4 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 3 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
273  #define FPGA_INTERNAL_SLOT_5 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 4 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
274  #define FPGA_INTERNAL_SLOT_6 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 5 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
275  #define FPGA_INTERNAL_SLOT_7 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 6 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
276  #define FPGA_INTERNAL_SLOT_8 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 7 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
277  #define FPGA_INTERNAL_SLOT_9 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 8 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
278  #define FPGA_INTERNAL_SLOT_10 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 9 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
279  #define FPGA_INTERNAL_SLOT_11 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 10 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
280  #define FPGA_INTERNAL_SLOT_12 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 11 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
281  #define FPGA_INTERNAL_SLOT_13 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 12 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
282  #define FPGA_INTERNAL_SLOT_14 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 13 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
283  #define FPGA_INTERNAL_SLOT_15 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 14 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
284  #define FPGA_INTERNAL_SLOT_16 ( FPGA_BASE + FPGA_INTERNAL_SLOT_AREA_OFFSET + ( 15 * FPGA_ADDRESS_SLOT_SIZE ) ) //!<
285 
286  #endif
287 
288 #endif
289 
290 //------------------------------------------------------------------------------
291 // Virtual communication link COM0
292 //------------------------------------------------------------------------------
293 
294 #ifndef COM1_COMMUNICATION_MODE
295 
296  //----------------------------------------------------------------------------
297  // Undefined compilation switch: COM1_COMMUNICATION_MODE
298  //----------------------------------------------------------------------------
299 
300  // Show error message
301  #error ERROR: Undefined compilation switch: COM1_COMMUNICATION_MODE
302 
303 #else
304 
305  //----------------------------------------------------------------------------
306  // Compilation switch setted
307  //----------------------------------------------------------------------------
308 
309  #include "System_COM0.h"
310 
311  extern TCOM0 object_System_COM0;
312 
313  #if ( COM1_COMMUNICATION_MODE == (true) )
314 
315  //--------------------------------------------------------------------------
316  // Communication link COM0 installed
317  //--------------------------------------------------------------------------
318 
319  #include "Protocol_PLUG_Over_UART.h"
320 
322 
323  #endif
324 
325 #endif
326 
327 //------------------------------------------------------------------------------
328 // Communication link COM1
329 //------------------------------------------------------------------------------
330 
331 #ifndef COM1_COMMUNICATION_MODE
332 
333  //----------------------------------------------------------------------------
334  // Undefined compilation switch: COM1_COMMUNICATION_MODE
335  //----------------------------------------------------------------------------
336 
337  // Show error message
338  #error "ERROR: Undefined compilation switch: COM1_COMMUNICATION_MODE"
339 
340 #else
341 
342  //----------------------------------------------------------------------------
343  // Compilation switch setted
344  //----------------------------------------------------------------------------
345 
346  #include "UART1_P017_39_KG3_CB.h"
347 
348  extern TUART1_P017_39_KG3_CB object_System_COM1;
349 
350  extern "C" VOID System_UART1_Interrupt_Handler();
351 
352  #if ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_NONE )
353 
354  //----------------------------------------------------------------------------
355  // Mount DUMMY protocol to COM1
356  //----------------------------------------------------------------------------
357 
358  #include "Protocol_PLUG_Over_UART.h"
359 
360  // Export DUMMY protocol over COM2 object reference
361  extern TProtocol_PLUG_Over_UART object_Protocol_Over_COM1;
362 
363  #elif ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX )
364 
365  //----------------------------------------------------------------------------
366  // Mount ANVILEX slave protocol to COM1
367  //----------------------------------------------------------------------------
368 
370 
371  // Export ANVILEX protocol over COM1 object reference
372  extern TProtocol_ANVILEX_Over_UART object_Protocol_Over_COM1;
373 
374  #elif ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX_V2 )
375 
376  //----------------------------------------------------------------------------
377  // Mount ANVILEX slave V2 protocol to COM1
378  //----------------------------------------------------------------------------
379 
381 
382  // Export ANVILEX protocol over COM1 object reference
383  extern TProtocol_ANVILEX_Over_UART_V2 object_Protocol_Over_COM1;
384 
385  #elif ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX_MASTER )
386 
387  //----------------------------------------------------------------------------
388  // Mount ANVILEX master protocol to COM1
389  //----------------------------------------------------------------------------
390 
392 
393  // Export ANVILEX master protocol over COM2 object reference
394  extern TProtocol_ANVILEX_Master_Over_UART object_Protocol_Over_COM1;
395 
396  #elif ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_RTU )
397 
398  //----------------------------------------------------------------------------
399  // Mount MODBUS RTU protocol to COM1
400  //----------------------------------------------------------------------------
401 
402  #include "Protocol_MODBUS_Over_UART.h"
403 
404  // Export MODBUS RTU protocol over COM2 object reference
405  extern TProtocol_MODBUS_Over_UART object_Protocol_Over_COM1;
406 
407  #elif ( COM1_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_ASCII )
408 
409  //----------------------------------------------------------------------------
410  // Mount MODBUS ASCII protocol to COM1
411  //----------------------------------------------------------------------------
412 
413  // Export MODBUS ASCII protocol over COM1
414  // ANVILEX KM: Reserved for the future
415 
416  // ANVILEX: Show error message
417  #error "ERROR: MODBUS ASCII communication mode not implemented for COM1."
418 
419  #else
420 
421  //--------------------------------------------------------------------------
422  // Unknown communication protocol linked to COM1
423  //--------------------------------------------------------------------------
424 
425  // Show error message
426  #error "ERROR: Undefined or unknown communication mode for COM1."
427 
428  #endif
429 
430 #endif
431 
432 //------------------------------------------------------------------------------
433 // Communication link COM2
434 //------------------------------------------------------------------------------
435 
436 #ifndef COM2_COMMUNICATION_MODE
437 
438  //----------------------------------------------------------------------------
439  // Undefined compilation switch: COM2_COMMUNICATION_MODE
440  //----------------------------------------------------------------------------
441 
442  // Show error message
443  #error "ERROR: Undefined compilation switch: COM2_COMMUNICATION_MODE"
444 
445 #else
446 
447  //----------------------------------------------------------------------------
448  // Compilation switch setted
449  //----------------------------------------------------------------------------
450 
451  #include "UART6_P017_39_KG3_CB.h"
452 
453  extern TUART6_P017_39_KG3_CB object_System_COM2;
454 
455  extern "C" VOID System_UART6_Interrupt_Handler();
456 
457  #if ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_NONE )
458 
459  //----------------------------------------------------------------------------
460  // Export mounted DUMMY protocol to COM2
461  //----------------------------------------------------------------------------
462 
463  // Export DUMMY protocol over COM2 object reference
464  extern TProtocol_PLUG_Over_UART object_Protocol_Over_COM2;
465 
466  #elif ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX )
467 
468  //----------------------------------------------------------------------------
469  // Export mounted ANVILEX protocol to COM2
470  //----------------------------------------------------------------------------
471 
472  // Export ANVILEX protocol over COM2 object reference
473  extern TProtocol_ANVILEX_Over_UART object_Protocol_Over_COM2;
474 
475  #elif ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX_V2 )
476 
477  //----------------------------------------------------------------------------
478  // Export mounted ANVILEX protocol to COM2
479  //----------------------------------------------------------------------------
480 
481  // Export ANVILEX protocol over COM2 object reference
482  extern TProtocol_ANVILEX_Over_UART_V2 object_Protocol_Over_COM2;
483 
484  #elif ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX_MASTER )
485 
486  //----------------------------------------------------------------------------
487  // Export mounted ANVILEX master protocol to COM2
488  //----------------------------------------------------------------------------
489 
490  // Export ANVILEX master protocol over COM2 object reference
491  extern TProtocol_ANVILEX_Master_Over_UART object_Protocol_Over_COM2;
492 
493  #elif ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_RTU )
494 
495  //----------------------------------------------------------------------------
496  // Export mounted MODBUS RTU protocol to COM2
497  //----------------------------------------------------------------------------
498 
499  // Export MODBUS RTU protocol over COM2 object reference
500  extern TProtocol_MODBUS_Over_UART object_Protocol_Over_COM2;
501 
502  #elif ( COM2_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_ASCII )
503 
504  //----------------------------------------------------------------------------
505  // Export mounted MODBUS ASCII protocol to COM2
506  //----------------------------------------------------------------------------
507 
508  // Export MODBUS ASCII protocol over COM2
509  // ANVILEX KM: Reserved for the future
510 
511  // ANVILEX: Show error message
512  #error "ERROR: MODBUS ASCII communication mode not implemented for COM2."
513 
514  #else
515 
516  //--------------------------------------------------------------------------
517  // Unknown communication protocol linked to COM2
518  //--------------------------------------------------------------------------
519 
520  // Show error message
521  #error "ERROR: Undefined or unknown communication mode for COM2."
522 
523  #endif
524 
525 #endif
526 
527 //------------------------------------------------------------------------------
528 // Communication link COM3
529 //------------------------------------------------------------------------------
530 
531 #ifndef COM3_COMMUNICATION_MODE
532 
533  //----------------------------------------------------------------------------
534  // Undefined compilation switch: COM3_COMMUNICATION_MODE
535  //----------------------------------------------------------------------------
536 
537  // Show error message
538  #error "ERROR: Undefined compilation switch: COM3_COMMUNICATION_MODE"
539 
540 #else
541 
542  //----------------------------------------------------------------------------
543  // Compilation switch setted
544  //----------------------------------------------------------------------------
545 
546  #include "UART7_P017_39_KG3_CB.h"
547 
548  extern TUART7_P017_39_KG3_CB object_System_COM3;
549 
550  extern "C" VOID System_COM3_Interrupt_Handler();
551 
552  #if ( COM3_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_NONE )
553 
554  //--------------------------------------------------------------------------
555  // Export mounted DUMMY protocol to COM3
556  //--------------------------------------------------------------------------
557 
558  // Export DUMMY protocol over COM3 object reference
559  extern TProtocol_PLUG_Over_UART object_Protocol_Over_COM3;
560 
561  #elif ( COM3_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_ANVILEX )
562 
563  //--------------------------------------------------------------------------
564  // Export mounted ANVILEX protocol to COM3
565  //--------------------------------------------------------------------------
566 
567  // Export ANVILEX protocol over COM3 object reference
568  extern TProtocol_ANVILEX_Over_UART object_Protocol_Over_COM3;
569 
570  #elif ( COM3_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_RTU )
571 
572  //--------------------------------------------------------------------------
573  // Export mounted MODBUS RTU protocol to COM3
574  //--------------------------------------------------------------------------
575 
576  // Export MODBUS RTU protocol over COM3 object reference
577  extern TProtocol_MODBUS_Over_UART object_Protocol_Over_COM3;
578 
579  #elif ( COM3_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_MODBUS_ASCII )
580 
581  //--------------------------------------------------------------------------
582  // Export mounted MODBUS ASCII protocol to COM3
583  //--------------------------------------------------------------------------
584 
585  // Export MODBUS ASCII protocol over COM3
586  // ANVILEX KM: Reserved for the future
587 
588  // ANVILEX: Show error message
589  #error "ERROR: MODBUS ASCII communication mode not implemented for COM3."
590 
591  #elif ( COM3_COMMUNICATION_MODE == USART_COMMUNICATION_MODE_SIMCOM )
592 
593  //--------------------------------------------------------------------------
594  // Export mounted SIMCOM protocol to COM3
595  //--------------------------------------------------------------------------
596 
597  // Export SIMCOM protocol over COM3
598  // ANVILEX KM: Reserved for the future
599 
600  // ANVILEX: Show error message
601  #error "ERROR: SIMCOM communication mode not implemented for COM3."
602 
603  #else
604 
605  //--------------------------------------------------------------------------
606  // Unknown communication protocol linked to COM3
607  //--------------------------------------------------------------------------
608 
609  // Show error message
610  #error "ERROR: Undefined or unknown communication mode for COM3."
611 
612  #endif
613 
614 #endif
615 
616 //------------------------------------------------------------------------------
617 // Communication link ETHERNET
618 //------------------------------------------------------------------------------
619 
620 #ifndef ETHERNET_MODULE_INSTALLED
621 
622  //----------------------------------------------------------------------------
623  // Undefined compilation switch: ETHERNET_MODULE_INSTALLED
624  //----------------------------------------------------------------------------
625 
626  // Show error message
627  #error "ERROR: Undefined compilation switch: ETHERNET_MODULE_INSTALLED"
628 
629 #else
630 
631  //----------------------------------------------------------------------------
632  // Compilation switch setted
633  //----------------------------------------------------------------------------
634 
635  #include "ETHERNET_P017_39_CB.h"
636 
637  extern TETHERNET_P017_39_CB object_System_ETHERNET;
638 
639  extern "C" VOID System_ETH_Interrupt_Handler();
640 
641  #if ( ETHERNET_MODULE_INSTALLED == true )
642 
643  #include "Protocol_IP_Over_ETHERNET.h"
644 
645  // Export IP protocol over ETHERNET object reference
647 
648  #else
649 
650  //--------------------------------------------------------------------------
651  // Unknown communication protocol linked to ETHERNET
652  //--------------------------------------------------------------------------
653 
654  // Show error message
655 // #error ERROR: Undefined or unknown communication mode for ETHERNET.
656 
657  #endif
658 
659 #endif
660 
661 //------------------------------------------------------------------------------
662 // Communication link CAN1
663 //------------------------------------------------------------------------------
664 
665 #ifndef CAN1_MODULE_INSTALLED
666 
667  //----------------------------------------------------------------------------
668  // Undefined compilation switch: CAN1_MODULE_INSTALLED
669  //----------------------------------------------------------------------------
670 
671  // Show error message
672  #error "ERROR: Undefined compilation switch: CAN1_MODULE_INSTALLED"
673 
674 #else
675 
676  //----------------------------------------------------------------------------
677  // Compilation switch setted
678  //----------------------------------------------------------------------------
679 
680  // Include CAN related headers
681  #include "CAN1_P017_39_KG3_CB.h"
682  #include "CAN2_P017_39_KG3_CB.h"
683 
684  extern TCAN1_P017_39_KG3_CB object_System_CAN1;
685  extern TCAN2_P017_39_KG3_CB object_System_CAN2;
686 
687  extern "C" VOID System_CAN1_RX0_Interrupt_Handler();
688  extern "C" VOID System_CAN1_RX1_Interrupt_Handler();
689  extern "C" VOID System_CAN1_TX_Interrupt_Handler();
690  extern "C" VOID System_CAN1_SCE_Interrupt_Handler();
691  extern "C" VOID System_CAN2_RX0_Interrupt_Handler();
692  extern "C" VOID System_CAN2_RX1_Interrupt_Handler();
693  extern "C" VOID System_CAN2_TX_Interrupt_Handler();
694  extern "C" VOID System_CAN2_SCE_Interrupt_Handler();
695 
696  #if ( CAN1_MODULE_INSTALLED == (true) )
697 
698  //--------------------------------------------------------------------------
699  // Mount CANopen protocol to CAN1
700  //--------------------------------------------------------------------------
701 
703 
705 
706  #else
707 
708  //--------------------------------------------------------------------------
709  // Unknown communication protocol linked to CAN1
710  //--------------------------------------------------------------------------
711 
712  // Show error message
713 // #error ERROR: Undefined or unknown communication mode for CAN1.
714 
715  #endif
716 
717 #endif
718 
719 //------------------------------------------------------------------------------
720 // Include ANYBUS module headers
721 //------------------------------------------------------------------------------
722 
723 #ifndef ADDISIONAL_MODULE_COMMUNICATION
724 
725  //----------------------------------------------------------------------------
726  // Undefined compilation switch: ADDISIONAL_MODULE_COMMUNICATION
727  //----------------------------------------------------------------------------
728 
729  // Show error message
730  #error "ERROR: Undefined compilation switch: ADDISIONAL_MODULE_COMMUNICATION"
731 
732 #else
733 
734  //----------------------------------------------------------------------------
735  // Compilation switch setted
736  //----------------------------------------------------------------------------
737 
738  // Test for PROFIBUS DPV1 module enabled
739  #if ( ADDISIONAL_MODULE_COMMUNICATION == PB_DPV_1 )
740 
741  //--------------------------------------------------------------------------
742  // Mount PROFIBUS DPV1 protocol to ANYBUS
743  //--------------------------------------------------------------------------
744 
745  // AnyBus includes
746  #include "ABCC_Base.h"
747  #include "ABCC_DPV1.h"
748 
749 // AnyBus includes
750 // ANVILEX KM: Move to ABCC object
751 /*
752  #include "abcc_drv_cfg.h"
753  #include "abcc.h"
754  #include "abcc_sys_adapt.h"
755  #include "ad_obj.h"
756  #include "appl_abcc_handler.h"
757  #include "abcc_versions.h"
758  #include "appl_adi_config.h"
759 */
760 
761  //! @brief Export ABCC objejct
762  extern TABCC_DPV1 object_ABCC;
763 
764  #else
765 
766  //--------------------------------------------------------------------------
767  // Unknown communication protocol linked to ANYBUS
768  //--------------------------------------------------------------------------
769 
770  // Show error message
771 // #error ERROR: Undefined or unknown communication mode for ANYBUS.
772 
773  #endif
774 
775 #endif
776 
777 //------------------------------------------------------------------------------
778 // System terminal
779 //------------------------------------------------------------------------------
780 
781 // Export pointer to system terminal object
783 
784 //----------------------------------------------------------------------------
785 // Parameter database
786 //----------------------------------------------------------------------------
787 
788 #include "Parameter_Manager.h"
789 
790 #include "FM25V02.h"
791 
792 //------------------------------------------------------------------------------
793 // Command manager
794 //------------------------------------------------------------------------------
795 
796 #ifndef COMMAND_MANAGER_MODULE_INSTALLED
797 
798  //----------------------------------------------------------------------------
799  // Undefined compilation switch: COMMAND_MANAGER_MODULE_INSTALLED
800  //----------------------------------------------------------------------------
801 
802  // Show error message
803  #error "ERROR: Undefined compilation switch: COMMAND_MANAGER_MODULE_INSTALLED"
804 
805 #else
806 
807  //----------------------------------------------------------------------------
808  // Compilation switch setted
809  //----------------------------------------------------------------------------
810 
811  // Test for command manager installed
812  #if ( COMMAND_MANAGER_MODULE_INSTALLED == (true) )
813 
814  //--------------------------------------------------------------------------
815  // Mount command manager
816  //--------------------------------------------------------------------------
817 
818  #include "Command_Manager.h"
819 
820  // Export global command manager object
822 
823  #endif
824 
825 #endif
826 
827 //------------------------------------------------------------------------------
828 // Event manager
829 //------------------------------------------------------------------------------
830 
831 #ifndef EVENT_MANAGER_MODULE_INSTALLED
832 
833  //----------------------------------------------------------------------------
834  // Undefined compilation switch: EVENT_MANAGER_MODULE_INSTALLED
835  //----------------------------------------------------------------------------
836 
837  // Show error message
838  #error ERROR: Undefined compilation switch: EVENT_MANAGER_MODULE_INSTALLED
839 
840 #else
841 
842  //----------------------------------------------------------------------------
843  // Compilation switch setted
844  //----------------------------------------------------------------------------
845 
846  // Test for command manager installed
847  #if ( EVENT_MANAGER_MODULE_INSTALLED == (true) )
848 
849  //--------------------------------------------------------------------------
850  // Mount event manager
851  //--------------------------------------------------------------------------
852 
853 // const BOOL bool_Configuration_Event_Database_Flash_Istalled = (BOOL)true;
854 
855  #define EVENT_DATABASE_STORAGE_INSTALLED (true)
856 
857  #include "S25FL512.h"
858 
859  extern TS25FL512 *object_Event_Database_Storage;
860 
861  #include "Event_Manager.h"
862 
863  //! @brief Export global event manager object
864  extern TEvent_Manager object_Event_Manager;
865 
866  #endif
867 
868 #endif
869 
870 //------------------------------------------------------------------------------
871 // Signal recorder
872 //------------------------------------------------------------------------------
873 
874 #ifndef SCOPE_MODULE_INSTALLED
875 
876  //----------------------------------------------------------------------------
877  // Undefined compilation switch: SCOPE_MODULE_INSTALLED
878  //----------------------------------------------------------------------------
879 
880  // Show error message
881  #error "ERROR: Undefined compilation switch: SCOPE_MODULE_INSTALLED"
882 
883 #else
884 
885  //----------------------------------------------------------------------------
886  // Compilation switch setted
887  //----------------------------------------------------------------------------
888 
889  // Test for signal recorder installed
890  #if ( SCOPE_MODULE_INSTALLED == (true) )
891 
892  //--------------------------------------------------------------------------
893  // Mount event manager
894  //--------------------------------------------------------------------------
895 
896  #include "Signal_Recorder.h"
897 
898  extern TSignal_Recorder object_Signal_Recorder;
899 
900  #endif
901 
902 #endif
903 
904 //------------------------------------------------------------------------------
905 // Include files related to the system objects
906 //------------------------------------------------------------------------------
907 
908 #include "Function_Block_Manager.h"
909 
910 //------------------------------------------------------------------------------
911 // End of file
912 //------------------------------------------------------------------------------
ANYBUS module base class header file.
ANYBUS Profibus module driver class header file.
STM32F429 on-chip CAN1 class header file.
STM32F429 on-chip CAN2 class for P017_39_KG3_CB header file.
STM32F429 CPU class header file.
ConOpSys command manager class header file.
void VOID
Datatypesess datatype definition.
Definition: Defines.h:105
System ETHERNET communication link unit.
Event manager class header file.
NVRAM chip FM25V02 hardware driver class header file.
FPGA driver calss header file for P017_39_KG3_CB.
Function block manager class header file.
STM32F429 heap class header file.
TWDT_STM32F429 object_System_Watchdog_Timer
TRTC_STM32F429 object_System_RTC
TSTACK_STM32F429 object_System_STACK
TTarget_P017_39_KG3_CB object_Target
THEAP_STM32F429 object_System_HEAP
VOID High_Precision_Timer_Interrupt_Handler()
TLED_P017_39_KG3_CB object_System_LED
VOID System_Timer_Interrupt_Handler()
TCPU_STM32F429 object_System_CPU
TTIMER2_STM32F429 object_Delay_Timer
TSPI5_P017_39_KG3_CB object_System_SPI1
TProtocol_Base * object_System_Terminal
TSPI_Master_Base * object_System_SPI2
TSPI4_P017_39_KG3_CB object_System_SPI3
TSYSTICK_STM32F429 object_System_Timer
P017.39 control board LED class header file.
STM32F429 on-chip NVIC module class header file.
VOID FPGA_Interrupt_Handler()
Definition: P013_35_V1_3_CPU.cpp:117
Target description unit.
ConOpSys parameter database manager class header file.
Communication protocol ANVILEX master over UART class header file.
Communication protocol ANVILEX over UART class header file.
Communication protocol ANVILEX over UART class header file.
Communication protocol CANopen over CAN class header file.
Communication protocol IP over Ethernet class header file.
Communication protocol MODBUS RTU over UART class header file.
Dummy communication protocol over UART class header file.
STM32F429 on-chip RTC module class header file.
SPI NAND FLASH memory chip S25FL512 hardware driver class header file.
STM32F429 SPI2 master class header file.
STM32F429 SPI4 master class header file.
STM32F429 SPI5 master class header file.
STM32F429 stack class header file.
STM32F429 on-chip SYSTICK timer module class header file.
Signal recorder class header file.
Virtual communication link COM0 class header file.
TABCC_DPV1 object_ABCC
ABCC global object instance.
Definition: System_Resource.cpp:1452
TProtocol_PLUG_Over_UART object_Protocol_Over_COM0
Definition: System_Resource.cpp:1177
TProtocol_CANopen_Slave_Over_CAN object_Protocol_Over_CAN
CANopen slave protocol over CAN global object instance.
Definition: System_Resource.cpp:1438
TCommand_Manager object_Command_Manager
Command manager global object instance.
Definition: System_Resource.cpp:1464
TProtocol_IP_Over_ETHERNET object_Protocol_Over_ETHERNET
IP protocol over ETHERNET global object instance.
Definition: System_Resource.cpp:1427
STM32F429 on-chip TIMER2 module class header file.
System UART communication link unit.
System UART communication link unit.
System UART communication link unit.
STM32F429 on-chip WTD module class header file.
Definition: ABCC_DPV1.h:111
STM32F429 on-chip CAN1 hardware abstraction layer class for P017_39_KG3_CB.
Definition: CAN1_P017_39_KG3_CB.h:70
STM32F429 on-chip CAN2 hardware abstraction layer class for P017_39_KG3_CB.
Definition: CAN2_P017_39_KG3_CB.h:71
Virtual communication link COM0 class.
Definition: System_COM0.h:91
STM32F429 CPU hardware class.
Definition: CPU_STM32F429.h:69
ConOpSys terminal command manager class.
Definition: Command_Manager.h:86
STM32F429 on-chip Ethernet hardware abstraction layer class for P017_39_CB.
Definition: ETHERNET_P017_39_CB.h:95
Event manager class.
Definition: Event_Manager.h:70
FPGA hardware dependent driver class for P017_39_KG3_CB.
Definition: FPGA_P017_39_KG3_CB.h:75
STM32F429 heap class.
Definition: HEAP_STM32F429.h:63
P017.39 control board system LED class.
Definition: LED_P017_39_KG3_CB.h:57
Communication protocol ANVILEX master over UART class.
Definition: Protocol_ANVILEX_Master_Over_UART.h:62
Communication protocol ANVILEX over UART class.
Definition: Protocol_ANVILEX_Over_UART_V2.h:62
Communication protocol ANVILEX over UART class.
Definition: Protocol_ANVILEX_Over_UART.h:60
Definition: Protocol_Base.h:57
Communication protocol CANopen over CAN class.
Definition: Protocol_CANopen_Slave_Over_CAN.h:60
Communication protocol IP over ETHERNET class.
Definition: Protocol_IP_Over_ETHERNET.h:61
Communication protocol MODBUS RTU over UART class.
Definition: Protocol_MODBUS_Over_UART.h:82
Dummy communication protocol over UART class implementation.
Definition: Protocol_PLUG_Over_UART.h:54
STM32F429 RTC class.
Definition: RTC_STM32F429.h:71
NAND memory hardware driver.
Definition: S25FL512.h:62
On chip SPI4 bus master unit class.
Definition: SPI4_P017_39_KG3_CB.h:53
On chip SPI5 bus master unit class.
Definition: SPI5_P017_39_KG3_CB.h:53
SPI master base class.
Definition: SPI_Master_Base.h:58
STM32F429 stack class.
Definition: STACK_STM32F429.h:63
STM32F429 interval timer class.
Definition: SYSTICK_STM32F429.h:55
Signal recorder class.
Definition: Signal_Recorder.h:135
System timer class.
Definition: TIMER2_STM32F429.h:55
Target P017_39_KG3_CB class.
Definition: P017_39_KG3_CB.h:61
STM32F429 on-chip UART1 hardware abstraction layer class for P017_39_KG3_CB.
Definition: UART1_P017_39_KG3_CB.h:97
STM32F429 on-chip UART6 hardware abstraction layer class for P017_39_KG3_CB.
Definition: UART6_P017_39_KG3_CB.h:95
STM32F429 on-chip UART7 hardware abstraction layer class for P017_39_KG3_CB.
Definition: UART7_P017_39_KG3_CB.h:95
STM32F429 on-chip WDT module class.
Definition: WDT_STM32F429.h:70