Hello,
I am working on a project with 2 PICs (16f877a) with I2C communication between both of them but it seems that Flowcode has only a master i2C component.
Has someone find a good code C to insert in a flowcode project ? Or any other solution ?
Thanks for your help,
Jeff
I2C Slave
- 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 Slave
Hello Jeff
Can you use RS232 instead? The I2C slave component for Flowcode is still a while off yet.
Can you use RS232 instead? The I2C slave component for Flowcode is still a while off yet.
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: 258
- Joined: Wed Nov 29, 2006 6:32 pm
- Location: Finland
- Has thanked: 7 times
- Been thanked: 36 times
Re: I2C Slave
Hello. I am too very interested that i2c slave mode,because i have already i2c omponent on my design,so it would be nice to have the pics communicate on same method...
Other thing is that i already have 2 custom component,so is it possible to modify the existing i2c component to work on slave mode,or use just
c code commands?
Mika
Other thing is that i already have 2 custom component,so is it possible to modify the existing i2c component to work on slave mode,or use just
c code commands?
Mika
Re: I2C Slave
I am also interested for one of my projects in the I2C slave functionality. When will it be available in flowcode? thanks, wim
-
- Posts: 5
- Joined: Tue Mar 10, 2009 12:52 pm
Re: I2C Slave
Hello,
Is there any news on I2C Slave module? Could you put up a beta component for this or tell me how I could connect two PICs using the I2C ports?
Many thanks,
George
Is there any news on I2C Slave module? Could you put up a beta component for this or tell me how I could connect two PICs using the I2C ports?
Many thanks,
George
- 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 Slave
Hello
Yes it would be possible to use the custom components to build your own slave I2C component.
Slave components are a little tricky as they have to be ready to react to incoming data which means careful planning of your program. This is why I prefare RS232 data as you can receive and respond to data pretty much whenever your ready as long as the baud rate is not too high. I2C or SPI slave devices are essentially dumb devices that can only ever sit on the bus and await instruction. Before you go down the path of making a I2C slave device you must be sure that this operation is what you are looking for.
Essentially all you need to do is to modify the I2C hardware commands so the peripheral is configured as a slave instead of a master. Alternativly you could create a bit banged slave routine similar to the software I2C master routines available in the current I2C component.
You can find more help on editing the Flowcode custom components from here.
http://www.matrixmultimedia.com/Flowcode_Components.php
Yes it would be possible to use the custom components to build your own slave I2C component.
Slave components are a little tricky as they have to be ready to react to incoming data which means careful planning of your program. This is why I prefare RS232 data as you can receive and respond to data pretty much whenever your ready as long as the baud rate is not too high. I2C or SPI slave devices are essentially dumb devices that can only ever sit on the bus and await instruction. Before you go down the path of making a I2C slave device you must be sure that this operation is what you are looking for.
Essentially all you need to do is to modify the I2C hardware commands so the peripheral is configured as a slave instead of a master. Alternativly you could create a bit banged slave routine similar to the software I2C master routines available in the current I2C component.
You can find more help on editing the Flowcode custom components from here.
http://www.matrixmultimedia.com/Flowcode_Components.php
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