ictdesigntools.cabling.channels¶
Cable channels: equipment port to equipment port through cable assemblies and the parts that join them (adapters, cassettes, splitters, splices), checked, budgeted and drawn.
A Channel is its items in order. Equipment is a port at an end (a transceiver, a
switch port). An Assembly (cabling.assemblies) is a patch cord, trunk or breakout.
Bulk is a length of cable with bare fiber at either end, or a factory plug (a pigtail),
for splicing. Part places a join from parts.joins (count of them side by side), in
a patch panel when panel names one (a TIA-606 identifier from identifiers).
problems() finds plugs that do not fit the next part, plugs meeting plugs or sockets
meeting sockets, connector counts that differ, angled (APC) plugs meeting flat ones in an
adapter, and splices not between bare fiber. loss() budgets the channel with the
ANSI/TIA-568.3 maxima: fiber attenuation by length, 0.75 dB a mated pair inside the channel,
0.3 dB a splice, and each splitter's own loss.
channel_drawing() draws it from the side: parts and plugs at 1:1, cable lengths to
scale (mm of drawing per metre), and any run longer than coil_over_m drawn that long
with the rest wound into a coil marked with the true length. Each part can carry its own
dimension line (dims), and the channel's total is dimensioned under them.
>>> from .assemblies import assembly
>>> ch = Channel((
... Equipment("Switch", "lc", ports=2),
... assembly("lc-lc-duplex-om4-2m"),
... Part("lc-adapter", panel="AD02-35"),
... assembly("lc-lc-duplex-om4-2m"),
... Equipment("Server", "lc", ports=2),
... ))
>>> ch.problems(), ch.length_m
([], 4.022)
>>> [(r.what, round(r.db, 3)) for r in ch.loss(850)]
[('Fiber, 4 m', 0.014), ('Mated pairs, 2 × 0.75 dB', 1.5)]
Equipment
dataclass
¶
A port at a channel's end: ports of connector (a connectors.toml slug).
Bulk
dataclass
¶
Bulk(
name: str,
type: str,
length_m: float,
a: End | None = None,
b: End | None = None,
outside_plant: bool = False,
)
A length of cable of a NetBox cable type with bare fiber at an end for splicing, or
a factory plug there (a, b) for a pigtail.
Part
dataclass
¶
A join from parts.joins by slug, count side by side (0: as many as the plugs
that enter it), with a label and the panel it is mounted in. flip turns it
round (a cassette's LC side first); by default it is turned to suit the plugs on its left.
Channel
dataclass
¶
length_m
property
¶
length_m: float
Cable lengths plus the lengths of the parts the light passes through (adapters, cassettes, splitters; a splice sleeve sits over the fiber and adds none).
count ¶
How many of a part sit side by side (its own count, or the plugs entering it).
Source code in src/ictdesigntools/cabling/channels.py
flipped ¶
Whether part i is turned round, its B side facing left.
Source code in src/ictdesigntools/cabling/channels.py
polarity ¶
polarity() -> Channel | None
The channel as cabling.polarity parts, to trace lanes and check transmit meets
receive, pins and polish end to end: array cables become trunks, two-cord duplex
assemblies A-to-B (type B) or A-to-A cords, cassettes fiber transitions behind their
rear adapters, and array adapters adapters. None when the channel carries no array
(MPO or MMC) cable, or has parts this cannot follow (a breakout, a splitter, splices).
Source code in src/ictdesigntools/cabling/channels.py
loss ¶
The channel's loss, row by row: fiber by type and length, the mated pairs inside
the channel (not the equipment's own ports), splices, and splitters. Mated pairs take
the ANSI/TIA-568.3 maximum, or with grade an IEC 61753-1 attenuation grade's
97 % maximum (optical.components: B, C or D; Bm or Cm for multimode).
Source code in src/ictdesigntools/cabling/channels.py
channel_drawing ¶
channel_drawing(
ch: Channel,
scale: float = 20.0,
coil_over_m: float = 5.0,
dims: str | set[int] = "cables",
wavelength_nm: int | None = None,
title: str = "",
) -> Drawing
The channel from the side, left to right.
scale is millimetres of drawing per metre of cable (20: 1:50). A run longer than
coil_over_m is drawn that long and the rest wound into a coil, marked with the true
length and "not to scale". Plugs and parts are drawn at 1:1. dims says which items get
a dimension line of their own: "cables" (assemblies and bulk cable), "all",
"none", or a set of item indexes; the channel's total length is always dimensioned.
wavelength_nm adds the loss budget under the drawing.
Source code in src/ictdesigntools/cabling/channels.py
378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 | |