Going back to a single chip, do you still have instability?
I'm not sure what to suggest really. Perhaps you could try putting a capacitor across the MCP23017's power pins just in case there are some fluctuations on the power rail?
The bitrate should default to 50000 so that shouldn't be an issue, but I guess you could try going faster with bitrate:100000 in I2C.setup (or more) and see if that helps somehow.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Going back to a single chip, do you still have instability?
I'm not sure what to suggest really. Perhaps you could try putting a capacitor across the MCP23017's power pins just in case there are some fluctuations on the power rail?
The bitrate should default to 50000 so that shouldn't be an issue, but I guess you could try going faster with
bitrate:100000
in I2C.setup (or more) and see if that helps somehow.