can demo kit

25
CAN Microcontrollers Demo-kit C51/C251 Demo Board CAN Extension Board Users Manual

Upload: zeke-steer

Post on 24-Oct-2014

37 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Can Demo Kit

CAN MicrocontrollersDemo-kit

C51/C251 Demo BoardCAN Extension Board

User�s Manual

Page 2: Can Demo Kit

C51/C251 Demo Board

C51/C251 Demo Board User�s Manual

1. IntroductionThe C51/C251 Demo Board allows an easy evaluation of most of Atmel Wireless & Microcontrollers C51/C251devices. The C51/C251 Demo Board can be powered using a simple 9V battery or using a 9V rechargeable battery.The C51/C251 Demo Board can also be used as programming tool for the Flash products.

2. Features• A LCD display (2 lines of 16 characters).• A eight led bargraph.• A 128kB Flash memory• Three different sockets: PLCC44, PLCC68 & DIL24.• An In System Programming (ISP) software to download HEX files in flash memory.• Hardware capability to program the microcontrollers on-chip Flash memory.• Extension Connectors for special feature, application, new product, or demo.

3. Content • One PCB C51/C251 Demo Board (with battery connector).• One Serial cable (1.8m length)• This User�s Manual.• ISP Program for the Flash products.• ISP Demo Board Source and Code to program external flash memory.• Source and Code of various demos software.

4. C51/C251 Support, WWW linksAll code and source files can be found for free on our web site at http://www.atmel-wm.com. Questions can be sent to: [email protected]

Figure 1. C51/C251 Demo Board

Rev. B - Jan 12, 2001 1

Page 3: Can Demo Kit

C51/C251 Demo Board

5. Hardware Description

5.1. Block Diagram

Figure 2. Block Diagram

5.2. Specifications

5.3. Supported PartsMost of Atmel Wireless & Microcontrollers C51 and C251 microcontrollers are supported.

The Demo Board does not support low voltage parts only 5V parts are supported.

5.4. Board supply considerations• Power connector J1 or battery connector J2 may be used to power the board.• On J2 connector a rechargeable battery or a non rechargeable battery may be used either.• In case of rechargeable battery usage on J2, if J18 is ON the battery is charged when the board is powered by J1.• Board may be powered by J2 for about 10 hours with one new non rechargeable battery.

Parameter Typ Max Unit

Supply DC voltage 9 12 V

Supply DC current 200 mA

Consumption at 12 MHz 60 100 mA

Consumption at 60 MHz in X2 mode 110 150 mA

Non rechargeable battery capacity 550 mAh

Rechargeable battery capacity 150 mAh

Reset & INT1#

Power interface

RS232

C51/C251 LCD 2*16

Bargraph

Config switches

128 K Flash memoryGlue

Synchro connectors

To All Extensionsconnector

2 Rev. B - Jan 12, 2001

Page 4: Can Demo Kit

C51/C251 Demo Board

J18 MUST BE OFF, WHEN THE BOARD IS POWERED BY J1

WITH A NON RECHARGEABLE BATTERY CONNECTED ON J2 (See Figure 3)

Figure 3. C51/C251 Demo Board powered by J1 with a non rechargeable battery on J2

Figure 4. C51/C251 Demo Board powered by J1 with a rechargeable battery on J2

J1 Power Supply Connector9V to 12V DC IN

J18

9VPP3

J2

OFFnon rechargeable

battery

AC-DC

LCD display

LCD display

J1 Power Supply Connector

9V to 12V DC IN

J18

9VPP3

J2

ON

Battery is Being chargedIn this configuration

rechargeablebattery

AC-DC

Rev. B - Jan 12, 2001 3

Page 5: Can Demo Kit

C51/C251 Demo Board

Figure 5. C51/C251 Demo Board powered by J2.

5.5. Board setupOn-Off• Switches ON the power supply.Reset• Resets the microcontrollers.INT1#• Issues an interruption on microcontollers on INT1# pin.J8 Connector• Configure hardware in Page Mode or Non Page Mode.• for C251 microcontrollers. For C51 products, the configuration must be set to Non Page Mode.Synchro IN• Used to connect several C51/C251 Demo Board together, provides global reset / interrupt for all connected

C51/C251 Demo Board.Synchro OUT• Only one power supply is needed but it may be able to deliver enough current to supply all the C51/C251

Demo Board.• There is no rules to connect two boards together anyone of the two DB9 may be useRS232• Used to connect a terminal or through a RS232 serial communication port.• This serial port can be used for displaying messages or for programming external Flash memory.

Note:The cable that connect this RS232 Connector MUST be a pin to pin cable.

J18

ON

J1 Power Supply Connector

9VPP3

J2

battery

NOT USED

(rechargeable or not)

LCD display

4 Rev. B - Jan 12, 2001

Page 6: Can Demo Kit

C51/C251 Demo Board

Figure 6. C51/C251 Demo Board

J11

J9

J16

RS232 Cable to Terminal

J8

J8

LCD CTRST+

RESET

INT1

OFFON

