Need advice regarding MuxShield II Arduino I/O and Analog Expander

Hi guys, MuxShield consist of 48 analog input that isolated with I/O1, I/O2 and I/O3 with 16 input each.

with I/O3 i can received my analog input fine without any issue.
The issue is if i tried to use two lane with is I/O2 and I/O3.

Here is the example code that is running fine.

/*This example shows how to use the Mux Shield for a combination of 
analog inputs, digital inputs, and digital outputs.
*/
#include <MuxShield.h>

//Initialize the Mux Shield
MuxShield muxShield;

void setup()
{

  muxShield.setMode(3,ANALOG_IN);          //set I/O 3 as analog input
  
  Serial.begin(19200);
}
//Arrays to store input values

void loop()
{
  
  //Read analog inputs on IO3
  const int analog1 = muxShield.analogReadMS(3,14);  //IO3, pin 14
  const int analog2 = muxShield.analogReadMS(3,15);  //IO1, pin 15
  
  //Print the results
  Serial.print("analog1: ");Serial.print(analog1);Serial.print('\t');
  Serial.print("analog2: ");Serial.print(analog2);Serial.println();
  
}

Output was great without any issue.

Here is the bad example:

/*This example shows how to use the Mux Shield for a combination of 
analog inputs, digital inputs, and digital outputs.
*/
#include <MuxShield.h>

//Initialize the Mux Shield
MuxShield muxShield;

void setup()
{

  muxShield.setMode(2,ANALOG_IN);
  muxShield.setMode(3,ANALOG_IN);          //set I/O 3 as analog input
  
  Serial.begin(19200);
}
//Arrays to store input values

void loop()
{
  
  //Read analog inputs on IO3
  const int analog1 = muxShield.analogReadMS(2,14);  //IO3, pin 14
  const int analog2 = muxShield.analogReadMS(3,15);  //IO1, pin 15
  
  //Print the results
  Serial.print("analog1: ");Serial.print(analog1);Serial.print('\t');
  Serial.print("analog2: ");Serial.print(analog2);Serial.println();
  
}

Output with both input connected to GND

image

i tried using I/O1 still same thing.. is this related to the code or the hardware configuration? i havent touch any jumper on the bottom.. it come still standart as it is.

Thank you!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.