Skip to content

Commit

Permalink
Merge pull request #2291 from hathach/minor-update-max3421
Browse files Browse the repository at this point in the history
minor update for max3421
  • Loading branch information
hathach authored Oct 30, 2023
2 parents 10558ac + 9cba9a7 commit a91b720
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .idea/cmake.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions hw/bsp/espressif/boards/espressif_s3_devkitm/board.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@

// SPI for USB host shield
#define MAX3421_SPI_HOST SPI2_HOST
#define MAX3421_SCK_PIN 36
#define MAX3421_MOSI_PIN 35
#define MAX3421_MISO_PIN 37
#define MAX3421_SCK_PIN 39
#define MAX3421_MOSI_PIN 42
#define MAX3421_MISO_PIN 21
#define MAX3421_CS_PIN 15
#define MAX3421_INTR_PIN 14

Expand Down
5 changes: 3 additions & 2 deletions src/portable/analog/max3421/hcd_max3421.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,8 +433,9 @@ bool hcd_init(uint8_t rhport) {
reg_write(rhport, PINCTL_ADDR, PINCTL_FDUPSPI, false);

// V1 is 0x01, V2 is 0x12, V3 is 0x13
// uint8_t const revision = reg_read(rhport, REVISION_ADDR, false);
// TU_LOG2_HEX(revision);
uint8_t const revision = reg_read(rhport, REVISION_ADDR, false);
TU_ASSERT(revision == 0x01 || revision == 0x12 || revision == 0x13, false);
TU_LOG2_HEX(revision);

// reset
reg_write(rhport, USBCTL_ADDR, USBCTL_CHIPRES, false);
Expand Down

0 comments on commit a91b720

Please sign in to comment.