diff options
Diffstat (limited to 'examples/stm32l4/src')
| -rw-r--r-- | examples/stm32l4/src/bin/tsc_multipin.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/stm32l4/src/bin/tsc_multipin.rs b/examples/stm32l4/src/bin/tsc_multipin.rs index 2fadbe16a..8fec5ddc4 100644 --- a/examples/stm32l4/src/bin/tsc_multipin.rs +++ b/examples/stm32l4/src/bin/tsc_multipin.rs | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | // ## This example demonstrates how to: | 12 | // ## This example demonstrates how to: |
| 13 | // | 13 | // |
| 14 | // 1. Configure multiple channel pins within a single TSC group | 14 | // 1. Configure multiple channel pins within a single TSC group |
| 15 | // 2. Use the set_active_channels method to switch between different channels | 15 | // 2. Use the set_active_channels_bank method to switch between sets of different channels (acquisition banks) |
| 16 | // 3. Read and interpret touch values from multiple channels in the same group | 16 | // 3. Read and interpret touch values from multiple channels in the same group |
| 17 | // | 17 | // |
| 18 | // ## Suggested physical setup on STM32L4R5ZI-P board: | 18 | // ## Suggested physical setup on STM32L4R5ZI-P board: |
| @@ -76,7 +76,7 @@ async fn acquire_sensors( | |||
| 76 | touch_controller: &mut Tsc<'static, peripherals::TSC, mode::Async>, | 76 | touch_controller: &mut Tsc<'static, peripherals::TSC, mode::Async>, |
| 77 | tsc_acquisition_bank: &AcquisitionBank, | 77 | tsc_acquisition_bank: &AcquisitionBank, |
| 78 | ) { | 78 | ) { |
| 79 | touch_controller.set_active_channels_mask(tsc_acquisition_bank.mask()); | 79 | touch_controller.set_active_channels_bank(tsc_acquisition_bank); |
| 80 | touch_controller.start(); | 80 | touch_controller.start(); |
| 81 | touch_controller.pend_for_acquisition().await; | 81 | touch_controller.pend_for_acquisition().await; |
| 82 | touch_controller.discharge_io(true); | 82 | touch_controller.discharge_io(true); |
