Elk M1XEP communication documentation

shenandoah75

Active Member
Just curious... Since CQC and ML both have drivers that interface over the non-secure port, i'm assuming there's a protocol to connect and execture send/receive commands over tcpip just like serial? Assumming this would be on some port other than 80?

How do i get access to this info ? :p

thx
-brad
 
you just use sockets, connnecting to port 2101 on your m1's ip address and then you can issue read and write socket commands.
everything is identical to serial port at that point.
 
Has anyone had any success using the secure port (2606 I believe) to connect and transfer data. I tried a while back putting the data through stunnel (www.stunnel.org) but could not get the secure port to work.

Thanks
 
Has anyone had any success using the secure port (2606 I believe) to connect and transfer data. I tried a while back putting the data through stunnel (www.stunnel.org) but could not get the secure port to work.

Thanks

Gwww, what's not working? I've used stunnel before successfully with the XEP. Here's a snip from the config.

[ssltelnet1]
accept=2601
connect=192.168.0.251:2601

The result of this is to accept connections on the machine that's running stunnel on port 2601 and relay those to the XEP (shown here as 192.168.0.251) on port 2601. You'd connected to the stunnel machine and see an unencrypted TCP connection to send traffic and stunnel will setup the SSL tunnel to the XEP on its port 2601.

You could now open up telnet to your stunnel machine on 2601 and be connected to the XEP.

Be careful if you use telnet because it appears to send the return after you put in your username as two characters, one of which becomes the first character entered as the password. So you'll need to "backspace" the first * you see echoed from the XEP on the password prompt before typing your password. If you see "Elk-M1XEP: Login successful." you're in.

Now just sit back and wait and you'll see the XK commands appear every 30 seconds. You can now enter and receive strings from the Elk RS232 protocol.
 
I think you are the first to get port 2601 to pass data outside of ELK engineering.

Nice going!!
 
I think you are the first to get port 2601 to pass data outside of ELK engineering.

Nice going!!

Thanks. I actually did it over a year ago when I demonstrated to Elk engineering that the secure port wasn't "secure" because it would accept an SSL connection from anyone. In other words, it was secure in that it encrypted traffic to prevent eavesdropping, but not secure in that it didn't authenticate the user. That led to the implementation of the username/password on the secure port.

Here's a screen shot of a connection and the heartbeat responses. Do remember that you'll need to use the backspace trick mentioned above. I've erased the username/password entries.

Another tip is to use the most recent stunnel..

telnet.JPG
 
I am having trouble with the username/password part.

If I configure the M1XEP with no usernames and passwords, I can do the SSL connection and enter commands as described in the RS232 protocol. All appears to work as documented.

But if I have a username and password defined, the Elk sends the prompt:

Username:

If I enter my username and hit Enter, it just echoes the username. There is never a prompt for the password. I have tried entering the password and it echoes that back as well. Doing backspace before entering the password doesnt help. Is there some trick to the password part?

thanks

BTW, I am using openssl on a Mac, OSX 10.6.
 
Answering my own question: You need to use the -crlf option in openssl

I now have this working through openssl as well as within a java app I am developing.
 
I am trying to use Java Socket programming to connect to M1EXP. I got the similar problem as nirias.

If I use port 2101, I have no problem to talk to M1EXP according to the RS232 protocol.

However, if I try to use the secure port 2601, I don't know how to handle the password and username. I tried Java SSLSocket, but failed.

It seems that SSL requires some kind of certificate. How can I set it up? Or can I just use username and password?

Can anyone give me some hints?
 
Back
Top