.. warning:: **OhmPi is a participative project open to all, it requires skills in electronics and to respect the safety rules. OhmPi must be assembled in a professional context and by people competent in electronics. The OhmPi team cannot be held responsible for any material or human damage which would be associated with the use or the assembly of OHMPI. The OhmPi team cannot be held responsible if the equipment does not work after assembly.** Measurement board v2023 ********************************************** **PART A** Assembly of the measurement board ============================================== Required components ---------------------------------------------------- .. figure:: ../../../img/v2023.x.x/step_n_2/a/00_mes_board_components.jpg :width: 600px :align: center :height: 450px :alt: alternate text :figclass: align-center .. csv-table:: List of components :file: ../../../img/v2023.x.x/step_n_2/a/measure_board_list_2_xx.csv :widths: 30, 70, 70, 70, 70, 35, 35 :header-rows: 1 Description ------------------ .. figure:: ../../../img/v2023.x.x/step_n_2/a/schema_measurement_board.jpg :width: 600px :align: center :height: 450px :alt: alternate text :figclass: align-center Figure shows the general schematics for the electronic measurement board developed. We have developed a complete "plug and play" measurement board. To measure electrical resistivity with Raspberry Pi. two ADS1115 were used,one for the voltage measurement one for the current measurement, as proposed by Florsch [7]. The ADS1115 is a 16-bit ADC (Analog-to-Digital Converter), with an adaptable gain. The advantage of ADS1115 is that the input signal value could lie between - to + 6.114 V. For the current measurement we have directly integrated the INA282 component, which allows to realize precise current measurement around a shunt resistor. The assembly are described in the following steps: .. table:: :align: center +--------+-------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/01_mes_board.jpg | | 1 +-------------------------------------------------------------------+ | | Installation of female header, 1 by 10 pins, for ADS1115 | | | | +--------+-------------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/02_mes_board.jpg| |2 +----------------------------------------------------------------+ | | Soldering of 4 dual-in-line socket (2 by 2 pins) for | | | optical relay, AQY211EH. | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/03_mes_board.jpg| |3 +----------------------------------------------------------------+ | | Soldering of 1 dual-in-line socket (2 by 9 pins) | | | for MCP23008. | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/04_mes_board.jpg| | 4 +----------------------------------------------------------------+ | | Soldering of 1 dual-in-line socket (2 by 4 pins) | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/05_mes_board.jpg| |5 +----------------------------------------------------------------+ | | Soldering of 2 dual-in-line socket (2 by 4 pins) | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/06_mes_board.jpg| | 6 +----------------------------------------------------------------+ | | Traco Power Supply 12V to 5V, TDH15 - 1211N | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/07_mes_board.jpg| |7 +----------------------------------------------------------------+ | | Four screw terminals for 12V inpout et 5V output | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/08_mes_board.jpg| |8 +----------------------------------------------------------------+ | | Traco power Supply 12V to 24V, TRN-1215 | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +--------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/09_mes_board.jpg| |9 +----------------------------------------------------------------+ | | Two screw terminals electrodes M and N | | | | +--------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/10_mes_board.jpg| |10 +----------------------------------------------------------------+ | | Four screw terminals, for 12V power supply and for | | | electrodes A and B | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/11_mes_board.jpg| |11 +----------------------------------------------------------------+ | | Soldering three capacitors (100nF) | | | | +---------+----------------------------------------------------------------+ .. warning:: In this version, we used a shunt resistor of 2 ohms, which limits the current measurement to 48 mA. If the current is higher than this value, you just have to decrease the value of the shunt resistor. Don't forget to change the shunt value in the config.py file (value associated to key 'R_shunt' in the OHMPI_CONFIG dict). .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/12_mes_board.jpg| | 12 +----------------------------------------------------------------+ | | 2 ohms shunt resistor pre-adjustment | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/13_mes_board.jpg| |13 +----------------------------------------------------------------+ | | Soldering 2 ohms shunt resistor | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/14_mes_board.jpg| |14 +----------------------------------------------------------------+ | | 1 MOhm resistors | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+---------------------------------------------------------------+ | | .. image::../../../img/v2023.x.x/step_n_2/a/15_mes_board.jpg| |15 +---------------------------------------------------------------+ | | Soldering tow 1 kOhm resistors | | | | +---------+---------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/16_mes_board.jpg| |16 +----------------------------------------------------------------+ | | Soldering two 1.5 kOhm resistors | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/17_mes_board.jpg| |17 +----------------------------------------------------------------+ | | Soldering two 1.5 kOhms resistors | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/18_mes_board.jpg| |18 +----------------------------------------------------------------+ | | Female header 2 by 20 pins for Raspberry Pi connection | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/19_mes_board.jpg| |19 +----------------------------------------------------------------+ | | View of the female header 2 by 20 pins installation | | | for Raspberry Pi connection | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/20_mes_board.jpg| |20 +----------------------------------------------------------------+ | | Fixing MCP23008 component (Dot mark on the top left corner) | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/21_mes_board.jpg| |21 +----------------------------------------------------------------+ | |Mounting optical relay, AQY211EH (Dot mark in the top left | | |corners) | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+---------------------------------------------------------------+ | | .. image::../../../img/v2023.x.x/step_n_2/a/22_mes_board.jpg| |22 +---------------------------------------------------------------+ | | Mounting LM158 operational amplifier | | | | +---------+---------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/23_mes_board.jpg| |23 +----------------------------------------------------------------+ | | Mounting ADS115 board | | | | +---------+----------------------------------------------------------------+ .. table:: :align: center +---------+----------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/a/24_mes_board.jpg| |24 +----------------------------------------------------------------+ | | Fixing the INA282 (Dot mark in the top right corner) | | | | +---------+----------------------------------------------------------------+ **PART B** Start-up of the measurement board ====================================================== +------------------------------------------------------------------------+ | **Required components** | +------------------------------------------------------------------------+ .. csv-table:: List of components :file: ../../../img/v2023.x.x/step_n_2/b/test_2_xx.csv :widths: 30, 70, 70, 70, 70, 35, 35 :header-rows: 1 .. table:: :align: center +--------+-------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/001.jpg | |1 +-------------------------------------------------------------+ | | Shutdown the raspberry Pi and unplug the power supply | | | | +--------+-------------------------------------------------------------+ .. table:: :align: center +--------+---------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/001.jpg | |2 +---------------------------------------------------------------------------+ | | Mounting the bottom spacers on the Raspberry Pi (male/female, 11mm, M3) | | | | +--------+---------------------------------------------------------------------------+ .. table:: :align: center +--------+---------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/002.jpg | |3 +---------------------------------------------------------------------------+ | | Mounting the upper spacers on the Raspberry Pi (female/female, 11mm, M3) | | | | +--------+---------------------------------------------------------------------------+ .. table:: :align: center +--------+-------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/003.jpg | |4 +-------------------------------------------------------------+ | | Mounting the OhmPi's measurement board on the Raspberry Pi | | | | +--------+-------------------------------------------------------------+ .. table:: :align: center +--------+------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/004.jpg | |5 +------------------------------------------------------------+ | | Mounting the OhmPi's measurement board on the Raspberry Pi | | | | +--------+------------------------------------------------------------+ .. table:: :align: center +--------+------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/b/005.jpg | |6 +------------------------------------------------------------+ | | Plug the power supply into a socket and connect it to your | | | Raspberry Pi's power port. | +--------+------------------------------------------------------------+ **PART C** Check the measurement board ====================================================== Run the terminal, and write .. code-block:: python i2cdetect -y 1 .. table:: :align: center +--------+---------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/i2cdetect.png | |1 +---------------------------------------------------------------+ | |If everything is working, three I2C addresses should appear | | |on the screen. | +--------+---------------------------------------------------------------+ Setting up an equivalent electronic circuit, for this you will need: * 4 1kOhm resistor (R2) * 1 220 Ohm resistor (R1) * 1 small padboard * Spool of solder .. table:: :align: left +--------+---------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/ref_circuit.png| |2 +---------------------------------------------------------------+ | | Schematic of equivalent electronic circuit test | +--------+---------------------------------------------------------------+ .. table:: :align: center +--------+--------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/20210905_122820.jpg | |3 +--------------------------------------------------------------------+ | | Prepare the equivalent electronic circuit test | +--------+--------------------------------------------------------------------+ .. table:: :align: center +--------+--------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/20210905_123034.jpg | |4 +--------------------------------------------------------------------+ | | Prepare the battery connections and the terminals. | +--------+--------------------------------------------------------------------+ .. table:: :align: center +--------+--------------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/20210905_132856.jpg | |5 +--------------------------------------------------------------------------------+ | | Soldering cables and terminals | +--------+--------------------------------------------------------------------------------+ .. table:: :align: center +--------+--------------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/Inked20211206_150522_LI.jpg | |6 +--------------------------------------------------------------------------------+ | |Install the red cables on the +12V terminal and black cable | | |on the ground terminal. Connect to two different 12V | | |batteries | +--------+--------------------------------------------------------------------------------+ .. table:: :align: center +--------+--------------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/Inked20211206_150522_LI2.jpg | |7 +--------------------------------------------------------------------------------+ | | Connect the equivalent electronic circuit test | | | | +--------+--------------------------------------------------------------------------------+ .. table:: :align: center +--------+-------------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/thonny_first_interface.jpg | |7 +-------------------------------------------------------------------------------+ | | Run the Thonny Interpreter | | | | +--------+-------------------------------------------------------------------------------+ .. table:: :align: center +--------+------------------------------------------------------------------------------+ | | .. image:: ../../../img/v2023.x.x/step_n_2/c/20211206_144334.jpg | |7 +------------------------------------------------------------------------------+ | | Run sample_measurement_example.py example, if everything | | | works you should get the following result (220 Ohm) | +--------+------------------------------------------------------------------------------+