BS2 and LCD with IO expander
Nikhil Vora
Posts: 7
Hello,
I have seen an example of the MCP23016 IO expander intefaced with the the BS2p to control an LCD. It uses the I2COUT commands to control everything. The article is in the Nuts and Volts Magazine.
I was wondering if it is possible to use a BS2 with the MCP23016 to control an LCD, i.e, without using the I2COUT commands.
I would appreciate a reply.
Nikhil Vora
I have seen an example of the MCP23016 IO expander intefaced with the the BS2p to control an LCD. It uses the I2COUT commands to control everything. The article is in the Nuts and Volts Magazine.
I was wondering if it is possible to use a BS2 with the MCP23016 to control an LCD, i.e, without using the I2COUT commands.
I would appreciate a reply.
Nikhil Vora
Comments
It is absolutely possible. I2CIN and I2COUT are merely specialized commands which permit the programmer easier access to the statndard I2C interface.
Those two commands had predecessor commands, SHIFTIN and SHIFTOUT, which also could be used with an I2C interface, just not quite as easily. It's not really that it's any more difficult to do, it's that there are more responsibilities which fall to the programmer when using the more basic commands SHIFIN and SHIFTOUT, rather than I2CIN and I2COUT.
I will search around to see if I have any examples handy, but even if I don't I'm SURE there are others that have SHIFTIN / SHIFTOUT examples which access I2C devices.
Regards,
Bruce Bates
Here is a program written by Jon Williams to access the Philips PCF8574A, an I2C device. This Philips chip·is a device similar in function·to the one you're working with, but they don't operate the same, insofar as·the internal registers are concerned! The prgram is wriiten for the Stamp BS-2.
Regards,
Bruce Bates
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
-Nikhil Vora
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
There are I2C appnotes for talking to a Matrix Orbital display at www.matrixorbital.ca/appnotes/basic_stamp/ .
Best Regards,
Tom Lam