J17

R21

Page Mode

Non Page Mode

Synchro IN Synchro OUT

RS232

LCD

111

X2

X3X1

PLCC44

PLCC68

DIL24

Extension connector

Rev. B - Jan 12, 2001 5

Page 7: Can Demo Kit

C51/C251 Demo Board

J11 Switches

(Set=1, Clear=0)Figure 7. J11 Switches

J9 Switches

Figure 8. J9 Switches

J16 Switches

Figure 9. J16 Switches

7 6 5 4 3 2 1 0

ISP ALE PSEN UC4 UC3 UC2 UC1 UC0

Bit Number Bit Mnemonic Description

7 ISP1In System Programming (external Flash memory)Set to enable external Flash memory programming Clear to protect external Flash memory from erasure and programming

6 ALEAddress Latch EnableSet to see ALE activityClear to ground ALE

5 PSENProgram Store EnableSet to run demosClear to program T89C51RD2 on-chip Flash memory

4-0 UC4:0 User CodeFree of use as data input for demos.

1 0

MAP SELECT EA

Bit Number Bit Mnemonic Description

1 MAP SELECTMap SelectSet to select external Flash memory zone from $10000 to $1FFFFClear to select external Flash memory zone from $00000 to $0FFFF

0 EAExternal AddressSet to fetch internal code (on chip code).Clear to fetch code from external Flash memory

0

ISP2

Bit Number Bit Mnemonic Description

0 ISP2

In System Programming 2 (external Flash memory)RESERVEDMUST BE OFF (set to 1)

6 Rev. B - Jan 12, 2001

Page 8: Can Demo Kit

C51/C251 Demo Board

Figure 10. Switch Configuration

Socket and Quartz Crystal

The C51/C251 Demo Board provides three different sockets for microcontrollers, a PLCC44, a PLCC68 and a DIL24.

Each socket has it own quartz crystal X1, X2 and X3.

Only one Atmel microcontroller must be plugged at one time, in one of the three socket.

Crystal may be easily changed on each socket.

J11

PSENALEISP1

User C

ode

1 0

1 0

J11

J9

J16

J9

J16

EAMAP SELECT

ISP2

RS232 Cable to PC

0

7

Set = 1Clear = 0

OFF

Rev. B - Jan 12, 2001 7

Page 9: Can Demo Kit

C51/C251 Demo Board

6. Operation mode

6.1. Flash Products

6.1.1. Switch Configuration

To program the on-chip Flash memory, hardware configuration of the chip

should be the following: PSEN = 0, EA = 1 and ALE = 1 or not connected.

On C51/C251 Demo Board, switches must be as shown on Figure 11

Figure 11. C51/C251 Demo Board Switches Configuration to use ISP.

6.1.2. Running ISP

The C51/C251 Demo Board must be connected to a PC com port via RS232 cable connected to RS232 connectorof C51/C251 Demo Board.

After downloading you can run your code by switching PSEN on J11 to 1 and press RESET push button.

J11

PSENALEISP1

User C

ode

1 0

1 0

J11

J9

J16

J9

J16

EAMAP SELECT

ISP2

RS232 Cable to PCPosition don�t care

Position needed

8 Rev. B - Jan 12, 2001

Page 10: Can Demo Kit

C51/C251 Demo Board

6.2. ISP External Flash Memory ModeExternal flash memory might be programmed using Windows(1) hyper terminal or any terminal able to send HEXfile in text mode.

6.2.1. Hardware configuration

The C51/C251 Demo Board must be connected to PC com port with cable connected to RS232 connector J10.

Switch must be set as shown on figure 12.

PLCC44 socket and X1 Quartz crystal will be used to program external flash memory. X1 must be 11.0592 Mhzand Atmel microcontroller must be plugged into PLCC44 socket.

Figure 12. C51/C251 Demo Board Switches Configuration to program external flash memory.

6.2.2. Terminal Configuration

Use the following configuration for the terminal.

Parameter Value

Bauds 9600

Data bits 8

Stop bits 1

Parity None

Flow control Xon-Xoff

J11

PSENALEISP1

User C

ode

1 0

1 0

J11

J9

J16

J9

J16

EAMAP SELECT

ISP2

RS232 Cable to PC

Position don�t care

Position needed

Rev. B - Jan 12, 2001 9

Page 11: Can Demo Kit

C51/C251 Demo Board

6.2.3. ISP Operation

First connect C51/C251 Demo Board to PC com port with cable.

Run Windows (see Note 2) hyper terminal and configure it with above parameter. (see figure13)

Figure 13. Com port configuration

Figure 14. Terminal window on running ISP

10 Rev. B - Jan 12, 2001

Page 12: Can Demo Kit

C51/C251 Demo Board

Turn on the C51/C251 Demo Board and then follow instruction on terminal screen and LCD display.After erasingflash, the program ask for memory zone, and then ask to send HEX file in text mode.(see figure 14, 15 & 16)

Figure 15. Send HEX file in text mode

Figure 16. Use *.* in selection zone to see HEX files into directory

