09.29.15

Analysis of Mimomax Captures

Mimomax radios produce the best debugging data available to the customer that I have seen on any radio so far, and you can gain some excellent insights as to what is happening at your sites RF wise by looking at them.  Mimomax  have some tools that will produce some graphs and they are all too happy for you to send them captures and they will provide you with some graphs and commentary as to what they think is going on.  However they are unlikely to give you the tools to generate these graphs, as they like to know their customers issues and to some extent don't want people to potentially come to the wrong conclusion by looking at data they might not fully understand.  I'm ok with that, but I still wanted to analyse the data without having to wait a day or two!  So I have whipped up a few Octave scripts to do a similar job.
Read the rest of this entry »

| Posted in Networking | No Comments »
08.30.15

CoApp for Visual Studio 2015

Some time ago when CoApp was making its first releases, I helped out as a packager for many open source packages.  Unfortunately CoApp seems to be all but dead, although it seems a few people are still using it.  The latest official CoApp release has a couple of issues, one being a lack of support for Visual Studio 2015.  Over the last couple of days I have made an effort to get my head around the somewhat messy codebase that makes up the CoApp project and get it working for the latest build tools.

Short Version

Grab my (unofficial) updated CoApp release that supports VS2015 here.

Long Version

My fork of CoApp.Powershell is based on the .net 4.5 and the Visual Studio 2015 tool chain, so you will need these installed to build it.  You will also need the Sysinternals Suite added to your path, and WiX 3.9 installed. I built it on Windows 10 with the Windows 10 SDK installed, I'm not sure how things will go on other operating systems (if anyone tries let me know!).  You also need to set the powershell execution policy to unrestricted.

I have setup two example repositories that build and create nuget packages, zlib and libpng (forked from the original CoApp repositories).  My NuGet package feed that has these packages is https://www.myget.org/F/raggles/api/v2, note that I haven't actually tried to use them for anything meaningful so if something doesn't work, again please leave a comment.

A couple of notes:

  1. When compiling and debugging your own builds, be sure that the default value of HKLM\Software\Outercurve\CoApp.Powershell\etc\ is set appropriately.
  2. If you want to debug the powershell scripts, instead of attaching the debugger to a powershell process, start powershell from visual studio by setting the project debug action to run C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe  and use noexit -command "& { import-module -name 'E:\coapp.powershell\output\v45\AnyCPU\Release\bin\coapp.powershell.dll'}" as the argument (set for your build location obviously).

| Posted in Software | 2 Comments »
05.7.15

SEL3505-3 USB-Ethernet Driver on Windows 8.1 x64

I recently acquired a SEL 3505-3 RTU for testing, and to configure it one must connect to it via the USB port. The USB port in question is actually a virtual ethernet interface, and according to the documentation in the manual for the 3505 the driver should have been installed automatically. However, for me it simply didn't work. I had a wee look in device manager and tried to install the driver manually to be greeted with this:

sel350533505-driver1 Read the rest of this entry »

| Posted in Software | No Comments »
04.28.15

com0com Fork

I've been using com0com a bit lately and it's proved to be very useful. However the source doesn't appear to have been touched in quite a long time, and it still uses make and other gross stuff from way back. I have forked com0com (including com2tcp and hu4com) and made nice shiny new Visual Studio 2013 projects for everything (including the kernel mode drivers) and put everything on GitHub for all to enjoy.  I have even gone to the trouble of purchasing an Authenticode Certificate and have published signed binaries.  Hopefully I'll get round to creating a nice WiX installer but I remember the last time I did battle with WiX I came out a shell of a human.

| Posted in Software | No Comments »
04.23.15

Improved guide to Firewalls, IPSec, OSPF and L2TP on the RuggedCom RX1500

Its been a while since I last played with the RX1500, and since then I've learned a few things. This post is an improved and updated version of the previous post on the topic.

The setup for this example is most easily demonstrated by the diagram below:rx1500-l2tp1
Read the rest of this entry »

| Posted in Networking | 4 Comments »
04.17.15

Virtual Serial Ports, com0com, RFC2217, and Radio

