background image

Unified Fieldbus Controller UFC100-L2 – Basic mode operation 

Page 37

 

 

Rev. 1.0 

Proprietary and confidential information of Aniotek Inc. 

21 May 2018 

 

6  T

EST PROCEDURES

 

The procedures to test the hardware are described. These procedures can also be used in device driver with some changes to 
suit the product software. 

6.1

 

Register access 

If the hardware interface to the CPU uses RDY signal, then the registers can be accessed as memory locations. If the RDY is 
not used, but Read and Write cycles are at least 4 cycles of the CLKIN input to the UFC100-L2, the registers can be accessed 
as memory locations. Else, the software should poll ARDY from Status register; and it should Read or Write only if ARDY is 
‘1’. 

6.2

 

Initialization 

The UFC100-L2 requires following settings before it can be used for transmission or reception. 

1.

 

Write 0x80 to Reset register (0x00). 

2.

 

Write to Mode register (0x01). The value depends upon the frequency of the clock input. The internal clock has to 
be 500 kHz – see CLOCK in 2.2.4. Set other fields as following: 

LB = 0, FDP = 1 (for test purpose), PRE = 1 (for test purpose), TFCS = 0, TMD = 0 (assuming using MAU with 
Enable mode). 

3.

 

Write to Interrupt mask (0x06) and Error mask (0x07) registers to enable interrupt, if required. 

4.

 

Write to FIFO control register (0x0B) according to software need. For transmission, it is better to set high threshold. 
For reception, it is better to set low threshold, so that the incoming frame FC and address can be checked. After 
checking these two bytes in the received frame, it is better to set high threshold to reduce the interrupts. For 
hardware test, use any threshold setting. 

5.

 

Write to GAP time register (0x14). The value depends upon the Data Link layer configuration. For test purpose, set 
it to 0x10 (8 bytes). 

6.

 

Write to Watch time register (0x16, 0x17). The value depends upon the Data Link layer configuration. For test 
purpose, set it to 0x20 (32 bytes). 

7.

 

Clear Watch-timer by writing 0x02 to Timer control register (0x1A). 

6.3

 

Frame transmission 

The procedure for transmitting one frame is described. It should be used for testing the hardware including UFC100-L2 and 
external MAU. The product software may use slightly different procedure e.g. it may use Half-duplex. These procedures do 
not use interrupt. 

6.3.1

 

Using non-DMA Write to the Transmit FIFO 

1.

 

Setup a buffer in the memory to store data bytes to be transmitted. Keep the data pattern such that any shorts in the 
data bus can be detected. For example 256 bytes with value from 0x00 to 0xFF can be stored. 

2.

 

Write to Mode register if necessary to update LB, FDP, PRE and TFCS. Note that this register may have been set to 
non-zero value during initialization. 

3.

 

Clear the FIFO status register by writing ‘1’ to CTF in FIFO control register (0x0B). 

4.

 

Write the number of bytes to be transmitted in Transmit frame length register (0x08, 0x09). 

5.

 

Write few bytes in the FIFO data register (0x0D), so that delay in software loop does not cause underrun. 

6.

 

Write 0x04 to Control register (0x02) (TRON is set to ‘1’). Note that the Receiver is disabled. 

7.

 

Poll TFRY in Status register (0x03). As long as this is ‘1’ another byte can be written to the FIFO data. Write all of 
the bytes in the frame to be transmitted. The number of bytes to be written in step 5 and this step has to be equal to 
the value written in the step 4. Otherwise, underrun or TLM error occurs. 

Содержание UFC100-L2

Страница 1: ...Aniotek Inc UNIFIED FIELDBUS CONTROLLER UFC100 L2 BASIC MODE USER S MANUAL...

Страница 2: ...not meant for military space medical or life sustaining equipment Aniotek Inc does not make any warranty of fitness or suitability of this product for any purpose Aniotek Inc reserves the right to ma...

Страница 3: ...t status 8 2 2 8 Error status 9 2 2 9 Interrupt mask 10 2 2 10 Error mask 11 2 2 11 Transmit frame length 11 2 2 12 FIFO control Register 12 2 2 13 FIFO status 13 2 2 14 FIFO data 13 2 2 15 Clock mode...

Страница 4: ...2 4 5 MAU INTERFACE TIMINGS 33 4 5 1 MAU Interface Timings 33 4 6 OTHER TIMINGS 34 4 6 1 Reset Timings 34 4 6 2 Interrupt Timings 34 1 PACKAGE FEHLER TEXTMARKE NICHT DEFINIERT 2 TEST PROCEDURES 37 2 1...

