File: fulltests.py

package info (click to toggle)
python-anthemav 1.4.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 200 kB
  • sloc: python: 1,408; makefile: 12
file content (23 lines) | stat: -rwxr-xr-x 531 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env python3

import asyncio
import logging


async def test():
    log = logging.getLogger(__name__)

    def log_callback(message):
        log.info("Callback invoked: %s" % message)

    host = "127.0.0.1"
    port = 14999

    log.info("Connecting to Anthem AVR at %s:%i" % (host, port))

    # conn = await anthemav.Connection.create(host=host,port=port,loop=loop,update_callback=log_callback,auto_reconnect=False)


if __name__ == "__main__":
    loop = asyncio.get_event_loop()
    loop.run_until_complete(test())