View previous topic :: View next topic |
Author |
Message |
dcwestcott
Joined: 14 Oct 2013 Posts: 3
|
I2C Non-Standard General call address |
Posted: Tue Oct 15, 2013 10:50 am |
|
|
I am curious about the I2C General Call Addresses. The spec defines a couple of addresses,06h,04h,&00h. And it states that the other 125 addresses have not been defined and the devices should ignore them.
Is there a good reason not to use those other addresses? Does anybody ever use these addresses? It would be great to define the exact function I require in a unique address. |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Oct 15, 2013 12:24 pm |
|
|
Philips uses most of the addresses for their own chips. See this table of
allocated i2c slave addresses, by chip:
http://www.diolan.com/downloads/i2c-address-allocation-table.pdf
But if you're making a PIC i2c slave, you can use whatever address you
want, as long as it's within the accepted range for a slave device. Just
make sure that the address doesn't conflict with any other i2c devices on
your board, such as eeprom chips, RTC chips, etc.
For some forum comments on allowable slave addresses for PIC slaves,
read this thread here:
http://www.ccsinfo.com/forum/viewtopic.php?t=49907
In other words, for your i2c slave PIC, don't use any of the special Philips
reserved addresses, such as General Call address, Hs-mode master code,
"reserved for future purposes" addreses, etc. And avoid addresses
for chips that embedded designers like to use a lot (ds1307, 24LC256, etc.)
Also read this thread about the correct format of the i2c slave address for CCS:
http://www.ccsinfo.com/forum/viewtopic.php?t=48415
And see:
i2c bus scanner program -
http://www.ccsinfo.com/forum/viewtopic.php?t=49713 |
|
![](templates/subSilver/images/spacer.gif) |
dcwestcott
Joined: 14 Oct 2013 Posts: 3
|
I2C Non-Standard Genereral call address |
Posted: Tue Oct 15, 2013 3:02 pm |
|
|
I was actually talking about the second byte of the General Call. I have found that only 00h, 02h, 04h, and 06h have a definition. What about the rest? are the free to use? the I2C spec implies that a slave should ignore them. Could we use them anyway? |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Oct 15, 2013 3:37 pm |
|
|
OK, sorry I misinterpreted your post.
The i2c user's guide from Philips says this about the 2nd byte:
Quote: | The remaining codes have not been fixed and devices must ignore them |
http://www.nxp.com/documents/user_manual/UM10204.pdf
What's your purpose ? Does your question refer to a PIC microcontroller chip ? If so, is your question about using the PIC as an i2c Master or a Slave ? |
|
![](templates/subSilver/images/spacer.gif) |
dcwestcott
Joined: 14 Oct 2013 Posts: 3
|
I2C Non-Standard Genereral call address |
Posted: Tue Oct 15, 2013 4:42 pm |
|
|
We were looking for ways to set the Slave addresses, ID's and Version numbers that was not apart part of the regular Slave addressing mode.
Does anyone know what the other "second bye" codes might mean? Could they be test modes? Or has no one ever thought about using them?
They do not seem to conflict with anything else in the spec other than it saying do not use them. ![Confused](images/smiles/icon_confused.gif) |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Oct 15, 2013 9:14 pm |
|
|
I don't think you're doing this for Microchip PIC's or the CCS compiler so
it's not relevant. You should ask this on a Philips forum, like this one:
http://forums.nxp.com/viewtopic.php?t=4799 |
|
![](templates/subSilver/images/spacer.gif) |
Ttelmah
Joined: 11 Mar 2010 Posts: 19383
|
|
Posted: Wed Oct 16, 2013 12:31 am |
|
|
You just use code 4, that is what it is there for.
You follow it with the address you want to use.
However you need to be _very_ careful using this. Remember that the master does not know how many devices are acknowledging a GCA call. Hence the 'standard' is to only have a small part of the slave address settable, with the rest hard-wired or programmed by location.
Remember there is nothing whatsoever to stop you just using 'normal' writes to set version numbers, ID's etc., after the address is set. The only part that ever needs to be adjusted, without 'knowing' the device address, is the device address itself....
Best Wishes |
|
![](templates/subSilver/images/spacer.gif) |
|