Страница 5: ...atures It is Compliant to IEC 61158 2 Physical layer at 31 25 Kbit s Compliant to IEC 61158 4 Data Link layer RoHS certified 44 pin LQFP package Operating voltage 2 7 to 3 6 V Low current consumption...

Страница 6: ...0 L2 The UFC100 L2 has function package and pins same as UFC100 L1 except in L2 the following pins are not 5 V tolerant Pin Signal 7 RESETn 21 RxS 22 RxA 26 FLT0n 37 CTYP 38 ATYP The UFC100 L2 draws l...

Страница 7: ...7 Vdd P Power plus side 18 Vss P Power negative side 19 TxS O L Transmit signal to medium attachment unit 20 TxEn O H Transmit control to medium attachment unit 21 RxS ICH Receive Signal from medium a...

Страница 8: ...ted only after the entire frame has been stored in this memory The CPU can cancel the current reception The current reception is also cancelled if any error is detected but the Receive FIFO is not cle...

Страница 9: ...IFO 0D DATA R W 0x00 Transmit Receive data to from FIFO 0E Reserved 1 Not used 0F Reserved 1 Not used 10 Clock mode R W 0x00 DL mode Timer enables 11 Timer status R 0x00 Node timer status 12 Node time...

Страница 10: ...er the CPU writes any value to Mode register even if the value to be written is 0x00 so that the internal clock does not start at a higher than the desired frequency Table 4 UFC Mode register Mode Bit...

Страница 11: ...mission the DMA transfer starts when TRON and DMA both are set to 1 The Transmit length register is decremented by 1 for every byte written to the Transmit FIFO The DMA transfer continues until either...

Страница 12: ...asked interrupts are used to activate INTn hardware signal 2 2 6 Status Address 0x03 Reset value 0x82 or 0x83 Table 7 UFC Status register Status Bit no Name 7 ARDY 6 3 Not used 2 RFRY 1 TFRY 0 CD ARDY...

Страница 13: ...control register see 2 2 12 The TFI status becomes 1 only if the last byte of the current transmission has not been read out of the FIFO TFI is reset to 0 when Transmitter has read all bytes of the fr...

Страница 14: ...nd any of the following error is detected during the reception detection of N or N code which is not a part of Start or End Delimiter or End Delimiter is not on the byte boundary or RxA is negated bef...

Страница 15: ...the frame as number of bytes to be transferred from memory to the Transmit FIFO This count does not include Preamble Start Delimiter and End Delimiter The FCS is not included in this count unless tran...

Страница 16: ...field see 2 2 7 RCTRL Threshold 00 8 bytes 01 16 bytes 10 24 bytes 11 32 bytes CTF Clear Transmit FIFO Writing 1 to this field clears the Transmit FIFO its error status and the FIFO becomes empty It...

Страница 17: ...whenever there is at least one byte in the FIFO TFOR Transmit FIFO overrun This field is set to 1 when the Transmit FIFO is full and the CPU or DMA tries to write another byte to Transmit FIFO This fi...

Страница 18: ...bit is automatically cleared to 0 when this register is read NOTE Multiple overflows cannot be detected by this register 2 2 17 Node time Address 0x12 0x13 Reset value 0x0000 This is a holding registe...

Страница 19: ...counter is reset whenever the bus is active This counter is also reset by setting CT bit of Timer control register see 2 2 21 The unit of this register is eight 8 bit time The address 0x16 accesses th...

Страница 20: ...d confidential information of Aniotek Inc 21 May 2018 LTR Latch Token timer Writing 1 to this field snaps the value of the internal Token time counter into Token counter register address 0x18 0x19 CT...

Страница 21: ...e RDY DACKn signal and if the CPU cannot insert enough wait states then it has to use software to poll a status bit ARDY inside UFC100 L2 This bit indicates that it is ready for next cycle 4 The input...

Страница 22: ...t may become low at the start of the Read or Write cycle to indicate that the CPU has to wait It becomes high when the CPU can complete the cycle The Figure 2 shows interface to Renesas microcontrolle...

Страница 23: ...use the non multiplexed bus as shown in the Figure 3 The INT0 input is used for DMA request UFC100 L1 A6 A5 A4 D7 D0 A0 9 8 1 41 36 29 CSn RDn WRn RDY INTn RQ CLKIN CTYP ATYP MS2 TxA TxS TxEn RxS RxA...

Страница 24: ...r Write cycle to indicate to the CPU that it can complete the cycle It becomes high when the CPU completes the cycle The Figure 4 shows interface to such CPU This example is meant for new designs beca...

