Searching \ for 'I2C on 16C74' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: techref.massmind.org/techref/i2cs.htm?key=i2c
Search entire site for: 'I2C on 16C74'.

Truncated match.
PICList Thread
'I2C on 16C74'
1997\03\11@160821 by Nishant Deshpande

flavicon
picon face
hi all,

i'm trying to use the I2C bus on the C74 - i've read all the info
on the bus & from microchip etc -

to help me get started, does anyone have a simple piece of code
that'll transmit some data?

what's the general convention? i.e. is it usually used via interrupts?

i'm using it to tune a video tuner and a teletext decoder. (as
some of you might remember helping me out on that..)

thanks

nishant

1997\03\12@051944 by Wolfram Liebchen

flavicon
face
At 21:05 11.03.97 +0000, you wrote:
>
>i'm trying to use the I2C bus on the C74 - i've read all the info
>on the bus & from microchip etc -
>>
>i'm using it to tune a video tuner and a teletext decoder. (as
>some of you might remember helping me out on that..)
>
Nishant,

it sounds, as if you wanted to use I2C master mode, to control
other I2C devices; that's impossible, because only I2C slave
mode is implemented in 16C74 hardware.

To use I2C master mode, you have to do every bit change in software,
so you can use every other PIC.

regards,

Wolfram


+-----------------------------------------------------+
| Wolfram Liebchen                                    |
| Forschungsinstitut fŸr Optik, TŸbingen, Deutschland |
| spam_OUTliebchenTakeThisOuTspamffo.fgan.de                         |
+-----------------------------------------------------+

1997\03\12@064928 by Mike Harrison

picon face
At 11:18 12/03/97 +0100, you wrote:

>Nishant,
>
>it sounds, as if you wanted to use I2C master mode, to control
>other I2C devices; that's impossible, because only I2C slave
>mode is implemented in 16C74 hardware.
>
>To use I2C master mode, you have to do every bit change in software,
>so you can use every other PIC.
>
>regards,
>
>Wolfram
>
Are you suggesting that you cannot use the i2c control registers to perform
output of data and interrupt on receive etc while acting as a master?
I can see that you would have to generate Sr, St and NACK yourself for bus
master control purposes but cannot see a problem with the general data
transmission to and fro.
Cheers
***************************************************************************
M. Harrison                                     TEL (00 44) 1235 445288
Space Science Division                          Fax (00 44) 1235 445848
Rutherford Appleton Lab                         email work: .....m.c.harrisonKILLspamspam@spam@rl.ac.u
k
Building R25 Room 2.124                         email home:mikespamKILLspamleyenda.demon.co
.uk
Chilton
Oxon OX11 0QX UK
***************************************************************************

1997\03\12@073255 by Wolfram Liebchen

flavicon
face
>
>>To use I2C master mode, you have to do every bit change in software,
>>so you can use every other PIC.
>>

>Are you suggesting that you cannot use the i2c control registers to perform
>output of data and interrupt on receive etc while acting as a master?
>I can see that you would have to generate Sr, St and NACK yourself for bus
>master control purposes but cannot see a problem with the general data
>transmission to and fro.
>Cheers

At least in the I2C mode, the SSP would not generate a clock signal, so
the data won't come out.
Somebody else in the PICLIST proposed to switch to SPI mode, to act
as an I2C master. Might work, but then, the slaves couldn't do clock
stretching and so on. Would only be a crude imitation of I2C.

regards,

Wolfram


+-----------------------------------------------------+
| Wolfram Liebchen                                    |
| Forschungsinstitut fŸr Optik, TŸbingen, Deutschland |
| .....liebchenKILLspamspam.....ffo.fgan.de                         |
+-----------------------------------------------------+

1997\03\13@120705 by Nishant Deshpande

flavicon
picon face
Wolfram,

yeah i remmember that thread about switching to SPI mode -

but i'm confused - are we still using the designated I2C SDA/SCL
pins ? so how can you switch to SPI mode?
or are we talking about using the SPI module to do this (i.e.
different pins) ?

nishant

1997\03\14@040149 by Wolfram Liebchen

flavicon
face
At 17:05 13.03.97 +0000, you wrote:
>Wolfram,
>
>yeah i remmember that thread about switching to SPI mode -
>
>but i'm confused - are we still using the designated I2C SDA/SCL
>pins ? so how can you switch to SPI mode?
>or are we talking about using the SPI module to do this (i.e.
>different pins) ?
>
>nishant
>

Nishant,

SDA (I2C) equals SDI (SPI). So you should connect SDI and SDO of the
SPI module, to be able to transmit and receive on the same line. But
then you have to take a lot of care to correctly configure and
reconfigure the data-direction bit for SDO to avoid collissions
between SDO and a slave device, transmitting data.

I have not tried this setup, I only think, that it might be possible
to be done.
But if you think of all the software-efforts and also the restrictions
and compromises of this SPI-driven solution, it might be easier and better,
to have an all-software solution for I2C master devices.

The best solution could be, to use the 17C75x, as it contains I2C master
and also 10bit A/D. And has a lot more features.

regards,

Wolfram


+-----------------------------------------------------+
| Wolfram Liebchen                                    |
| Forschungsinstitut fŸr Optik, TŸbingen, Deutschland |
| EraseMEliebchenspam_OUTspamTakeThisOuTffo.fgan.de                         |
+-----------------------------------------------------+

More... (looser matching)
- Last day of these posts
- In 1997 , 1998 only
- Today
- New search...