Thanks for that, so even with the software 'remarked' out for the HMC6352 but with the devices connected there is a hardware conflict which still exists because two devices without an address identifier are sharing the same bus? I'll re-wire the GPS device tonight to p13,p14 and reinstate the serial command.
Just to clarify:
All I2C devices need an address. The lib constructor methods for SRF08 and TMP102 include the address in the parameterlist to explicitly show the address or because these devices can have one of several addresses depending on the logic levels on one of their configuration pins. This feature allows you to use multiple devices of the same type on one I2C bus. Obviously every device needs to have a unique address to avoid I2C bus conflicts.
The HMC6352 compass also has a unique I2C address but it is hardcoded and hidden in the software.
All three lib methods declare an I2C bus internally using the provided pinnumbers (p9,p10).
The internal object will configure these pins to connect with the lpc1768 I2C hardware engine.
The GPS unit needs a serial port. Hardwarewise this is completely different from I2C. It just happens that p9,p10 can also be configured to connect to the lpc1768 serial port hardware engine.
The problem with the software is that the libs first configure p9,p10 to connect with the I2C bus (3x over actually, but that works) and then, when the GPS object does its initialisation, these pins get reconnected to the serial port engine, breaking the I2C.
Without precautions in the software (ie always reconfiguring the pins before every use) this will lead to problems. It will lead to problems anyhow because the GPS will typically send its position messages automatically once per second no matter what, while the mbed needs to be the master on the I2C bus and initiate all communications with its I2C slaves. This means corrupted messages on I2C and possibly even shortcircuits with the transmitting GPS.
Had the following program fine, now added the GPS code which compiles correctly but all I see on the lcd screen is what's at line 27??? Also as you can see I've remarked out the HMC6352 because I'm thinking either the HMC6352 needs an address or the GPS needs an address I'm I correct?
Thank you in advance