diff options
author | Giovanni Di Sirio <gdisirio@gmail.com> | 2015-12-05 11:17:28 +0000 |
---|---|---|
committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2015-12-05 11:17:28 +0000 |
commit | 9210ae4da0ebf07120028faf2473b1a11d84863c (patch) | |
tree | 5a5632aab890a9c802148ee64d8521b3c7061283 /os | |
parent | 00edb39399bbd765f08bdc917aaa6624af1f7778 (diff) | |
download | ChibiOS-9210ae4da0ebf07120028faf2473b1a11d84863c.tar.gz ChibiOS-9210ae4da0ebf07120028faf2473b1a11d84863c.tar.bz2 ChibiOS-9210ae4da0ebf07120028faf2473b1a11d84863c.zip |
Fixed bug #677.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8568 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os')
-rw-r--r-- | os/hal/ports/STM32/LLD/DACv1/dac_lld.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/os/hal/ports/STM32/LLD/DACv1/dac_lld.c b/os/hal/ports/STM32/LLD/DACv1/dac_lld.c index faebcadc0..5ab25bae1 100644 --- a/os/hal/ports/STM32/LLD/DACv1/dac_lld.c +++ b/os/hal/ports/STM32/LLD/DACv1/dac_lld.c @@ -419,6 +419,7 @@ void dac_lld_start_conversion(DACDriver *dacp) { dmaStreamSetPeripheral(dacp->params->dma, &dacp->params->dac->DHR12RD);
dmamode = dacp->params->dmamode |
STM32_DMA_CR_PSIZE_WORD | STM32_DMA_CR_MSIZE_WORD;
+ n /= 2;
break;
case DAC_DHRM_12BIT_LEFT_DUAL:
osalDbgAssert(dacp->grpp->num_channels == 2, "invalid number of channels");
@@ -426,6 +427,7 @@ void dac_lld_start_conversion(DACDriver *dacp) { dmaStreamSetPeripheral(dacp->params->dma, &dacp->params->dac->DHR12LD);
dmamode = dacp->params->dmamode |
STM32_DMA_CR_PSIZE_WORD | STM32_DMA_CR_MSIZE_WORD;
+ n /= 2;
break;
case DAC_DHRM_8BIT_RIGHT_DUAL:
osalDbgAssert(dacp->grpp->num_channels == 1, "invalid number of channels");
@@ -433,6 +435,7 @@ void dac_lld_start_conversion(DACDriver *dacp) { dmaStreamSetPeripheral(dacp->params->dma, &dacp->params->dac->DHR8RD);
dmamode = dacp->params->dmamode |
STM32_DMA_CR_PSIZE_HWORD | STM32_DMA_CR_MSIZE_HWORD;
+ n /= 2;
break;
#endif
default:
|