# This is the DPP register Config 0x8000 variable Config 0 variable Config.TrigOpt 0 variable Config.InvertInput 0 variable Config.DualTrace 0 variable Config.VProbe1 0 variable Config.VProbe2 0 variable Config.EnableFmtWord 1 variable Config.OscMode 0 variable Config.EnergyMode 1 variable Config.TimeTagMode 1 variable Config.ExMode 0 variable Config.DigVProbe 0 proc GetConfig {} { variable Config variable Config.DualTrace variable Config.InvertInput variable Config.TrigOpt variable Config.EnableFmtWord variable Config.VProbe1 variable Config.VProbe2 variable Config.OscMode variable Config.EnergyMode variable Config.TimeTagMode variable Config.ExMode variable Config.DigVProbe set Config [ReadRegister Config] set Config.TrigOpt [expr ($Config >> 2) & 1] set Config.InvertInput [expr ($Config >> 9) & 1] set Config.DualTrace [expr ($Config >> 11) & 1] set Config.VProbe1 [expr ($Config >> 12) & 3] set Config.VProbe2 [expr ($Config >> 14) & 3] set Config.OscMode [expr ($Config >> 16) & 1] set Config.EnergyMode [expr ($Config >> 19) & 1] set Config.TimeTagMode [expr ($Config >> 18) & 1] set Config.ExMode [expr ($Config >> 17) & 1] set Config.DigVProbe [expr ($Config >> 20) & 15] set Config.EnableFmtWord [expr ($Config >> 24) & 1] } proc SetConfig {} { variable Config variable Config.DualTrace variable Config.InvertInput variable Config.TrigOpt variable Config.EnableFmtWord variable Config.VProbe1 variable Config.VProbe2 variable Config.OscMode variable Config.EnergyMode variable Config.TimeTagMode variable Config.ExMode variable Config.DigVProbe set Config.EnableFmtWord 1 set Config.InvertInput 0 set Config.EnergyMode 1 set Config.TimeTagMode 1 set Config [expr \ ([set Config.TrigOpt] << 2) + \ (1 << 4) + \ (1 << 8) + \ ([set Config.InvertInput] << 9) + \ ([set Config.DualTrace] << 11) + \ ([set Config.VProbe1] << 12) + \ ([set Config.VProbe2] << 14) + \ ([set Config.OscMode] << 16) + \ ([set Config.EnergyMode] << 19) + \ ([set Config.TimeTagMode] << 18) + \ ([set Config.ExMode] << 17) + \ ([set Config.DigVProbe] << 20) + \ ([set Config.EnableFmtWord] << 24)] WriteRegister Config $Config } proc DrawConfig {} { variable Name set html "" append html "
" append html "
| Trigger Propagation \[2\] | " append html "" append html " | Dual Trace \[11\] | " append html "" append html " | Analogue Probe 1 \[12:13\] | " append html "Analogue Probe 2 \[14:15\] | " append html "
| " append html "" append html " | " # Bit 9: not in use append html "" append html " | " # Bit 11: Dual Trace append html "" append html "" append html " | " # Bit xx: not in use append html "" append html " | " # Bit 12/13: Analogue Probe 1 append html "" append html "" append html " | " # Bit 14/15: Analogue Probe 2 append html "" append html "" append html " | " append html "
| Oscilloscope Mode \[16\] | " append html "Extras Mode \[17\] | " append html "Time Tag Mode \[18\] | " append html "Energy Mode \[19\] | " append html "Digitial Virtual Probe \[20:23\] | " append html "Event Format Info \[24\] | " append html "" append html "" append html " | " # Bit 17: Extras Mode append html "" append html "" append html " | " # Bit 18: TimeTag Mode append html "" append html "" append html " | " # Bit 19: Energy Mode append html "" append html "" append html " | " # Bit 22/20 Digitial Virtual Probe append html "" append html "" append html " | " # Bit 24 Enable Event Data Format Word append html "" append html "" append html " | " append html "" append html "