Page 1 of 1
Even more questions on I2C
Posted: Wed Sep 24, 2008 2:03 pm
by Alberto_82
Hi to all, guys!
My problems with i2c bus are driving me crazy!
I\'ve tried to dial with a compass, HMC6352 by Honeywell, but I didn\'t receive no answers. So I\'ve taken my oscilloscope to see if signals sequence on pins RG3_PIN56 and 57 (i2c port n°1) was right.. Surprise: no signal were sent by the Flex to the sensor. I tried to set and reset I2C1CONbits.I2CEN bit, to send the sensor as start sequence by the I2C1CONbits.SEN bit, but the line was kept low.
I don\'t know what to do...
Please help me!!
Tnx...
/Alberto
Re:Even more questions on I2C
Posted: Wed Sep 24, 2008 2:12 pm
by paolo.gai
Alberto,
did you used the I2C code we used for the I2C compass in the Embedded World 2007 demo? I remember I have seen the device working...
bye
PJ
Re:Even more questions on I2C
Posted: Wed Sep 24, 2008 3:12 pm
by Alberto_82
yes I did! But nothing works...
The problem is that I have to use it for my Thesis.. I\'m of University of Pavia, Tullio is my supervisor and told me to contact you!!
Bye,
/Alberto
Re:Even more questions on I2C
Posted: Thu Sep 25, 2008 9:07 am
by nino
You remembered to put the pull-up resistors on I2C bus clock and data lines?
You respected all the init phases? TRISxbits for directions, clock multipliers compatible with the system clock and so on?
Nino
Re:Even more questions on I2C
Posted: Thu Sep 25, 2008 9:54 am
by Alberto_82
Ehm... not at all! Where does the pull up resistors might be placed? I didn\'t know that, sorry. Is it on the EE docs? I\'m going to try finding it, now.
Talkin\' about the TRISxbits: yes, I think I\'ve setted it in the right way, looking to the \"pic30_Embedded_World_2007\" example.
I\'m working to obtain something, now...
Thanks!!!
/Alberto
Re:Even more questions on I2C
Posted: Thu Sep 25, 2008 10:01 am
by nino
In the demo folder you also can find the schematich for the homemade board. In that you can spot the resistors with the right placement and value.
Re:Even more questions on I2C
Posted: Thu Sep 25, 2008 10:14 am
by Alberto_82
Thank you!
I understand where to put the resistors... I\'m going to build the circuit!
Bye,
/Alberto
Re:Even more questions on I2C
Posted: Thu Sep 25, 2008 2:14 pm
by Alberto_82
Thank you Nino!!!
Now it works!!! I\'ve just put the pull-up resistors in the right place and voilà, all works fine!!!
Many thanks...
/Alberto