Fixed bug in can.s: CAN->BTR |= -->> CAN->BTR =

This commit is contained in:
eddyem
2020-06-02 17:55:36 +03:00
parent 31aaaeccf6
commit e9b497f827
53 changed files with 3 additions and 3 deletions

View File

@@ -135,7 +135,7 @@ void CAN_setup(){
CAN->MCR &=~ CAN_MCR_SLEEP; /* (3) */
CAN->MCR |= CAN_MCR_ABOM;
CAN->BTR |= 2 << 20 | 3 << 16 | 59 << 0; /* (4) */
CAN->BTR = 2 << 20 | 3 << 16 | 59 << 0; /* (4) */
CAN->MCR &=~ CAN_MCR_INRQ; /* (5) */
while((CAN->MSR & CAN_MSR_INAK)==CAN_MSR_INAK) /* (6) */
{

0
F0-nolib/canbus/src/canbus.bin Normal file → Executable file
View File