[Solved] Building Ser2Sock on Raspberry Pi

General Discussion

[Solved] Building Ser2Sock on Raspberry Pi

Postby krkeegan » Fri Jan 03, 2014 9:40 pm

I am getting an error trying to compile ser2sock on the raspberrypi, I am getting the following error:

checking for SSL_library_init in -lssl... no
configure: error: in `/opt/ser2sock':
configure: error: ssl test failed (--without-ssl to disable)
See `config.log' for more details

I have openssl installed. Is there some other dependency that I need in order to compile this?
krkeegan
newt
newt
 
Posts: 9
Joined: Fri Jan 03, 2014 9:37 pm

Re: Building Ser2Sock on Raspberry Pi

Postby mathewss » Fri Jan 03, 2014 10:02 pm

Yep we need to have the dev packages as well to compile. Try this and lets see how it goes.
Code: Select all
sudo apt-get install libssl-dev


I will be adding this to the AD2Pi wiki document. If you find you need anything else or have feedback for that document let me know and I will update the document.

Thanks
Sean M
mathewss
Moderator
Moderator
 
Posts: 188
Joined: Fri Dec 06, 2013 11:14 am

Re: Building Ser2Sock on Raspberry Pi

Postby krkeegan » Sat Jan 04, 2014 11:52 am

I got the installation instructions for Ser2Sock from the github page, which is fine. Isn't libssl-dev required for all distributions to complile Ser2Sock? If so, I would just add it to the instructions on that page.

As for other hiccups, the rest of the installation on the RPi went well, I chose the manual method rather than redownload and start over with the the RPi image. Just a suggestion, but the changes were rather simple, a batch script could likely be created to do the "manual install."

I also had to look up how to use minicom to test out the RPi. The basic instructions in on the "Installation Guide" were a little vauge suggesting just to use the -o switch. I ended up using the instructions here:

http://www.shirwahersi.com/content/how- ... munication

which involved using the -s switch. I was never able to figure out how to exit minicom after getting it to work either. In fact, in the process I managed to set off the fire alarm to my wife's delight.

Other than that, the initial install seemed to go well.

I have started working on the MH interaction. The codebase that Howard and Wayne worked on is complicated to say the least. This step is going to take me the longest and may require rewriting the MH plugin.
krkeegan
newt
newt
 
Posts: 9
Joined: Fri Jan 03, 2014 9:37 pm

Re: Building Ser2Sock on Raspberry Pi

Postby mathewss » Sat Jan 04, 2014 1:59 pm

Thanks for the feedback. I will talk to the team on Monday about the docs for ser2sock and the dependencies needed if SSL is enabled.

Minicom is a little off topic but I can bring that back a little and its a good topic.

So Minicom has been one of the suggested tools to configure the AlarmDecoder but it has been a real problem as you found out and as my good friend berkinet here on the forums would say it has a VERY low WAF :o and its just overly complex for such a simple task. This is why we suggest putty but thats no help for embedded applications.

Minicom by default wants to "initialize" modems or send long strings of Hayes modem commands to the serial device. The AD2 is not a modem but like a modem will gladly gobble up all the data minicom sends to it. These modem init commands have been known to trigger alarms as you found out. The -o option was suggested to prevent this behavior but as you found its possible to re-trigger the behavior inside of some of minicoms configuration screens so in the end minicom needs to be removed from all docs and a suitable replacment found for testing and initial configuration of the AD2*.

Now to bring it back on topic of ser2sock. I am thinking about creating a branch of ser2sock that allows for a non daemon mode where it watches the keypad for input and then sends the input directly to the attached serial device and thus provides all that is needed to interact with the AD2* from a terminal and we can stop suggesting minicom. It would likely still require a control sequence to exit like minicom CRTL-a q gets you out but I would echo that to the user upon startup :) if one were to run ser2sock under Screen then it would be possible to ssh back into your AD2* appliance and reconnect to your screen ('screen -r') and start talking to your panel directly. Detaching from the screen with CRTL-a CRTL-d would leave ser2sock running as if it were a daemon.

Re
Sean M
mathewss
Moderator
Moderator
 
Posts: 188
Joined: Fri Dec 06, 2013 11:14 am

Re: Building Ser2Sock on Raspberry Pi

Postby berkinet » Sun Jan 05, 2014 3:13 pm

Yes, fire alarms not only have "low WAF" but they serve as great fodder for future derision about HA projects ;-)

BTW, since you are on RPi you might just want to install "telnet" and then use that to connect to ser2sock. Of course, if you enabled ssh in ser2sock you could just install/use a local ssh client.
berkinet
Moderator
Moderator
 
Posts: 12
Joined: Tue Nov 03, 2009 6:48 am

Re: Building Ser2Sock on Raspberry Pi

Postby krkeegan » Mon Jan 06, 2014 12:46 pm

Yes all great points. I really only used minicom for setting up the device, since that is what was suggested in the instructions, i hadn't thought of telnet but I should have. Although, I don't think users should be "punished" for strictly following the instruction manual, so if there is a better way, that should be described in the instruction manual. In hindsight, I might advise installing ser2sock first and configuring the device through ser2sock as this allows you to use practically anything that you are comfortable with.

I went back and test it, and the problem seems to be that minicom advises pressing ctrl-A Z to see the help menu. Best I can tell, pressing ctrl-Z three time is what set off my alarm.
krkeegan
newt
newt
 
Posts: 9
Joined: Fri Jan 03, 2014 9:37 pm


Return to General

Who is online

Users browsing this forum: No registered users and 24 guests

cron