i2c does not work on ecio28
Moderator: Benj
-
- Posts: 26
- Joined: Tue May 23, 2017 1:55 am
- Been thanked: 1 time
- Contact:
i2c does not work on ecio28
i have had problems with the i2c , in the end i connected a i2c lcd display and wrote a very simple progran and still did not work . then had the brainwave to swicth to software using the same ports and the display workes . i now can just swicth between hardware and software i2c recompile and it always workes with software never with hardware so my conclusion is there is something wrong with the i2c hardware support ?
- 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: i2c does not work on ecio28
Hello,
Could you post your program that shows the problem. I have just tested an accelerometer program using hardware I2C on the ECIO28P and for me it's working fine.
Could you post your program that shows the problem. I have just tested an accelerometer program using hardware I2C on the ECIO28P and for me it's working fine.
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
-
- Posts: 26
- Joined: Tue May 23, 2017 1:55 am
- Been thanked: 1 time
- Contact:
Re: i2c does not work on ecio28
note i am using the free version of the pic as only have avr and arm licence
- Attachments
-
- test_display.fcfx
- (7.9 KiB) Downloaded 244 times
-
- Posts: 26
- Joined: Tue May 23, 2017 1:55 am
- Been thanked: 1 time
- Contact:
Re: i2c does not work on ecio28
the i2c lcd gets more interesting i have tried to use it on a atmil attiny85 i made a very simple program to just test the outputs and that worked but just the act of adding the i2c lcd without actuly calling it apears to kill all outputs when set to softweare and if set to hardware it gives me lots of errors , note i do have the licence for the atmil chips
here are the 2 programs
here are the 2 programs
- Attachments
-
- attiny_dead.fcfx
- none working
- (12.34 KiB) Downloaded 215 times
-
- attiny_working.fcfx
- working
- (11.63 KiB) Downloaded 217 times
- 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: i2c does not work on ecio28
Hello,
Thanks for letting us know.
I tried a I2C accelerometer on the ECIO28P and for me it was working in hardware and software mode. Maybe the problem is limited to the display for some reason?
Here is an updated CAL C file which should solve the compilation errors you are getting using the hardware mode. Simply copy to your "Flowcode 7/CAL/AVR" folder.
I'm not sure why you would be getting lock ups in software mode unless the clock stretching is kicking in. Do you have pull up resistors on the SDA and SCL pins?
Thanks for letting us know.
I tried a I2C accelerometer on the ECIO28P and for me it was working in hardware and software mode. Maybe the problem is limited to the display for some reason?
Here is an updated CAL C file which should solve the compilation errors you are getting using the hardware mode. Simply copy to your "Flowcode 7/CAL/AVR" folder.
I'm not sure why you would be getting lock ups in software mode unless the clock stretching is kicking in. Do you have pull up resistors on the SDA and SCL pins?
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
-
- Posts: 26
- Joined: Tue May 23, 2017 1:55 am
- Been thanked: 1 time
- Contact:
Re: i2c does not work on ecio28
than you hardware worked on the attiny85 will check it out on the ecio28 later , no i dont have put up resistors but it workes ok now