theganeshlalu
Posts: 1
Joined: Thu Sep 07, 2017 10:26 pm

CAN Controller: NO BUFFER SPACE error

Thu Sep 07, 2017 10:39 pm

Hi. I am trying to make a CAN gateway which interfaces 2 CAN networks working at 2 different speeds ie 500kbps and 125kbps. I have used Rpi3 with piCAN2 Duo . I have used python-can libraries and in the code I have 2 different processes. One process(Process A) will monitor messages from CAN A(500kbps) and other process( Process B ) will monitor messages from CAN B(125kbps). I have used filters in both CAN ports so that both receives only messages with a particular message id. When Process A receives a message, it checks for some values in the data byte and then it creates a new CAN message and sends it to CAN B. Similarly Process B receives a message from CAN B and based on the data byte values, it will create another CAN message and send it to CAN A. I have used multiprocessing in python for the 2 processes. But when I am sending messages from both sides using CANoe , one of the processes stops working with an OS error: NO BUFFER SPACE AVAILABLE when it is trying to send the message via the CAN socket. I assume the error is because either the SPI buffer is overflowing or the buffer in the CAN controller is not able to handle the messages at this rate especially when it is sending from 500kbps to 125 kbps. Can someone help me? I am stuck with this for the last 2 weeks. Any help would be really helpful.

inky699
Posts: 8
Joined: Mon Mar 20, 2017 11:27 am

Re: CAN Controller: NO BUFFER SPACE error

Thu Sep 14, 2017 4:21 pm

I had the same problem, Ensure the termination resistor is engaged, as not having this will prevent the piCAN2 Duo sending data on the bus and returning this error message.

Good luck

Return to “Troubleshooting”

Who is online

Users browsing this forum: FTrevorGowen, MrWheeliebin and 51 guests