![]() |
Altera SoCAL
16.0
The Altera SoC Abstraction Layer (SoCAL) API Reference Manual
|
This register sets the SCL clock low period count
Register Layout
Bits | Access | Reset | Description |
---|---|---|---|
[15:0] | RW | 0x82 | Fast Spd SCL Low Period |
[31:16] | ??? | 0x0 | UNDEFINED |
Field : Fast Spd SCL Low Period - ic_fs_scl_lcnt | |
This register must be set before any I2C bus transaction can take place to ensure proper I/O timing. This field sets the SCL clock low period count for fast speed. It is used in high-speed mode to send the Master Code and START BYTE or General CALL. This register can be written only when the I2C interface is disabled, which corresponds to the Enable Register being set to 0. Writes at other times have no effect.The minimum valid value is 8; hardware prevents values less than this being written, and if attempted results in 8 being set. Field Access Macros: | |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_LSB 0 |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_MSB 15 |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_WIDTH 16 |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_SET_MSK 0x0000ffff |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_CLR_MSK 0xffff0000 |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_RESET 0x82 |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_GET(value) (((value) & 0x0000ffff) >> 0) |
#define | ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_SET(value) (((value) << 0) & 0x0000ffff) |
Data Structures | |
struct | ALT_I2C_FS_SCL_LCNT_s |
Macros | |
#define | ALT_I2C_FS_SCL_LCNT_OFST 0x20 |
#define | ALT_I2C_FS_SCL_LCNT_ADDR(base) ALT_CAST(void *, (ALT_CAST(char *, (base)) + ALT_I2C_FS_SCL_LCNT_OFST)) |
Typedefs | |
typedef struct ALT_I2C_FS_SCL_LCNT_s | ALT_I2C_FS_SCL_LCNT_t |
struct ALT_I2C_FS_SCL_LCNT_s |
WARNING: The C register and register group struct declarations are provided for convenience and illustrative purposes. They should, however, be used with caution as the C language standard provides no guarantees about the alignment or atomicity of device memory accesses. The recommended practice for writing hardware drivers is to use the SoCAL access macros and alt_read_word() and alt_write_word() functions.
The struct declaration for register ALT_I2C_FS_SCL_LCNT.
Data Fields | ||
---|---|---|
uint32_t | ic_fs_scl_lcnt: 16 | Fast Spd SCL Low Period |
uint32_t | __pad0__: 16 | UNDEFINED |
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_LSB 0 |
The Least Significant Bit (LSB) position of the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_MSB 15 |
The Most Significant Bit (MSB) position of the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_WIDTH 16 |
The width in bits of the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_SET_MSK 0x0000ffff |
The mask used to set the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field value.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_CLR_MSK 0xffff0000 |
The mask used to clear the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field value.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_RESET 0x82 |
The reset value of the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_GET | ( | value | ) | (((value) & 0x0000ffff) >> 0) |
Extracts the ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT field value from a register.
#define ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT_SET | ( | value | ) | (((value) << 0) & 0x0000ffff) |
Produces a ALT_I2C_FS_SCL_LCNT_IC_FS_SCL_LCNT register field value suitable for setting the register.
#define ALT_I2C_FS_SCL_LCNT_OFST 0x20 |
The byte offset of the ALT_I2C_FS_SCL_LCNT register from the beginning of the component.
#define ALT_I2C_FS_SCL_LCNT_ADDR | ( | base | ) | ALT_CAST(void *, (ALT_CAST(char *, (base)) + ALT_I2C_FS_SCL_LCNT_OFST)) |
The address of the ALT_I2C_FS_SCL_LCNT register.
typedef struct ALT_I2C_FS_SCL_LCNT_s ALT_I2C_FS_SCL_LCNT_t |
The typedef declaration for register ALT_I2C_FS_SCL_LCNT.