learning to use a mcp23008 using I2C
-
- Flowcode V4 User
- Posts: 38
- Joined: Thu Feb 24, 2011 4:38 pm
- Has thanked: 2 times
- Been thanked: 1 time
- Contact:
learning to use a mcp23008 using I2C
hi guys, this may be a stupid question but gonna ask anyway, am just starting to use I2c com's with a mcp23008 expander chip. have figured out most of the basic's but am wondering if the outputs actually go low on the mcp23008 output or do they stay floating at around 2v. when i right an output to the gpio port the pin i right to goes to 5v as expected, but the rest stay at 2v, i was expecting them to goto 0v, am i missing something here?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: learning to use a mcp23008 using I2C
Hello,
The pins probably should go to 0V though I have not personally tested this on the I2C expander. Are you sure you have setup the data direction register correctly for an output?
The pins probably should go to 0V though I have not personally tested this on the I2C expander. Are you sure you have setup the data direction register correctly for an output?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Flowcode V4 User
- Posts: 38
- Joined: Thu Feb 24, 2011 4:38 pm
- Has thanked: 2 times
- Been thanked: 1 time
- Contact:
Re: learning to use a mcp23008 using I2C
hi ben, you are correct, outputs do go to zero. have written code addressing each register individually which works. i did have a restart command inbetween before, which i assumed would write all the data at the final stop command.