Closed sshane closed 6 months ago
Close if we don't want to spend any time on this
Was confusing for Nick who was doing a car port, who's used to the three method of storing the returned bus. We should just pick one and stick with it.
bxcan stores the destination bus (CAN buffer number - 128 means delivered on bus 0): https://github.com/commaai/panda/blob/c118c2887d0b9029957b63069e8d8e57b8c530b4/board/drivers/bxcan.h#L136-L141
fdcan stores the source bus (CANPacket_t bus - 128 means origin is bus 0): https://github.com/commaai/panda/blob/c118c2887d0b9029957b63069e8d8e57b8c530b4/board/drivers/fdcan.h#L130-L134
Let's fix this
Close if we don't want to spend any time on this
Was confusing for Nick who was doing a car port, who's used to the three method of storing the returned bus. We should just pick one and stick with it.
bxcan stores the destination bus (CAN buffer number - 128 means delivered on bus 0): https://github.com/commaai/panda/blob/c118c2887d0b9029957b63069e8d8e57b8c530b4/board/drivers/bxcan.h#L136-L141
fdcan stores the source bus (CANPacket_t bus - 128 means origin is bus 0): https://github.com/commaai/panda/blob/c118c2887d0b9029957b63069e8d8e57b8c530b4/board/drivers/fdcan.h#L130-L134