Skip to content

Commit

Permalink
Merge pull request #1203 from slaclab/Qsfp-TxDisable
Browse files Browse the repository at this point in the history
_Qsfp.py Update
  • Loading branch information
ruck314 authored Oct 2, 2024
2 parents 03e838e + 8f30131 commit 9250912
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions python/surf/devices/transceivers/_Qsfp.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,37 @@ def __init__(self,**kwargs):
dependencies = [self.TxPwrRaw[2*i+0],self.TxPwrRaw[2*i+1]],
))

for i in range(4):
self.add(pr.RemoteVariable(
name = f'TxDisable[{i}]',
description = 'Tx_Disable bit that allows software disable of transmitters, Writing 1 disables the laser of the channel',
offset = (86 << 2),
bitSize = 1,
bitOffset = i,
mode = 'RW',
base = pr.Bool,
))

self.add(pr.RemoteVariable(
name = 'PowerOverride',
description = '0: allows setting power mode with hardware, 1: allows setting power mode with software',
offset = (93 << 2),
bitSize = 1,
bitOffset = 0,
mode = 'RW',
base = pr.Bool,
))

self.add(pr.RemoteVariable(
name = 'PowerMode',
description = 'Power set to low power mode: 1 sets to LP mode if PowerOverride is 1',
offset = (93 << 2),
bitSize = 1,
bitOffset = 1,
mode = 'RW',
base = pr.Bool,
))

################
# Upper Page 00h
################
Expand Down

0 comments on commit 9250912

Please sign in to comment.