20 lines
569 B
Python
Raw Normal View History

2025-02-13 12:22:10 +01:00
import pyqtgraph as pg
from PyQt6.QtWidgets import QWidget
class Plot(pg.PlotWidget):
def __init__(self):
super().__init__()
self.setBackground("w")
self.setTitle("Test")
self.setLabel("bottom", "time [s]")
self.setLabel("left", "Voltage [V]")
self.setLabel("right", "LED [%]")
self.showGrid(x=True, y=True)
self.time = list(range(10))
self.voltage = list(range(10))
self.led = list(range(-10))
self.line = self.plot(
self.time,
self.voltage
)