Rev. B - Jan 12, 2001 11

Page 13: Can Demo Kit

C51/C251 Demo Board

After the download of HEX file, the program ask if you want to download another HEX file in the second

zone of the external flash memory.

In this case you�ll have to switch MAP SELECT (to access second zone) and send another HEX file in text mode.

All the external flash memory (128Kbytes) is erased when ISP is used, even if you only want do download one zone.

If you have one external flash memory zone programmed, and later you want to add another program to the

second memory zone, you will have to download both program at the same time.

Notes:1. The data transfer is seen on bar graph.2. Windows is a trademark of Microsoft Company

12 Rev. B - Jan 12, 2001

Page 14: Can Demo Kit

C51/C251 Demo Board

6.3. Demo ModeIn demo mode, programs stored into external flash memory are executed to demonstrate capability of AtmelMicrocontrollers. To run external code we must have EA=0.

In this mode the first four bits of J11 (UC3:0) are used to select demo program and UC4 is used to select display(LCD or RS232).

Figure 17. Switch utilities in Demo mode

6.3.1. C51 mode

In C51 mode (Non Page Mode) switch J8 must be as shown in figure 18

Figure 18. C51 mode (Non Page Mode)

6.3.2. C251 mode

In C251 mode microcontroller can be used in Page Mode or Non Page Mode.

For Non Page Mode switch J8 must be in the same configuration as in C51 mode

J11

PSENALEISP1

User C

ode

1 0

1 0

J11

J9

J16

J9

J16

EAMAP SELECT

ISP2

Used to select demo program

Used to select display

Used to select memory zone

J11

J9

J16

J8

NON PAGE MODE

Rev. B - Jan 12, 2001 13

Page 15: Can Demo Kit

C51/C251 Demo Board

For Page Mode switch J8 must be as shown in figure 19

Figure 19. C251 mode (Page Mode)

J11

J9

J16

J8

PAGE MODE

14 Rev. B - Jan 12, 2001

Page 16: Can Demo Kit
Page 17: Can Demo Kit
Page 18: Can Demo Kit
Page 19: Can Demo Kit
Page 20: Can Demo Kit
Page 21: Can Demo Kit
Page 22: Can Demo Kit

CAN Extension Board

CAN Extension Board User�s Manual

1. IntroductionThis board is an evaluation board dedicated to the Atmel T89C51CC01 microcontroller. The CAN demoboardExtension is plugged to the demoboard connector. All features provided by the demoboard can be used (LCD, ledbargraph, 128kB Flash memory, hardware capability to program the T89C51CC01 on-chip Flash memory, etc.).

2. FeaturesThe CAN Demoboard Extension works with the following T89C51CC01 features:• CAN (on board CAN transceiver SI9200DY).• Two different sockets for transceiver: DIL8 & SO8.• D-sub connectors compliant to the CiA (User Group:"CAN in Automation") recommendation for the CAN High

Speed Bus.• Analog-to-Digital Converter (Connector for ADC reference voltage VAGND and VAREF).

3. C51/C251 Support, WWW linksAll code and source files can be found for free on the Atmel Wireless & Microcontrollers website at

http://www.atmel-wm.com

Figure 1. CAN Demoboard Extension

Rev. A - Jan 12, 2001 1

Page 23: Can Demo Kit

CAN Extension Board

4. Hardware Description

4.1. Block Diagram

Figure 2. Block Diagram

4.2. CAN PartsDifferent kinds of transceiver can be plugged on the board (Si9200, PCA82C250 ...) on socket DIL8 or SO8.Please pay attention to have only one transceiver on the board.

Jumper J10 allows to connect or not the 120 Ohm termination resistance. The CAN High Speed Bus must beterminated at both ends with a termination resistance for proper operation.

Figure 3. Pinning of the D-sub 9 connector

Reset & INT1#

RS232

T89C51CC01

LCD 2*16

Bargraph

Config switches128 kB

CAN

Synchro connectors

Flash memory

ADC reference

Transceiver

Glue

D-sub connector

Port 0, 1, 2 & 3

1 2 3 4 5

6 7 8 9

Pin 1: N.C.Pin 2: CAN_LPin 3: GNDPin 4: N.C.Pin 5: N.C.Pin 6: GNDPin 7: CAN_HPin 8: N.C.Pin 9: N.C.

2 Rev. A - Jan 12, 2001

Page 24: Can Demo Kit

CAN Extension Board

4.3. ADC PartsTo use ADC feature, a reference voltage must be applied on VAGND and VAREF (3 Volts).

When the ADC is addressed, you cannot control the LCD or the led bargraph because Port1 must be left free.Therefore pay attention on P3.2 and P3.4 states that are used to select LCD and bargraph (see Table 1).

The Port 1 pins are input for Voltage to convert.

Table 1. Chip select Description

P3.4 P3.2 Designation

0 0 LCD selected

0 1 led bargraph selected

1 0 switch selected

1 1 ADC/Port1 selected

Rev. A - Jan 12, 2001 3

Page 25: Can Demo Kit