On Thu, Jun 10, 2010 at 6:00 AM, Lei Luo <[email protected]> wrote: > Hi, >
Hi, > The bitrate is 500000, the SPI speed is 5*1000*1000. Is That too high? the maximum SPI speed for mcp2510 is 5 Mhz, for 2515 is 10 Mhz. Try to lower a bit to see if something improves please. > phase_seg2 = 4. Is that does matter? the data on the CAN bus is protected by CRC. So it's very improbable that an error can happen there. You should see data going through all right or nothing at all. This is the reason why I'm suggesting to do some tests on the SPI bus. Another thing to try is to add .delay_usecs = 1, to struct spi_transfer t in mcp251x_spi_trans. Perhaps your platform is too fast (BTW which one are you using?) and the CS change doesn't get taken in account by the mcp (in this case you should always see a previous value in case of error when you are using cangen with increment). ASAP I will do some tests, unfortunately right now I don't have the hardware (this is the sad life of consultants, when you finish a job you are thrown on something else and left without hardware). -- Christian Pellegrin, see http://www.evolware.org/chri/ "Real Programmers don't play tennis, or any other sport which requires you to change clothes. Mountain climbing is OK, and Real Programmers wear their climbing boots to work in case a mountain should suddenly spring up in the middle of the computer room." _______________________________________________ Socketcan-users mailing list [email protected] https://lists.berlios.de/mailman/listinfo/socketcan-users
