HPM SDK
HPMicro Software Development Kit
hpm_mipi_csi_phy_drv.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2023 HPMicro
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  *
6  */
7 
8 #ifndef HPM_MIPI_CSI_PHY_DRV_H
9 #define HPM_MIPI_CSI_PHY_DRV_H
10 
18 #include "hpm_common.h"
19 #include "hpm_soc.h"
20 #include "hpm_mipi_csi_phy_regs.h"
21 
22 
23 typedef struct mipi_csi_phy_clane_config {
24  uint16_t t_term_en_ns; /* !< unit: nanosecond. Time for the Clock Lane receiver to enable the HS line termination, starting from the time point when Dn crosses VIL,MAX */
25  uint16_t t_settle_ns; /* !< unit: nanosecond. Time interval during which the HS receiver should ignore any Clock Lane HS transitions, starting from the beginning of TCLK-PREPARE */
27 
28 typedef struct mipi_csi_phy_dlane_config {
29  uint16_t t_term_en_ns; /* !< unit: nanosecond. Time for the Data Lane receiver to enable the HS line termination, starting from the time point when Dn crosses VIL,MAX */
30  uint16_t t_settle_ns; /* !< unit: nanosecond. Time interval during which the HS receiver shall ignore any Data Lane HS transitions, starting from the beginning of THS-PREPARE */
32 
33 typedef struct mipi_csi_phy_config {
37 
38 
39 
46 
54 
55 #ifdef __cplusplus
56 extern "C" {
57 #endif
58 
59 
60 #ifdef __cplusplus
61 }
62 #endif
63 
67 #endif /* HPM_MIPI_CSI_PHY_DRV_H */
struct mipi_csi_phy_config mipi_csi_phy_config_t
void mipi_csi_phy_init(MIPI_CSI_PHY_Type *ptr, mipi_csi_phy_config_t *cfg)
MIPI_CSI_PHY init.
Definition: hpm_mipi_csi_phy_drv.c:19
struct mipi_csi_phy_clane_config mipi_csi_phy_clane_config_t
void mipi_csi_phy_default_config(mipi_csi_phy_config_t *cfg)
get MIPI CSI PHY of default config
Definition: hpm_mipi_csi_phy_drv.c:10
struct mipi_csi_phy_dlane_config mipi_csi_phy_dlane_config_t
Definition: hpm_mipi_csi_phy_regs.h:12
Definition: hpm_mipi_csi_phy_drv.h:23
uint16_t t_term_en_ns
Definition: hpm_mipi_csi_phy_drv.h:24
uint16_t t_settle_ns
Definition: hpm_mipi_csi_phy_drv.h:25
Definition: hpm_mipi_csi_phy_drv.h:33
mipi_csi_phy_clane_config_t clane_cfg
Definition: hpm_mipi_csi_phy_drv.h:34
mipi_csi_phy_dlane_config_t dlane_cfg
Definition: hpm_mipi_csi_phy_drv.h:35
Definition: hpm_mipi_csi_phy_drv.h:28
uint16_t t_term_en_ns
Definition: hpm_mipi_csi_phy_drv.h:29
uint16_t t_settle_ns
Definition: hpm_mipi_csi_phy_drv.h:30