access AD2USB via Python on Windows

General Discussion

access AD2USB via Python on Windows

Postby kapios » Sun Jan 13, 2019 10:31 am

I have a working AD2USB connected to my Vista 20P, successfully monitored using the Windows keypad app.
I would like to use Python so that I can also trigger different actions based on zone faults BUT I am not able to access the AD2USB. When I run the "usb_detection.py" script from GITHUB I get an exception: "No AD2USB devices present".
I have restarted the program, the PC etc but I can not get anywhere.

Please, any help would be appreciated. Thank you!
kapios
newt
newt
 
Posts: 3
Joined: Sat May 19, 2018 11:53 am

Re: access AD2USB via Python on Windows

Postby mathewss » Sun Jan 13, 2019 11:56 am

Are you by chance using the keypad app at the same time? The device can only be opened by one app at a time. If you want more code to be able to connect at the same time then run the ser2sock code inside of the GUI app or on a Raspberry pi.

That being said I have not tested this on Windows but I put it on my list today to tinker with.

Best
SM
mathewss
Moderator
Moderator
 
Posts: 11
Joined: Fri Dec 06, 2013 11:14 am

Re: access AD2USB via Python on Windows

Postby kapios » Sun Jan 13, 2019 12:56 pm

I do have the keypad app closed when I try to run the python script. Also, I would assume that the error code would be different if there was a port conflict. For some reason it does not see the device at all.

Unfortunately I don't have a Raspberry pi to try accessing the AD2USB - it does look like the webapp may be able to do the things that I need but I figured I can get Python on Windows to accomplish the same.

Please let me know if there is anything that I may be overlooking after you have had a chance to try it on Windows.

Thanks.
kapios
newt
newt
 
Posts: 3
Joined: Sat May 19, 2018 11:53 am


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron