Skip to content

Commit

Permalink
resolved import problems
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucas-D20 committed Mar 1, 2024
1 parent 7e1e73b commit 716568f
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 3 deletions.
2 changes: 1 addition & 1 deletion panduza_platform/connectors/serial_low_usb.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@


from .serial_base import ConnectorSerialBase
from panduza_platform.log.driver import driver_logger
from log.driver import driver_logger

from .udev_tty import SerialPortFromUsbSetting

Expand Down
2 changes: 1 addition & 1 deletion panduza_platform/connectors/serial_tty.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import aioserial

from .serial_base import ConnectorSerialBase
from panduza_platform.log.driver import driver_logger
from log.driver import driver_logger

from .udev_tty import SerialPortFromUsbSetting

Expand Down
18 changes: 18 additions & 0 deletions panduza_platform/core/udp_server.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# UPD server listening for a client broadcast and responding by giving its IP and name

import asyncio
import socket

class Server:
def connection_made(self, transport):
self.transport = transport

def datagram_received(self, data, addr):
message = data.decode()
print('received : %r from %s' % (message, addr))

hostname = socket.gethostname()
IP_addr = socket.gethostbyname(hostname)
reply = "Yes! I am server %s and my address is %s" % (hostname, IP_addr)
self.transport.sendto(reply.encode(), addr)
print('send : %r to %s' % (reply, addr))
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import asyncio
from meta_drivers.powermeter import MetaDriverPowermeter

from panduza_platform.connectors.thorlabs_pm100.connector import ConnectorThorlabsPM100
from connectors.thorlabs_pm100.connector import ConnectorThorlabsPM100


class InterfaceThorlabsPM100APowermeter(MetaDriverPowermeter):
Expand Down

0 comments on commit 716568f

Please sign in to comment.