Tunneling com ports over tcp, and in particular over low bandwidth radio links can be a tricky business. Even more so if you are on windows and want to use free or preferably open source software. Recent work I've been involved in has required that many devices with different and proprietary protocols (all serial in nature) be tunneled over a udp radio connection from a Windows server to the client device.  The image below demonstrates the conecpt.

com0com1
Read the rest of this entry »

10.29.14

Autolisp part II - convert drawing to grayscale skeleton

For my second Autolisp job, I was tasked to convert a drawing to a grayscale skeleton so that it could be used as a background for additional drawings.  This is typical of floor plans that are developed by one company, then another company overlays electrical, air conditioning or other building services over top of the floor plan.

acadpartii
Read the rest of this entry »

| Posted in Software | 1 Comment »
07.12.14

A foray into AutoLISP

I was recently asked by a friend to write a couple of AutoLISP routines that would offset a polyline in both directions, and change a few styles along the way. The problem is easiest defined visually:

autocad-lisp

This was to be my second experience writing lisp (after my experience with GIMP scripts), so I knew the language concepts and syntax already.  Initially I tried to get away with command macros; unfortunately these have no ability to store objects (as far as I could tell) and if you can't do what you want by running a sequence of AutoCAD commands it seems you're pretty much out of luck.

The entire function is as follows:

;;double offset with offset line style change
(defun C:doffset(/ pickEnts pickEnt offset i n)
  (vl-load-com)
  (if (setq pickEnts (ssget '((0 . "LWPOLYLINE"))))       ;select polylines
   (progn                                             
    (setq offset(getreal "\n Offset: "))                  ;store offset
    (setq i 0 n (sslength pickEnts))
    (while (< i n)
     (setq  pickEnt (ssname pickEnts i))                  ;get the next polyline from the selection
     (setq i (1+ i))
     (setq pickObj (vlax-EName->vla-Object pickEnt))   ;convert entity to object
     (vla-Offset pickObj offset)                          ;offset in one direction
     (command "_change" "l" "" "p" "LT" "ZIGZAG" "")
     (vla-Offset pickObj (- offset))                      ;offset in the other direction
     (command "_change" "l" "" "p" "LT" "ZIGZAG" "")
     (command "_change" pickEnt "" "p" "LT" "ACAD_ISO07w100" "")
     (command "_pedit" pickEnt "w" (* offset 2) "")       ;change the pline width (twice the original offset)
    )
   )                                                      ;progn
   (princ "No object selected!\n")                      
  )                                                       ;endif
  (princ)                                                 ;clean exit (supresses echo)
)

All in all this lisp business seems to be a quick and easy way to automate some of the more tedious AutoCAD jobs.

| Posted in Software | No Comments »
05.23.14

Bypassing MiCOM S1 Studio password

MiCOM S1 Studio is a program for programming power system protection relays. This post outlines how the password protection feature can be bypassed, in the case that it mysteriously starts asking for a password that it never used to like it did for me...

 

s1s_1

I know that S1 Studio is largely written in .NET, so lets try reflection to see what gives:
Read the rest of this entry »

| Posted in Software | 8 Comments »
03.18.14

Autonumbering Title Blocks in AutoCAD

Several people seem to have had this problem (going by the number of posts on the internet about it), but I didn't really find a satisfying solution.  After spending half a day on the problem, I think I have come up with something useable.

First, lets outline the problem:  Normally, along the top of a title block we have a column numbers (for referencing purposes).  Say there are 20 columns per drawing.  In a multisheet drawing, we want the first sheet to go from 1 to 20, the second from 21 to 41 and so on.  You can do this easily by editing your block each time and changing the numbers, but this is tedious...

Solution:
First we need to create a table for our column numbers.  My title block is 400 units wide, so I have a table 400 wide, with one row and 20 columns of 20 units each.  In the second column, enter the formula "=A1 + 1".  Drag this across all the columns so each one increments from the previous cell (so now you should have a blank first cell, then 1 to 19 in the others).autocad-autonum3
Read the rest of this entry »

| Posted in Software | No Comments »