File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
40
40
- ` Serial::usart1/2/3 ` -> ` Serial::new ` .
41
41
- ` Serial ` implements ` Write<WORD> ` and ` Read<WORD> ` for ` WORD ` simultaneously as u8 and u16.
42
42
- Bump bxcan version to [ v0.7.0] ( https://github.com/stm32-rs/bxcan/releases/tag/v0.7.0 )
43
+ - PWM timer auto reload value is now preloaded/buffered
43
44
44
45
### Added
45
46
Original file line number Diff line number Diff line change @@ -400,7 +400,7 @@ macro_rules! hal {
400
400
}
401
401
#[ inline( always) ]
402
402
fn start_one_pulse( & mut self ) {
403
- self . cr1. write ( | w| unsafe { w . bits ( 1 << 3 ) } . cen( ) . set_bit( ) ) ;
403
+ self . cr1. modify ( |_ , w| w . opm ( ) . set_bit ( ) . cen( ) . set_bit( ) ) ;
404
404
}
405
405
#[ inline( always) ]
406
406
fn cr1_reset( & mut self ) {
@@ -460,7 +460,7 @@ macro_rules! with_pwm {
460
460
461
461
#[ inline( always) ]
462
462
fn start_pwm( & mut self ) {
463
- self . cr1. write ( | w| w. cen( ) . set_bit( ) ) ;
463
+ self . cr1. modify ( |_ , w| w. cen( ) . set_bit( ) ) ;
464
464
}
465
465
466
466
#[ inline( always) ]
@@ -512,7 +512,7 @@ macro_rules! with_pwm {
512
512
513
513
#[ inline( always) ]
514
514
fn start_pwm( & mut self ) {
515
- self . cr1. write ( | w| w. cen( ) . set_bit( ) ) ;
515
+ self . cr1. modify ( |_ , w| w. cen( ) . set_bit( ) ) ;
516
516
}
517
517
518
518
#[ inline( always) ]
@@ -565,7 +565,7 @@ macro_rules! with_pwm {
565
565
#[ inline( always) ]
566
566
fn start_pwm( & mut self ) {
567
567
$( let $aoe = self . bdtr. modify( |_, w| w. aoe( ) . set_bit( ) ) ; ) ?
568
- self . cr1. write ( | w| w. cen( ) . set_bit( ) ) ;
568
+ self . cr1. modify ( |_ , w| w. cen( ) . set_bit( ) ) ;
569
569
}
570
570
571
571
#[ inline( always) ]
You can’t perform that action at this time.
0 commit comments