The Digilent DMM Shield is a 5 1/2 Digit digital multimeter, designed for use with microcontroller boards that are equipped with the Arduino shield header. The device has 7 measurements functions (AC/DC Voltage, AC/DC Current, Resistance, Diode, Continuity) and is factory calibrated. It is accessed through a custom SPI interface, using digital IO pins exposed in the DMM Shield connector. The interface to DMMShield functionality is implemented as a Command interpreter running over standard Arduino Serial Terminal, or as direct commands to be called from the main sketch.
The user interface of the DMMShield functionality is implemented as a command interpreter, recognizing a set of commands covering all DMMShield functionality. It is implemented in DMMCMD module. It runs using the standard Serial Arduino terminal and that has these functions:
- It listens over UART for individual DMM Shield commands. The user will have to provide these commands in the Serial Arduino terminal.
- The commands are recognized by DMMCMD module and implemented by calls to needed modules.
- The command interpreter will send over UART the commands output messages, which can be seen in the Serial Arduino terminal.
The following list shows the commands implemented in the DMMCMD module:
- DMMSetScale
- DMMMeasureRep
- DMMMeasureStop
- DMMMeasureRaw
- DMMMeasureAwg
- DMMCalib
- DMMMeasureForCalib
- DMMFinalizeCalib
- DMMSaveEPROM
- DMMImportCalib
- DMMRestoreFactCalibs
- DMMReadSerialNo
Library Overall Structure
Library Usage
The library can be used as a normal Arduino library: The folder must be placed in the proper Arduino libraries folder for example <user folder>\Documents\Arduino\libraries, depending on sketch location defined in Preferences window (File / Preferences). In the sketch the DMMShield can be used as any class object, for example by declaring an object of class DMMShield and calling its member functions DMMShield dmmShieldObj; dmmShieldObj.CheckForCommand();
Further possible developments
The current DMMShield implementation provides all the DMM functions through a text Command interpreter. User may implement other approach in order to access the DMMShield modules: DMM module, CALIB module and EPROM module. For example a function accessing the user locations of EPROM can be implemented, using the existing function in EPROM module.
Library Modules
The DMMShield class implements the DMMShield Arduino library object main class. Normally its functions are called from the Arduino sketch. The library is initialized using DMMShield::begin function. As an interface between the user and DMMShield functionality, it provides three approaches:
- All the DMMShield functionality is implemented in a command interpreter, in the DMMCMD Module. The command interpreter is accessed by calling DMMShield::CheckForCommand function. See Command Interpreter chapter for more details.
- Each command of the command interpreter can be accessed using DMMShield::ProcessIndividualCmd function.
- Basic DMMShield functionality can be accessed using specific functions
Find the library modules and setup details on the Digilent Reference Page. DMM Shield is available in Elfa Distrelec.