Skip to content

Bootcamp: Everest Shen#300

Open
yxshen22 wants to merge 3 commits into
UWARG:masterfrom
yxshen22:master
Open

Bootcamp: Everest Shen#300
yxshen22 wants to merge 3 commits into
UWARG:masterfrom
yxshen22:master

Conversation

@yxshen22

Copy link
Copy Markdown
  • configured SPI1 for MCP3004 ADC (PA6, PA7, PB3, PB8)
  • configured TIM1 CH1 for 50Hz PWM on PA8
  • mapped potentiometer input (0-1023) to servo pulse width (1ms-2ms)

@yxshen22 yxshen22 changed the title efs bootcamp bootcamp: Everest Shen May 17, 2026
@yxshen22 yxshen22 changed the title bootcamp: Everest Shen Bootcamp: Everest Shen May 17, 2026
Comment thread nucleof072rb/Core/Src/main.c Outdated
// map ADC (0-1023) to servo pulse width (1ms-2ms)
// CCR 500 = 1ms | Pulse = min speed/position
// CCR 1000 = 2ms | Pulse = max speed/position
uint32_t ccr = 500 + (adc_val * 500) / 1023;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can you walk me through your period and prescaler calculation using the formula in the bootcamp instructions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants