> ## Documentation Index
> Fetch the complete documentation index at: https://nominal-noahschwab-instro-571-create-config-driven-demo-for.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# build an InstroDMM from a JSON config file

```python dmm_config.py theme={null}
"""Example: build an InstroDMM from a JSON config file.

Run:
    uv run python -m instro.dmm.scpi_sim_server   # terminal 1: the simulator (port 5026)
    uv run python examples/dmm/dmm_config.py      # terminal 2
"""

from pathlib import Path

from instro.dmm import InstroDMM

# Swap this for dmm_config_keysight_34461a.json (after editing its visa_resource)
# to run against real hardware instead of the simulator.
CONFIG_PATH = Path(__file__).parent / "dmm_config_simulated.json"


def main() -> None:
    with InstroDMM(config=CONFIG_PATH) as dmm:
        measurement = dmm.read()
        print(f"{dmm.name}: {measurement.latest:.3f}V")


if __name__ == "__main__":
    main()
```
