View previous topic :: View next topic |
Author |
Message |
MikeW
Joined: 15 Sep 2003 Posts: 184 Location: Warrington UK
|
CANBus in Time-TriggeredCAN mode |
Posted: Sat Jan 19, 2013 3:18 am |
|
|
I posted this on the useless microchip forum, but go to replies.
Are there any CANBus guru's who know the answer to this
I am planning to use a PIC24 for a time triggered CAN application.
having read several datasheets, it becomes apparent that to have TTCan, the transmitter must not retry in the event of a failure.
Holt Integrated circuits call it "anti babble mode" or
"One-Shot Mode Enable.
OSMis intended to be usedONLYwith theTX1M bit. IfOSMis enabled andTX1M is set, the
controller transmits only once and does not attempt re-transmission upon loss of arbitration or
error. This feature is necessary to support the implementation of fixed time slots in the
Time-TriggeredCANstandard (TTCAN)."
This seems to be implemented in the MCP2515 as
"3.4 One-Shot Mode
One-Shot mode ensures that a message will only
attempt to transmit one time. Normally, if a CAN
message loses arbitration, or is destroyed by an error
frame, the message is retransmitted. With One-Shot
mode enabled, a message will only attempt to transmit
one time, regardless of arbitration loss or error frame.
One-Shot mode is required to maintain time slots in
deterministic systems, such as TTCAN. "
This feature seems to be missing in the CAN and ECAN modules inside PIC's, or am I wrong |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19592
|
|
Posted: Sat Jan 19, 2013 5:52 am |
|
|
Not a CAN person myself, but of the programmers I worked with did this. If I remember correctly he used the IRXIF bit and set the bus to receive only mode when this occurred.
Best Wishes |
|
|
MikeW
Joined: 15 Sep 2003 Posts: 184 Location: Warrington UK
|
|
Posted: Sat Jan 19, 2013 11:04 am |
|
|
@Ttelmah,
could you re-check with your software guys and confirm this.
I will get fired if I make the wrong decision.
but why oh why did microchip not include this mode ( rhetorical question)
Mike |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19592
|
|
Posted: Sat Jan 19, 2013 2:08 pm |
|
|
Apologies, no, they were with a company I no longer deal with. It was just a 'memory' from a project where this was needed.
Best Wishes |
|
|
newguy
Joined: 24 Jun 2004 Posts: 1911
|
|
Posted: Mon Jan 21, 2013 11:15 am |
|
|
Workaround would be to monitor the number of transmit errors. If nonzero, blow all outbound CAN buffers.
Sorry I can't be more helpful - I've never enabled or worked with the so-called one shot mode. |
|
|
|