This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

toolstick + 8051f330 + SMBUS problem

hello,
i have a problem on a developpement board toolstick which is associated to a 8051f330.
for example: electronicdesign.com/.../14025_fig.1.jpg

I want to make make and simule an SMBUS communication but i don't happend

I found an example on the web: www.silabs.com/.../an141.pdf
and i try the first example, 8051 as a master (p24).

When i send a start, i haven't interruption on the SMBUS interrupt and i don't know why.

Thanks for your help and sorry for my bad english, i'm french.

So when i write a STA:

void SMB_Write (void)
{
 while (SMB_BUSY); // Wait for SMBus to be free.
 SMB_BUSY = 1; // Claim SMBus (set to busy)
 SMB_RW = 0; // Mark this transfer as a WRITE
 STA = 1; // Start transfer
}

i don't ho here..

void SMBus_ISR (void) interrupt 7
{
 bit FAIL = 0; // Used by the ISR to flag failed
 // transfers
 static bit ADDR_SEND = 0; // Used by the ISR to flag byte
 // transmissions as slave addresses
 if (ARBLOST == 0) // Check for errors
 {
 // Normal operation
 switch (SMB0CN & 0xF0) // Status vector
 {
 // Master Transmitter/Receiver: START condition transmitted.
 case SMB_MTSTA:
 SMB0DAT = TARGET; // Load address of the target slave
 SMB0DAT &= 0xFE; // Clear the LSB of the address for the
 // R/W bit