Skip to content
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

Setup Boot Sequence and initialization steps for MCU #47

Open
csinko opened this issue Feb 20, 2020 · 1 comment
Open

Setup Boot Sequence and initialization steps for MCU #47

csinko opened this issue Feb 20, 2020 · 1 comment
Assignees
Labels
software Software team

Comments

@csinko
Copy link
Owner

csinko commented Feb 20, 2020

The following must be initialized for the MCU upon startup:

  • All pins should be configured as inputs on first boot

When a configuration is set, the following must be changed to outputs for each IO Pin:

  • Output pin -> Output, Timer Pin -> Input, Input Pin -> Input
  • Output pin -> Input, Timer Pin -> Output, Input Pin -> Input
  • Output pin -> Input, Timer Pin -> Input, Input Pin -> Input

^^ These are the only states that should be allowed

When switching between output pin and timer pin, MUST switch BOTH output pin and timer pins to inputs before setting the other pin as an output. This ensures we do not short anything on the board.

All Unused pins should be set to output and driven low.

The Termination and Pulldown resistor control pins along with the tristate pins are active low, so they should be set high when made into outputs

The differential pins are active high, set to low when made an output (default to single ended)

The DAC needs to be set to whatever value correlates to ~1.4 volts (needs calculated)

@codeThatThinks, we also need to measure the amount of time it takes for the DAC to be set from first turning on with a scope.

@csinko csinko added the software Software team label Feb 20, 2020
@csinko
Copy link
Owner Author

csinko commented Feb 22, 2020

All of the initial pin configuration has been done with 5f4e88a

The gpio.c file contains all of the initialization code for the pins: https://github.com/csinko/io-master/blob/5f4e88aaa68fd4bc49f22c1297d72b6442a4038c/mcu/io_master/mcu/stm32h743/src/gpio.c

Still need to add code to handle controlling the I/O Pin states for the above modes, handle the DAC, and need to test that all of the added code is working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
software Software team
Projects
None yet
Development

No branches or pull requests

2 participants