+ All Categories
Home > Documents > JMDC Application Software (JAP)

JMDC Application Software (JAP)

Date post: 02-Feb-2016
Category:
Upload: urbana
View: 49 times
Download: 0 times
Share this document with a friend
Description:
JMDC Application Software (JAP). Xudong CAI / MIT. Sep.1, 2009 @ CERN. Current Status. Communication: All AMSWire and CAN master slave modes are implemented and tested except JIM-CAN “bypass” mode. All HRDL and 1553 communications are implemented and tested. They are in use. - PowerPoint PPT Presentation
10
JMDC Application JMDC Application Software (JAP) Software (JAP) Xudong CAI / MIT Sep.1, 2009 @ CERN
Transcript
Page 1: JMDC Application Software (JAP)

JMDC Application Software (JAP)JMDC Application Software (JAP)

Xudong CAI / MIT

Sep.1, 2009 @ CERN

Page 2: JMDC Application Software (JAP)

Current StatusCurrent Status Communication:

• All AMSWire and CAN master slave modes are implemented and tested except JIM-CAN “bypass” mode.

• All HRDL and 1553 communications are implemented and tested. They are in use.

• RS422 has implemented but not tested yet.

• JBUX/JBU has partly implemented under debugging.

Flash file system and file control:• File system is implemented and compatible with JROM

• The file system operations are also compatible with JROM (the support for the data types).

• AMS file transfer protocol has been modified and unified between JAP and JROM.

• Support file copy between JMDCs

Node address control: • Node addresses can be controlled by commands now.

• Node address timeout counter and disable function not yet finished. (Proposed by Alexei)

Sep.1, 2009 2JMDC Application Software (JAP)

Page 3: JMDC Application Software (JAP)

Current Status (continued)Current Status (continued) Q-List:

• Counter based Q-List has completed (AMS-1 style)

• Time based Q-List is under discussion

Envelop commands:• AMSWire and CAN envelop commands are implemented.

• Envelop AMS blocks are implemented and under tests.

Command file execution:• Command file execution is implemented and under tests

• There is a way to execute command file with new node address. (Proposed by Alexei)

Flash file as block data:• A data type is implemented to use a flash file as part of data append at the end of

command. (Proposed by Paolo)

It is ready to implement DAQ and Slow Control tasks whenever the procedures are defined.

Sep.1, 2009 3JMDC Application Software (JAP)

Page 4: JMDC Application Software (JAP)

Node Address ControlNode Address Control

Node Address Table Item (Total 512 items)

Word 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Comments0 Type Error Count Size  1

Address

CAN: 2 words CAN Message IDAMSW: 0xCnnn is used to copy pathes from node "nnn".

234567

Sep.1, 2009 4JMDC Application Software (JAP)

Node Types

Name Code Comments

Undefined 0x00 Node is not defined.

Self 0x55 It is used for JMDC itself. For example, HRDL owner will have 0x10 address marked as itself.

Alias 0x77 It makes one node equal to another node. For example, JINJ-PA = JINJ-0

AMSW 0xAA It marks address for AMSW and address area gives the path starting from JMDC ports.

CAN 0xCC It marks address for CAN and CAN message ID is in the first two words of address area.

External 0xEE It's JMDC external addresses for HRDL/RS422/1553 and ACOP/DDRS2.

Page 5: JMDC Application Software (JAP)

Nodes Address Control (continued)Nodes Address Control (continued)

The real AMSW path has to start from JMDC links. There is a special way to define the path to be copied from another node.

For example:• JINJ-0 (0x80) : 0x0001

• JINJ-P (0x84) : equal to JINJ-0

• JINF-T0-A (0xA6) : 0xC084 0x033F

• JINF-T0-P (0xA8) : equal to JINF-T0-A

• TDR0-00-A (0x11A) : 0xC0A8 0x003F

• Real address of JINF-T0-A : 0x0001 0x033F

• Real address of TDR0-00-A: 0x0001 0x033F 0x003F

It is also possible to define a group address for AMSW. For example all TDRs in T-0.

Sep.1, 2009 JMDC Application Software (JAP) 5

JMDC AMSWire Path TableNodes JINJ-0 JINJ-1 JINJ-2 JINJ-3 JMDC-0 JMDC-1 JMDC-2 JMDC-3

JMDC-0 0x0001 0x0102 0x0204 0x0308 - 0x0411 0x0412 0x0414JMDC-1 0x0001 0x0102 0x0204 0x0308 0x0411 - 0x0412 0x0414JMDC-2 0x0001 0x0102 0x0204 0x0308 0x0411 0x0412 - 0x0414JMDC-3 0x0001 0x0102 0x0204 0x0308 0x0411 0x0412 0x0414 -

Page 6: JMDC Application Software (JAP)

Command file / Envelop AMS BlockCommand file / Envelop AMS BlockEncapsulated AMS Block Request

