HPM SDK
HPMicro Software Development Kit
hpm_romapi_xpi_soc_def.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2021 HPMicro
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  *
6  */
7 
8 #ifndef HPM_ROMAPI_XPI_SOC_DEF_H
9 #define HPM_ROMAPI_XPI_SOC_DEF_H
10 
11 #include "hpm_common.h"
12 #include "hpm_romapi_xpi_def.h"
13 
14 /***********************************************************************************************************************
15  * Definitions
16  **********************************************************************************************************************/
17 
18 #define XPI_CLK_OUT_FREQ_OPTION_30MHz (1U)
19 #define XPI_CLK_OUT_FREQ_OPTION_50MHz (2U)
20 #define XPI_CLK_OUT_FREQ_OPTION_66MHz (3U)
21 #define XPI_CLK_OUT_FREQ_OPTION_80MHz (4U)
22 #define XPI_CLK_OUT_FREQ_OPTION_104MHz (5U)
23 #define XPI_CLK_OUT_FREQ_OPTION_120MHz (6U)
24 #define XPI_CLK_OUT_FREQ_OPTION_133MHz (7U)
25 #define XPI_CLK_OUT_FREQ_OPTION_166MHz (8U)
26 #define XPI_CLK_OUT_FREQ_OPTION_200MHz (9U)
27 
28 typedef struct {
29  uint8_t data_pads;
30  xpi_channel_t channel;
31  xpi_io_group_t io_group;
32  uint8_t drive_strength;
33  bool enable_dqs;
34  bool enable_diff_clk;
36 
37 typedef enum {
41 
42 typedef enum {
53 
54 
55 typedef union
56 {
57  struct {
58  uint8_t freq;
59  bool enable_ddr;
60  xpi_clk_src_t clk_src;
61  clk_freq_type_t freq_type;
62  };
63  uint32_t freq_opt;
65 
66 typedef enum {
70 } xpi_clock_t;
71 
72 #endif /* HPM_ROMAPI_XPI_SOC_DEF_H */
clk_freq_type_t
Definition: hpm_romapi_xpi_soc_def.h:37
@ xpi_freq_type_mhz
Definition: hpm_romapi_xpi_soc_def.h:39
@ xpi_freq_type_typical
Definition: hpm_romapi_xpi_soc_def.h:38
xpi_clk_src_t
Definition: hpm_romapi_xpi_soc_def.h:42
@ xpi_clk_src_pll1clk0
Definition: hpm_romapi_xpi_soc_def.h:46
@ xpi_clk_src_pll4clk0
Definition: hpm_romapi_xpi_soc_def.h:51
@ xpi_clk_src_osc
Definition: hpm_romapi_xpi_soc_def.h:44
@ xpi_clk_src_pll2clk1
Definition: hpm_romapi_xpi_soc_def.h:49
@ xpi_clk_src_pll2clk0
Definition: hpm_romapi_xpi_soc_def.h:48
@ xpi_clk_src_auto
Definition: hpm_romapi_xpi_soc_def.h:43
@ xpi_clk_src_pll3clk0
Definition: hpm_romapi_xpi_soc_def.h:50
@ xpi_clk_src_pll1clk1
Definition: hpm_romapi_xpi_soc_def.h:47
@ xpi_clk_src_pll0clk0
Definition: hpm_romapi_xpi_soc_def.h:45
xpi_clock_t
Definition: hpm_romapi_xpi_soc_def.h:65
@ xpi_clock_serial_root
Definition: hpm_romapi_xpi_soc_def.h:67
@ xpi_clock_bus
Definition: hpm_romapi_xpi_soc_def.h:66
@ xpi_clock_serial
Definition: hpm_romapi_xpi_soc_def.h:68
xpi_io_group_t
XPI IO pin group options.
Definition: hpm_romapi_xpi_def.h:45
xpi_channel_t
XPI Channel definitions.
Definition: hpm_romapi_xpi_def.h:64
Definition: hpm_romapi_xpi_soc_def.h:28
Definition: hpm_romapi_xpi_soc_def.h:55