The invention provides a method for calculating a frame
collision rate of a frame on a
CAN bus and a method for minimizing
CAN bus resources. The method for minimizing the
CAN bus resources comprises the following steps: S1, setting an initial CAN
bus communication rate; s2, calculating a frame
collision rate of each priority frame planned to run on the CAN
bus based on an Erlang B formula in a queuing theory at the preset rate of the step S1; s3, judging whether the frame
collision rate, calculated in the step S2, of the frame of each priority exceeds the upper limit of the frame collision rate allowed by the frame of the priority or not; if yes, increasing the CAN
bus communication rate in the step S1 and entering the step S2 to continue circulation; if not, lowering the CAN bus communication rate in the step S1 and entering the step S2 to continue circulation; and S4, outputting the minimum communication rate corresponding to the frame collision rate upper limit allowed by the frames not exceeding the priorities so as to complete optimization. The invention provides a set of frame collision rate
algorithm, so that the required minimum bus resource is calculated according to the upper limit of the frame collision rate of each priority frame, and the resource is optimized.