> thank you for your code. I wonder to know if
"spi.h" is important in the code that you posted.
> I tested my code with SPI Debugger and found that the LPC2138 only
transfers 8 bit data eventhough I set to transfer 12 bit! If your code already
work fine with the real device, I think this might the problem with the
simulation software. Thank you very much for your help.
I NEVER use simulation. It isn't real hardware and my code ultimately has
to run on hardware.
spi.h is unimportant, it simply defines the two functions:
Richard
Problem of using LPC2138 to SPI interface with DAC LTC1451
Started by ●June 6, 2013
Reply by ●June 7, 20132013-06-07
Reply by ●June 9, 20132013-06-09
> thank you for your code. I wonder to know if
"spi.h" is important in the code that you posted.
> I tested my code with SPI Debugger and found that the LPC2138 only transfers 8 bit data eventhough I set to transfer 12 bit! If your code already work fine with the real device, I think this might the problem with the simulation software. Thank you very much for your help.
At this line:
Are you sure that the compiler issues an 16 bit write to the S0SPDR register?
> I tested my code with SPI Debugger and found that the LPC2138 only transfers 8 bit data eventhough I set to transfer 12 bit! If your code already work fine with the real device, I think this might the problem with the simulation software. Thank you very much for your help.
At this line:
Are you sure that the compiler issues an 16 bit write to the S0SPDR register?
Reply by ●June 9, 20132013-06-09