![Murata DNT90M Series Integration Manual Download Page 19](http://html1.mh-extra.com/html/murata/dnt90m-series/dnt90m-series_integration-manual_1857330019.webp)
b. Set the SPI master command string and string length by setting the
SpiMasterCmdStr
and
SpiMas-
terCmdLen
parameters respectively in Bank 3.
3. Configure the edge trigger direction, bit-sampling edge and bit-order options by setting the
SpiOptions
parameter in Bank 3.
5.3
Configuring Digital I/O
1. GPIO2 through GPIO 5 have configurable alternate functions as discussed in Section 7.4.7. Select either digital
(state) functionality or alternate functionality for each of these pins by setting the
GpioAlt
parameter in Bank 6.
Note that selecting SPI slave mode overrides the
GpioAlt
parameter setting for GPIO3 though GPIO5.
2. Configure the direction of each GPIO pin as needed by setting the
GpioDir
parameter in Bank 6
(the default is all inputs).
3. Configure the direction of each GPIO pin for sleep mode as needed by setting the
GpioSleepDir
parameter in Bank 6 (the default is all inputs).
4. Set the initial state (power on) of all GPIO pins configured as outputs by setting the
GpioInit
parameter in Bank 6
(the default is all logic low).
5. Set the state of all GPIO pins configured as outputs in sleep mode by setting the
GpioSleepState
parameter in
Bank 6 (the default is all logic low).
6. GPIO0 through GPIO3 can trigger I/O event reporting when functioning as digital inputs. Enable event report trig-
gering and optional sleep hold-off for these pins by setting the
GpioEdgeTrigger
parameter in Bank 6.
5.4
Configuring Analog I/O
1. Select the ADC full-scale reference by setting the
AdcReference
parameter in Bank 6. This setting applies to all
ADC channels. The default is the ADC_EXT_REF input. If ADC operation is not needed, setting this parameter to
0x03 disables ADC operation, reducing current consumption.
2. Select the ADC mode, either single-ended or differential by setting the
AdcDiffMode
parameter in Bank 6. The de-
fault is single-ended ADC operation.
3. If differential ADC mode is selected, set the desired ADC preamplifier gain for each ADC channel with the
AdcGainCh0
and
AdcGainCh1
parameters in Bank 6. The default gain is 1. Note that the full scale output voltage
from the preamplifier is 2.4 V.
4. Reconfigure the ADC measurement interval as needed by setting the
AdcSampleIntvl
parameter. The default is
100 ms, and applies to all ADC channels.
5. Set the
AdcAveSelect
parameter to the number of ADC readings to be averaged to produce a measurement. The
larger the
AdcAveSelect
parameter is set, the greater the noise filtering effect, but the longer it takes to produce a
measurement. Setting this parameter to 8 or more when the ADC is operating in single-ended mode is especially
helpful in stabilizing ADC measurements.
6. Measurements on each ADC input can be compared to high/low threshold values, triggering an I/O event report if
the measurements go above/below the respective thresholds. The thresholds for each ADC channel are set by
loading the
AdcXThresholdLo
and
AdcXThresholdHi
, where
X
refers to the ADC channel designator, 0 through 2.
©2012 by Murata Electronics N.A., Inc.
DNT90M Integration Guide (2012/09/17)
Page 19 of 74
www.murata.com