Skip to content

feat:at24xx adds ee_type option #1809

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions peripherals/at24cxx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,57 @@ if PKG_USING_AT24CXX
bool "latest"
endchoice

choice
prompt "AT24XX Type"
default EE_TYPE_AT24C128
help
Select the at24xx type

config EE_TYPE_AT24C01
bool "AT24C01"

config EE_TYPE_AT24C02
bool "AT24C02"

config EE_TYPE_AT24C04
bool "AT24C04"

config EE_TYPE_AT24C08
bool "AT24C08"

config EE_TYPE_AT24C16
bool "AT24C16"

config EE_TYPE_AT24C32
bool "AT24C32"

config EE_TYPE_AT24C64
bool "AT24C64"

config EE_TYPE_AT24C128
bool "AT24C128"

config EE_TYPE_AT24C256
bool "AT24C256"

config EE_TYPE_AT24C512
bool "AT24C512"

endchoice

config EE_TYPE

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

根据最新的代码,这里应该是PKG_AT24CXX_EE_TYPE

int
default 0 if EE_TYPE_AT24C01
default 1 if EE_TYPE_AT24C02
default 2 if EE_TYPE_AT24C04
default 3 if EE_TYPE_AT24C08
default 4 if EE_TYPE_AT24C16
default 5 if EE_TYPE_AT24C32
default 6 if EE_TYPE_AT24C64
default 7 if EE_TYPE_AT24C128
default 8 if EE_TYPE_AT24C256
default 9 if EE_TYPE_AT24C512

config PKG_AT24CXX_VER
string
default "latest" if PKG_USING_AT24CXX_LATEST_VERSION
Expand Down
Loading