1root { 2 platform { 3 template uart_controller { 4 match_attr = ""; 5 id = 0; 6 baudrate = 115200; 7 8 pin_tx_type = 0; 9 pin_tx_pin = 0; 10 pin_tx_mux = 0; 11 pin_tx_pull = 0; 12 13 pin_rx_type = 0; 14 pin_rx_pin = 0; 15 pin_rx_mux = 0; 16 pin_rx_pull = 0; 17 18 use_mode_type = 0; 19 use_mode_tx_dma_ch = 0; 20 use_mode_rx_dma_ch = 0; 21 22 rx_timeout_mode = 1; 23 } 24 controller_uart0 :: uart_controller { 25 match_attr = "goodix_gr55xx_uart_0"; 26 id = 0; /* APP_UART_ID_0 */ 27 baudrate = 115200; 28 pin_tx_type = 0; /* APP_IO_TYPE_NORMAL */ 29 pin_tx_pin = 10; /* APP_IO_PIN_10 */ 30 pin_tx_mux = 2; /* APP_IO_MUX_2 */ 31 pin_tx_pull = 1; /* APP_IO_PULLUP */ 32 33 pin_rx_type = 0; /* APP_IO_TYPE_NORMAL */ 34 pin_rx_pin = 11; /* APP_IO_PIN_11 */ 35 pin_rx_mux = 2; /* APP_IO_MUX_2 */ 36 pin_rx_pull = 1; /* APP_IO_PULLUP */ 37 38 use_mode_type = 0; /* APP_UART_TYPE_INTERRUPT */ 39 use_mode_tx_dma_ch = 0; /* DMA_Channel0 */ 40 use_mode_rx_dma_ch = 1; /* DMA_Channel1 */ 41 42 rx_timeout_mode = 1; /* UART_RECEIVER_TIMEOUT_ENABLE */ 43 } 44 controller_uart1 :: uart_controller { 45 match_attr = "goodix_gr55xx_uart_1"; 46 id = 1; /* APP_UART_ID_1 */ 47 baudrate = 115200; 48 pin_tx_type = 0; /* APP_IO_TYPE_NORMAL */ 49 pin_tx_pin = 9; /* APP_IO_PIN_7 */ 50 pin_tx_mux = 3; /* APP_IO_MUX_3 */ 51 pin_tx_pull = 1; /* APP_IO_PULLUP */ 52 53 pin_rx_type = 0; /* APP_IO_TYPE_NORMAL */ 54 pin_rx_pin = 8; /* APP_IO_PIN_6 */ 55 pin_rx_mux = 3; /* APP_IO_MUX_3 */ 56 pin_rx_pull = 1; /* APP_IO_PULLUP */ 57 58 use_mode_type = 0; /* APP_UART_TYPE_INTERRUPT */ 59 60 rx_timeout_mode = 1; /* UART_RECEIVER_TIMEOUT_ENABLE */ 61 } 62 } 63} 64