examples/gene_SYNC_HCS12/readme.txt
author frdupin
Wed, 13 Dec 2006 14:48:04 +0100
changeset 55 96173dd44f2c
parent 54 a2ca09ac1523
child 57 522ece4057d2
permissions -rw-r--r--
unused variable deleted
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     1
Generator of Canopen SYNC message (cobid = 0x80)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     2
---------------------------------------------
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     3
francis.dupin@inrets.fr
54
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
     4
27 Janv 2005. 
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
     5
Revised 13 Dec 2006
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     6
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     7
54
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
     8
Status of the code :
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
     9
====================
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    10
Tested with 
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    11
- CanFestival 3 rc2 (cvs version)
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    12
- gcc port for HC12 release 3.1
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    13
- Microcontroler MC9S12DP256 
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    14
on board  T-board (http://www.elektronikladen.de)
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    15
54
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    16
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    17
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    18
To build the example
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    19
--------------------
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    20
a) Compile CanFestival for hcs12 :
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    21
  Go to the root of CanFestival and enter
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    22
  ./configure --target=hcs12
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    23
  make clean all
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    24
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    25
b) Build the example
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    26
--------------------
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    27
 cd examples/gene_SYNC_HCS12
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    28
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    29
 make clean all
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    30
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    31
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    32
What does the node ?
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    33
====================
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    34
Just reset it, it should send the SYNC (cobId 0x80) every 10 ms
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    35
Informations availables if you connect the serial port 0 to a terminal configured at 38400 8N1
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    36
				   
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    37
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    38
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    39
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    40
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    41
The default values :
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    42
nodeId = 0x03
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    43
CAN rate = 250 kbps
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    44
Please read appli.c, these values can be modified by switch.
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    45
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    46
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    47
If you put the node in operational state, the CAN messages received are filtered : Only the NMT and Nodeguard can be received.
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    48
The parameters of the filter are mapped in the object dictionary, so that the filter can be configured by SDO before entering in operational state. See the object dictionary index 2015 to 2023. To have the values applied, always download at 0x2023 index 0 the value 1 before entering in operational.
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    49
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    50
Read the file objdict.c to see the capabilities of the node. 
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    51
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    52
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    53
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    54
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    55
54
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    56
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    57
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    58
a2ca09ac1523 Tested. OK on Canfestival 3 rc2
frdupin
parents: 0
diff changeset
    59