Страница 25: ...the start of the Read or Write cycle to indicate that the CPU has to wait It becomes high when the CPU can complete the cycle The RDY output requires some amount of logic to convert it to DTACK signal...

Страница 26: ...ite cycle to indicate to the CPU that it can complete the cycle It becomes high when the CPU completes the cycle 3 2 5 Power PC The PowerPC has a bus interface which is similar to Intel type CPU It ha...

Страница 27: ...1 The TxA signal is always high during active transmission for all transmit modes It can be used to enable the transmit buffer in the MAU that drives voltage or to change the bias current in the MAU...

Страница 28: ...external MAU should generate active RxA signal only after detecting sufficient activity beyond the noise threshold and for sufficient time so that noise above threshold can also be filtered After the...

Страница 29: ...2 INTn This output becomes active when it needs to interrupt the CPU The active polarity is low This signal stays active as long as any one of the interrupt sources in the UFC100 L2 is active The rese...

Страница 30: ...e 0 0 3 VDD V VIH Input high voltage ICH type 0 7 VDD VDD V VH Input hysteresis 0 4 V IL Input leakage current 5 A VOL Output low voltage IOL 0 1 mA 0 2 V VOL Output low Voltage RES0 RES1 RES2 IOL 8 m...

Страница 31: ...8 and Figure 9 below It was measured while the device was continuously transmitting and receiving in full duplex using DMA with continuous Read and Write access to the device Figure 8 Typical operatin...

Страница 32: ...Inc 21 May 2018 4 3 Clock Input Timings The timings are shown in the Table 21 and the Figure 10 Table 21 Clock Timings Name Description Min Max TCLK Clock input period VDD 2 7 to 3 6 V 125 ns 1000 ns...

Страница 33: ...n it can issue successive access without delay If the CPU cannot use RDY DACKn signal and if the successive bus access cannot be delayed then the CPU has to check completion of the prior access by rea...

Страница 34: ...DACKn to valid Data delay 20 3 t8b Positive edge of CLKIN to valid Data delay 30 3 t9 RDn negation to tristate Data invalid Data delay 3 15 t10 RDn WRn negation to DACKn negation delay 0 15 t11 RDn WR...

Страница 35: ...ek Inc 21 May 2018 4 4 2 Freescale Type CPU Figure 13 Freescale Bus Read Cycle Timing Diagram Figure 14 Freescale Bus Write Cycle Timing Diagram ADRS CSn t2 t3 RWn DACKn t1 t15 DATA t10 t12 t13 RDY t5...

Страница 36: ...t10 DSn negation to DACKn RDY negation delay 0 15 t11 DSn assertion duration 10 t12 DSn inactive time 10 t13 CSn inactive time 10 t14 Valid Data to WRn negation setup time 5 t15 WRn negation to inval...

Страница 37: ...ut average period 30 s 34 s tRTR Receive signal input transition time 200 ns tRJTR Receive signal zero crossing jitter 2 s tLOCK Receive lock time 110 s 2 tRxAH Receive activity signal hold time 0 Not...

Страница 38: ...voltage is below minimum value Figure 19 Reset Signal Timings 4 6 2 Interrupt Timings Table 27 Interrupt Timings Num Description Min Max Notes tTXINTD Active INTn output to end of transmission delay...

Страница 39: ...ve FIFO becomes empty The last received byte is available for transfer at the start of end delimiter Therefore in DMA mode the FIFO is likely to become empty before the end delimiter is detected 3 If...

Страница 40: ...M MAX MIN NOM MAX A 1 60 0 063 A1 0 05 0 15 0 002 0 006 A2 1 35 1 40 1 45 0 053 0 055 0 057 b 0 22 0 30 0 38 0 009 0 012 0 015 c 0 09 0 20 0 004 0 008 D 12 00 BSC 0 472 BSC E 12 00 BSC 0 472 BSC e 0 8...

Страница 41: ...pts For hardware test use any threshold setting 5 Write to GAP time register 0x14 The value depends upon the Data Link layer configuration For test purpose set it to 0x10 8 bytes 6 Write to Watch time...

Страница 42: ...1 then there was an error 8 If there was an error then first read FIFO status register 0x0C and then Error status register 0x05 to find the reason for the error Clear the FIFO status register by writi...

Страница 43: ...en Error status register 0x05 to find the reason for the error Clear the FIFO status register by writing 1 to CRF and CTF in FIFO control register 0x0B 9 Compare the received data bytes with transmitt...

Отзывы: