@Diesel drivers:
You're welcome. The tables indicate which CPU registers are responsible for that.
Or, how to initialize the baud rate of the CAN controller – that's not so simple.
I have never done anything with CAN bus programming before
* Berechnung des Bittimings
* 1. Berechnung Tosc = 1/clk
* 2. Festlegen des Bustaktes zB. 100kHz
* 3. Festlegen des Tq durch Baudrate-Prescaler
* Tq = Tosc * BRP
* Tq = 1/(16MHz) * 10 = 62,5nsec * 10 = 625nsec
* 4. Berechnen der Tq pro Bit n * Tq = 1/Busfrequenz
* n = (1/busfrequenz) / Tq
* n = (1/100kHz) / 625nsec
* n = 16
* 5. Aufteilen der n-Tq auf die Zeit-Segmente
* Sync Seg 1Tq per Definition
* Prop Seg 2Tq allg. guter Wert
* Phase1 7Tq allg. guter Wert
* Phase2 6Tq 16 -(1+2+7) = 6
* SJW 1Tq da hier ein Quarz als clk verwendet wird ist entgegen der Daumenregel 1 ein guter Wert
.
I'm starting to consider skipping the Lib and walking instead.
The library would definitely help me, as a newcomer, with quite a few things.
I have now found a reference to the parameters in the Lib Init function.
I'll try using the library for now.
Best regards, Rudi.