Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rename stuff
Browse files Browse the repository at this point in the history
jr1221 committed Jan 25, 2025
1 parent 23c2180 commit a605b45
Showing 3 changed files with 14 additions and 14 deletions.
6 changes: 3 additions & 3 deletions Core/Inc/adi_interaction.h
Original file line number Diff line number Diff line change
@@ -55,13 +55,13 @@ void set_aux_soak_range(cell_asic *chip, OWRNG range);
void set_open_wire_soak_time(cell_asic *chip, OWA time);

/**
* @brief Set the mode of a GPIO pin on an ADBMS8630.
* @brief Set the pull of a GPIO pin on an ADBMS8630.
*
* @param chip ADBMS6830 chip
* @param gpio Number of the GPIO pin to change (1-10)
* @param input True is input, False is output.
* @param input True is no pull down, False is pull down.
*/
void set_gpio_mode(cell_asic *chip, uint8_t gpio, bool input);
void set_gpio_pull(cell_asic *chip, uint8_t gpio, bool input);

/**
* @brief Set the corner frequency of the IIR filter.
2 changes: 1 addition & 1 deletion Core/Src/adi_interaction.c
Original file line number Diff line number Diff line change
@@ -54,7 +54,7 @@ void set_open_wire_soak_time(cell_asic *chip, OWA time)
chip->tx_cfga.owa = time;
}

void set_gpio_mode(cell_asic *chip, uint8_t gpio, bool input)
void set_gpio_pull(cell_asic *chip, uint8_t gpio, bool input)
{
if (gpio > 10 || gpio < 1) {
printf("ERROR: Invalid GPIO pin %d\n", gpio);
20 changes: 10 additions & 10 deletions Core/Src/segment.c
Original file line number Diff line number Diff line change
@@ -57,18 +57,18 @@ void init_chip(cell_asic *chip)
set_open_wire_soak_time(chip, OWA0);

// Set therm GPIOs
set_gpio_mode(chip, 1, true);
set_gpio_mode(chip, 2, true);
set_gpio_mode(chip, 3, true);
set_gpio_mode(chip, 4, true);
set_gpio_mode(chip, 5, true);
set_gpio_mode(chip, 6, true);
set_gpio_mode(chip, 7, true); // this is a on board therm for beta only
set_gpio_mode(chip, 8, true); // this is a on board therm
set_gpio_pull(chip, 1, true);
set_gpio_pull(chip, 2, true);
set_gpio_pull(chip, 3, true);
set_gpio_pull(chip, 4, true);
set_gpio_pull(chip, 5, true);
set_gpio_pull(chip, 6, true);
set_gpio_pull(chip, 7, true); // this is a on board therm for beta only
set_gpio_pull(chip, 8, true); // this is a on board therm

// set outputs, 9=iso led 10=bal LED
set_gpio_mode(chip, 9, false);
set_gpio_mode(chip, 10, false);
set_gpio_pull(chip, 9, false);
set_gpio_pull(chip, 10, false);

// Registers are unfrozen
set_snapshot(chip, SNAP_OFF);

0 comments on commit a605b45

Please sign in to comment.