Bits 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Comments

AMS Block Header(Envelop)

L Size (number of bytes) of the block exclude "size" and "size extension" word  Size extension if "L" = 1 May not exist

0 RW Node Address 1 1 1 1 1Data type=0x1F0380

0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0

FBI 0 NL Secondary header tagIR: Include request in replyNL: No HK-1553 reply

AMS Block 0(Encapsulated)

L Size (number of bytes) of the block exclude "size" and "size extension" word  Size extension if "L" = 1  

0 RW Node Address Data Type  Data type extension if "Data type" = 0x1F May not exist

FBI IE 0 Secondary header tag (maybe the same as envelop) IE - Ignore error

Request Data Bytes …May not alinged to

16-bit wordMore AMS Blocks … … May not exist

Encapsulated AMS Block Reply

Bits 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Comments

AMS Block Header(Envelop)

L Size (number of bytes) of the block exclude "size" and "size extension" word  Size extension if "L" = 1 May not exist

1 RW Node Address 1 1 1 1 1Data type=0x1F0380

0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0Status Secondary header tag  

Secondary header time tag (MSB)  Secondary header time tag (LSB)  

AMS Block 0(Encapsulated)

L Size (number of bytes) of the block exclude "size" and "size extension" word  Size extension if "L" = 1  

RR RW Node Address Data Type  Data type extension if "Data type" = 0x1F May not exist

Status Secondary header tag  Secondary header time tag (MSB) Reply only and can be

different from the envelopSecondary header time tag (LSB)

Reply Data Bytes … May not existMore AMS Blocks … … May not exist

Sep.1, 2009 JMDC Application Software (JAP) 6

Page 7: JMDC Application Software (JAP)

Command File / Envelop AMS BlocksCommand File / Envelop AMS Blocks Envelop AMS block will put replies from sub blocks in a envelop and send

together. You will not get replies until all sub-blocks are executed. Command file will be executed in separate tasks (there are five of them).

The command is replied if command file execution started. All blocks in command file will be executed one by one. The reply will not be packed and will be sent to HK streams not depend on the command source.

The current status of command file executions can be obtained from JMDC.

Command file execution can be stopped by command. One level nesting is allowed and will be executed by the same task as the

original command file. This is under debugging. Alexei has provided graphic tools to control the command file executions

Sep.1, 2009 JMDC Application Software (JAP) 7

Page 8: JMDC Application Software (JAP)

Counter based Q-ListCounter based Q-List There are two parameters to control the execution frequency of the Q-List.

• Wait time between items (32-bit word defines time in ms)

• Wait time at the end of loop (32-bit word defines time in ms)

Each item has a 16-bit word which defines the priority (in how many loops the command to be executed once).

The Q-List table can be read or write by command. The table items cannot be modified by command. (Proposed by Alexei)

The item priority can be changed by command. Priority 0 means the item is disabled.

Q-List is a system task now (was belong to MCT and related to the MCT ownership). All JMDC can have its own Q-List.

Alexei has provided graphic tool to control the Q-List.

Sep.1, 2009 JMDC Application Software (JAP) 8

Page 9: JMDC Application Software (JAP)

AMS File Transfer ProtocolAMS File Transfer Protocol Alessandro is working on the graphic interface to support it. I have made a command line program can be used from our ground

support computers. Usage: jftp [options]

Options:{-? --help} Show this listing.

{-d --debug} debug Bigger is more.

{-v --server} server Server computer name or IP string (def: localhost)

{-a --port} port eAss server port name or number (def: hrdl)

{-s --segsize} seg_size Segment length for transfer in byte (def: 4000)

{-f --name} jname File name at JMDC (def: jap_test.img)

{-n --node} node JMDC node address (def: 4)

{-h --handle} handle Transfer handle (def: random)

{-g --get} gname Get file (downlink) and file (def: put)

{-p --put} gname Put file (uplink) and file (def: ~/jmdcfiles/jap.img)

{-e --exec} Execute after uplink transfer (def: save)

{-c --continue} Continue uncompleted transfer (def: new)

For example:

jftp –v pcgsc13 –a hrdl –s 4000 –f test.dat –n 7 –p /home/ams/config/test.dat

jftp –v pcgsc10 –a 1553 –s 400 –f test.dat –n 7 –g /home/ams/config/test.dat

Sep.1, 2009 JMDC Application Software (JAP) 9

Page 10: JMDC Application Software (JAP)

DocumentDocument There is a “AMS-02_datatypes.xls” file on AMS web site which is updated

automatically every night. The address is http://ams.cern.ch/AMS/DAQ/AMS-02_datatypes.xls

I try to keep all information and formats inside. The data types marked with green color are implemented in the current version of JAP.

Sep.1, 2009 JMDC Application Software (JAP) 10


Recommended