# Controlling hardware with serial port [closed]

I initially posted this in SuperUser SE Site, but it was recommended that I bring it here instead. So, here we go :)

We have a 'dated' security system at the office. It is a model that was made (or at least rebranded) by a company named ATI Access. The board are stamped as: SA-2000-II V8.0.

As I mentioned before, the company that made (rebranded) the board is "ATI Access", located 30 minutes away from me in Milwaukee, WI. As of a few weeks ago, they are now defunct. That means that all my tech support, etc, has gone out the window. With that being said, I am trying to have a go at a small project, but I am now flying blind. Here are the details:

On the top left side of the board, there are 5 inputs that can be programmed to do various tasks such as trigger an alert, or open a door by pushing a button. Looking at the manual for the board, a simple 'dry contact' switch is all that is needed to trigger them. So, what I have done on one of my panels is connect wires to Input 2 and attached them to a doorbell attached to the side of a table in my IT Closet. I then programmed the input to open the door on my IT Closet when the button is pressed. It works great. Go me, right?

Well, that is not good enough for me. I want to be able to control it with my PC as well. Now yes, I could just keep the security system open at all times, and alt-tab to it, right click on the door, and choose Open, but that is a lot of steps. I figured I would just write my own app that sits in the system tray that I can double click on, which would somehow emulate me pushing the doorbell.

I am not looking to use the PC to control a motor to push the doorbell for me, although that would be kinda cool. I am thinking that perhaps the serial or parallel ports could act as a dry-contact switch (however I am pretty sure that's not a feasible idea), or perhaps using some sort of dry contact relay that can be controlled via the serial port. So, the sequence of events would then be:

1. Click on the icon of my app in the system tray
2. App sends a signal out via the COM or LPT port (this part I can handle, I love programming)
3. That signal is picked up by [insert stuff I don't know here] that trips the relay momentarily to a CLOSED position, completing the circuit to the security panel input header.
4. Security Panel works its magic and opens my door.

As stated, I have this done the manual way utilizing a doorbell button, but I am looking to fancy it up and use my PC instead. Has anyone done here ever done something similar to this and is willing to point me into the right direction for [insert stuff I don't know here] ?

For bonus points: Does anyone have experience with this type of security panel? I'd be interested in knowing if there are any alternatives to the software that I am currently using for it (StarAccess Pro is the software that is used).

## closed as unclear what you're asking by Voltage Spike, Dmitry Grigoryev, pipe, DoxyLover, AndrewMay 15 '17 at 14:23

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

• I've used small brds, connected to a PC/USB, to control things. You need a development or "launchpad" board (cheap), where a nice, free decent development toolset exists. You plug in the development board to the USB port and it identifies itself to the PC, usually providing both a debugger port and also enumerating a virtual COM port (HID) to the PC. Ignore the debugger port, use the virtual COM port for your PC software. Write software on the target board to accept serial port text as commands and operate a port pin. Add tiny circuit to port pin to connect to your board. That's it. – jonk Apr 22 '17 at 1:08
• if you have an LPT port, you have 8 controllable switches. hook up a mosfet or solid-state-relay to one of those data lines and you can easily turn the switch on and off without much hardware investment. – dandavis Apr 22 '17 at 16:28

I recommend an Arduino board and any one of the many existing "relay shields" for it. Arduino connected via USB to computer is easily programmed to present a virtual COM port where you can send commands. Then you can close relay contacts by just switching an Arduino output pin from LOW to HIGH state.

If you are looking for a easy to get up and running solution than an arduino would be a great choice. A arduino nano or uno would work fine and connect over USB to your pc, emulating a serial port. You would attach a relay with driving transistor or if your looking for an easy option, a relay shield. This is how the code would run:

initialisation stuff

Wait for serial input and then...

Match serial input to a command set- eg, activateswitch1 and then...

Do the corresponding actions eg, turn on pin 3 to activate relay

Then wait again for more commands!

This could cost off eBay from those Chinese sellers around $10 • arduino clone-$5
• relay module- $3 • project box-$2
• some indicator leds as you want them- \$1

You could use a hc-06 serial over Bluetooth module. I have personally worked with these and are really easy to use. I have even made them work with android apps so I can send data to the arduino over Bluetooth.

Well that's to different routes and again, other people have talked about commercial options so the choice is yours.

You may be going a little OTT with your thinking. Down the right hand side of your panel there seems to be an unused RS-232 port, so one option may be to use that to send a command to the panel to tell it to open the door. There's also the RS-422 port you've labelled as going to the PC, presumably this is what the control software uses, but it may also provide a method of doing what you want without any extra hardware.

If you do need a separate bit of hardware there are lots of options. I've used a bunch of Velleman K-8056 relay boards to control a whole load of motorised blinds in an office, which had an RS-232 port and accepted basic commands generated by a wall-mounted touch screen PC. The one I used had 8 relays, which is a bit excessive for your application, but there are probably smaller alternatives or you could put one together yourself from a whole load of different options such as Arduino, Raspberry Pi etc. and connect to it through serial, Ethernet, Wi-Fi or whatever you fancy trying - it depends how "dirty" you want to get your hands putting it together.

You could actually bypass the panel and provide a parallel connection for the door striker directly from your relay, though it won't make a lot of practical difference (although it would lose the recording of you opening the door from your PC that the software presumably provides at the moment).

As for alternative panels, there are loads on the market as a quick search online or browse through eBay will show.

• The RS422 is used between the PC and 2 other boards. The boards only respond after authentication, which I don't know how to do. Besides that, the SW on the PC already is using that port. As far as the RS232 port goes, that might work, IF I could find any documentation as to how to talk to the panel. I know the settings for the COM port, but I know nothing beyond that. I have been unable to find any documentation anywhere on the net about it. I am assuming that the communications protocol is proprietary for these types of boards. I could be wrong – Jason H. Apr 21 '17 at 12:19
• Yes, it will be proprietary - there's no real standard that applies to these sort of panels, certainly not when this one was made. It may just provide an alternative to the RS422 port, but they sometimes provide a connection for something else, or a logging output for a printer or they're left "reserved for future use" and do nothing at all. Is there anyone that you might still be able to get in touch with at the supplier? – Finbarr Apr 21 '17 at 12:25