Saturday, March 10, 2018

Playstation BUZZ usb controllers on PC

This is how I got the BUZZ USB controllers to work on a PC.  Tested on Windows 10


Essentially I am using a USB to keyboard program to translate the buttons being pressed on the individual controllers to simulate pressing keys on the computer keyboard.

I use them for the "You Don't Know Jack" game, but, for example, you could plug in a Rockband or Guitar Hero drum set into your computer, and using a key-to-drum program simulate the drums being played.

What I did:

The program I'm using to do the translation is called
"JoyToKey"
https://joytokey.net/en/download

I've used several different ones, so there are a few to pick from.  This one worked pretty good first try so I stuck with it.

This program will scan the USB port of your controller, and then allow you to individually assign the buttons to key inputs.

Then I plugged in my controllers.  Windows 10 recognized them right away as BUZZ controllers.

I ran the program, and by pressing each button on the controllers, the corresponding button would show up in the JoyToKey program

I mapped 3 of the 4 controllers (max 3 supported in Jack Box game), each of the "buzz in buttons" to their corresponding buzz in key (Q, B and P) and then each of the color buttons 1-4 in descending.


I launched JackBox games and worked perfectly.



I output the computer HDMI signal to my TV and everyone can play from comfortable chairs without having to huddle around the computer.

Wednesday, February 21, 2018

Cisco 4507 stuff

Find a mac address on a switch
show mac-address-table | include XXXX

XXXX= last 4 digits of the mac address of the device you re looking for.  I find that easiest, but you can search bigger range.  Cisco doesn’t use xx:xx:xx format
Cisco uses xxxx.xxxx.xxxx


Find summary of port
show int status | include xxxx


You can get additional detail about the port using
show running-config interface gigabitEthernet X/XX


Default the port configuration (from config)
default interface gigabitEthernet X/XX


NON 802.1X port config example

interface GigabitEthernet X/XX
description XXXXXXX
switchport access vlan XX
switchport mode access
switchport voice vlan 90
qos trust cos
auto qos voip trust
tx-queue 3
   bandwidth percent 33
   priority high
   shape percent 33
spanning-tree portfast
service-policy output autoqos-voip-policy
shut
no shut
end

802.1X port config example

interface GigabitEthernet X/XX
description 8021X_Enabled
switchport access vlan 66
switchport mode access
switchport voice vlan 90
qos trust cos
authentication event fail action authorize vlan 202
authentication event no-response action authorize vlan 202
authentication host-mode multi-host
authentication port-control auto
authentication periodic
auto qos voip trust
dot1x pae authenticator
dot1x timeout quiet-period 5
dot1x timeout server-timeout 10
dot1x max-reauth-req 1
storm-control broadcast level 20.00
storm-control action shutdown
tx-queue 3
   bandwidth percent 33
   priority high
   shape percent 33
spanning-tree portfast
spanning-tree bpduguard enable
service-policy output autoqos-voip-policy
shut
no shut
end

Configure a trunk
interface gigabitethernet x/xx
switchport trunk encapsulation dot1q
switchport mode trunk
description XXXXX
 switchport trunk native vlan 100
 switchport trunk allowed vlan 10,50,60,66,67,100,110,130
 qos trust cos
 auto qos voip trust
 tx-queue 3
   bandwidth percent 33
   priority high
   shape percent 33
 service-policy output autoqos-voip-policy

RESTART SWITCH REMOTELY
reload

CONFIGURE IP OF SWITCH

configure terminal
interface vlan XX
ip address 192.168.99.11 255.255.255.0
no shutdown
exit
ip default-gateway 192.168.99.1
end
copy running-config startup-config

CHANGE NAME OF CISCO SWITCH
hostname Corp-Training

configureVLAN

Conf t
Vlan #
State active
End
Write
Or copy run start

Add unifi node to controller

1. Start a ping in a cmd prompt window. This will help you know when controller is up or down.

2. Login into UNFI device using putty via SSH.  (default is ubnt/ubnt) but if device is already acquired, System will give it custom password:

a. log into controller gui.
b goto 'settings button' on the lower left side
c. goto DEVICE AUTHENTICATION
d. click on the the picture of the 'eye' to show the controller password.
e. note the user name that is assigned then you can ssh to the controller using the IP of the controller and the user/password shown on that page

3. From command prompt send the command:  This will reset the configuration of the node back to factory default.

syswrapper.sh restore-default

Controller will now reboot.

4. Once controller is available again, SSH back in.  the user/password will now be " ubnt/ubnt"

5. Send the following command: Alter the "ip-of-controller" to the ip of your systems controller

set-inform http://IPofCONTROLLER:8080/inform
(example: set-inform http://10.1.100.100:8080/inform)

6. The device will appear ready for "pending adoption" in the controller. Click Adopt.

7. Wait for the 'Adopting' status to appear on the UniFi controller, then issue the set-inform command again.

8. The device should now change to a 'Provisioning' status and then connect shortly thereafter.

If the adoption failed, check this blog for "Unifi Adoption Failed" procedure that might work for you.

Sunday, February 11, 2018

DIY XLR ethernet cable audio snake on standard (unshielded) Cat5 Cat5e Cat6 cable

This document focuses on using standard, unshielded (UTP) Ethernet cable (Cat5/6) to obtain 3 balanced audio channels 


Commonly advertised solutions demonstrate 4 channels of analog audio but shielded Ethernet cable (STP) is required to properly work, specifically around grounding.

The main differences between using UTP and STP cable are the number of channels available.
  1. UTP has Three channels vs Four (STP).
    UN-Shielded Ethernet lacks an additional wire to use as a ground allowing for a 4th channel.

  2. COST and AVAILABILITY
    UN-shielded Ethernet is inexpensive and found everywhere 
But we need the shield for audio quality in an XLR cable?

No, not really. Balanced audio primary rejection to interference results from the positive (in-phase) and negative (out-of-phase) relationship of the analog signal as it travels together over a cable pair.  The ground wire helps reduce unwanted noise and interference, and the shield (usually metal foil) found in some balanced mic cable provide rejection enhancement.


Solution A - 
TWO (2) audio channels using unshielded ethernet cable.

Easily connect the XLR pins on the Ethernet wire and get 2 channels of audio.  Balanced audio uses 3 wires for each audio channel.  With Ethernet having 8 wires its easy to get 2 channels as shown in this diagram.

XLR over Cat5 using standard wiring methodology (2 unused wires)

OR


Solution B -
THREE (3) channels using the same unshielded ethernet cable.

This design gives has the positive and negative wires connected to orange, green or blue.  But the ground wires all going to the same brown wire on either side of the Ethernet cable.  This is how you get 3 channels of audio when you only have 8 wires, when you normally would need 9.  You share the ground.


Wiring Diagram

In this diagram, the brown/white stripe wire is being used for common ground for all the mics. 

In this example, the extra brown wire can be either be ignored or attached together with the brown/white wire to double it up.

Channel 1 blue pair 
Channel 2 Orange Pair 
Channel 3 Green Pair 
Ground Brown pair 
SHARED GROUND FOR ALL 3 CHANNELS


A variation is assigning one channel its own dedicated ground wire as you have two to use.

 SHARED GROUND FOR 2 CHANNELS and 1 CHANNEL DEDICATED

Useful if channels are going to a different location or you hare having a ground hum being introduce by a connected device.  You can have 1 channel isolated from the other two.


Implementation methods

Here are a few termination examples that could be used, but with an understanding of the wiring diagram, there are many possibilities that could be explored.

An efficient no soldering way to build pigtails using an RJ45 breakout box connected to the XLR connectors.  The one shown is a "female" adapter.
Use standard Ethernet cable with RJ45 ends to link each end of the snake.

In the wiring diagram below note that considerations for the "split pair" wiring that a properly built RJ45 Ethernet cable needs to follow.  Connect the Positive, Negative and Ground wires from each XLR connector to the terminal adapter according to the diagram shown.


IMPORTANT!!! "Hey, why do channel 2 wires do not seem to be in order in this picture?"

There is an important wiring methodology that needs to be considered when using Cat5 cabling.  A properly built RJ45 Ethernet cable uses pin groups of  

ORANGE PINS: 1 & 2
GREEN PINS: 3 & 6
BLUE PINS: 4 & 5
BROWN: PINS 7 & 8

Here's a closeup


Take noted that the RED XLR cable, made up of a red, white and ground wire, are going into pins 1&2 in the adapter

The ground wire (black shrink wrap) is going into pin #7.

Possible Applications
Send audio through preexisting Ethernet infrastructure allowing connections between locations allowing analog signals via the in house wires.  
Must NOT pass through any electronic equipment, direct patching between patch bay ports is ok.

In a situation that use this method all the Ethernet jacks were patched directly by IT staff.  Essentially a super long Ethernet wire cable, but not limited by the Ethernet length of 300 foot normal limitation.  A 1000' or more long connection in many cases is achievable.

Monday, December 4, 2017

DIY Camera JIB build

Project highlights
  • $300 in materials
  • Modular length adjustable from 8' - 21' reach
  • Stable, self leveling PTZ head/camera platform
  • Handle 5 lb camera
  • Professional in construction and safety - 100% metal.  No wood 
  • Suitable for live TV broadcast.
  • Off the shelf parts from a hardware store
Finished product showing length 15 feet
This application used a Sony PTZ self contained camera system.


JIB TEST VIDEO


This boom's operation has been really smooth.
The boom of the jib is made from galvanized 1 7/8" fence post pipe with 1 5/8" galvanized fence post pipe acting as pins to to hold it all together.  The result is a solid double pipe boom arm.

THE MAIN BOOM

The entire boom can be pretty much built with items purchased from a typical hardware store like Lowes or Home Depot equivalents. Some clamps and pipes used in this article were on hand already, but substitutes can be easily found.

Some of you will stop reading at this point, loosing interest that its not durable or just flimsy.  This thing is solid, relatively easy to assemble and strong.  There is nothing chintzy about it.



The main exterior body of this jib boom is made of 1 7/8" galvanized pipe intended to build chain link fences. It was purchased in pre-cut, pre-painted black, 7'6" lengths for about $15 each.

Below you see the jib with the section lengths marked for visual references.

To allow easy transport, the boom's interchangeable sections come lengths of 4', 6' and 7'6".  Its been used to a reach from about  8' to 21' reach from the fulcrum point.

Each boom section uses a slightly narrower 1 5/8" pipe that are 4' long each and are inserted into the main boom to increase structure strength and used as "pins" to connected the various sections together.

The picture below is of a prototype pipe that was about 5' long (vs finished 4') hence the uneven length.  The red line indicates the actual 4' length.



Bolts are used with washers located top and bottom.  Washers reduce scratches that the bolts and nuts will do in the surface of the pipe.

The significance of the uniform method of measuring the holes at each end of the boom and pins means boom extensions can be assembled easily like building blocks.  Each section will fit together with another without fussing around with it.

Here you see the sections being connected together.  We've since reduced the bolt lengths



The main 7’6” boom section that attaches to the tripod has to bear a lot of weight.  Taking that into account, another 7'6" of 1 5/8” pipe is inserted into it.  This smaller diameter pipe is effectively sandwiched in to add structural support of the fulcrum boom without affecting the required additional counterweight at the back.  Holes in it are drilled to align with the fulcrum and other bolts to go through it.

This smaller inserted pipe is not completely inserted.  Approximately 18” of it is extended out the front.  This acts as the first primary attachment point for the first section of boom being connected.


A fulcrum hole drilled at the 4' (measure from back of jib) point the boom, matching the size of the now removed dolly wheel axle point is used as the fulcrum point. The 3'6 in front of the fulcrum signifies the beginning of the actual boom.

In this picture the 3/4 bolt going through the main boom pipe, white plastic spacers are keeping everything centered.



The bolt used is not threaded for its entire length.  The pipes fulcrum point is on the smooth section of the bolt to ensure smooth booming up and down of the jib without thread grooves affecting the motion.


The hole for the boom to mount to the pivot point (fulcrum) is critical to get drilled right.  If not drilled perfectly horizontal, the entire jib would be off rotation and boom up/down at an angle that might be undesirable. A jig was used (pictured below) in conjunction with a drill press to ensure the holes were drilled completely "square".  There is a picture of the jig towards the bottom of this post.  It was about $15 and worth every single penny.

GUY WIRES

As the boom is extended out the weight of it will cause it to sag in an arch. This can cause significant unwanted movement and control problems. This is a safety concern of it collapsing.  Its also very visually unsettling.

To counter act the pull of gravity on the boom, guy wires are utilized extending from a 2' vertical mast to various points on the boom front and back. Approximately 6" in front of the fulcrum a threaded 3/8" steel road is mounted through the boom pipe with a series of bolts to ensure its secure. In this jib, a black piece of pipe was used around the rod, in this construction it provided some more vertical stability, and a uniformed black look. The rod that goes through the main boom is held into place by both a clamp, some bolts, and the downwards force place on by the bolt and shackle at the top, and the eventual cable forces applied to it.





Guy wires are attached at each connection point of the boom through an eye bolt and back to the mast. The wires are 1/8 braided steel cable, carbines on one end to speed up connection and turnbuckles at the other end to adjust tension individually. An eye hook doubles as a bolt for each boom section at the 4” point, and the guy wire hooks onto it. The turnbuckle allows for tension adjustments of the boom to remove any sag or bounce.

These cables and turnbuckle adjustments can take some of the load from the main boom and keep it straight. An additional cable going from the mast in the opposite direction back to the main weight bar provided the counter pull action, the resulting in the mast remaining evenly at a 90 degree angle to the boom arm at all times with relatively equal pull in both directions being provided. Performance improvement of the crane with these cables is very noticeable. Locking clamps keep the loops in place.



When the boom is extended, especially 15' and longer, with proper adjustment of the tension on the guy lines, the boom is very very straight and very little up/down bounce (if any really).

COUNTER WEIGHTS

For counter weights at the operator end of the main boom, a 1/2" x 3' square box steel rod is used hold the weights at the very end of the jib arm. Although its sqaure, it would still fit through the hole of the weights. Its held in the boom using a 5/8 bolt and the rear guy wire eyebolt goes through it. The end of it has several additional holes to accommodate different combinations of weights and to hold them in place without slipping off.



Weights on the back of the boom will give a coarse adjustment of the counter balance, getting it pretty close to even balance, but in order to get the fine tuning of the weight distribution, a sliding weight makes this very easy. This boom achieves that with a separate 5lb weight on a clamp can be placed anywhere along the boom where required to accommodate the slight variation of weight front to back. Having this feature is very necessary allows very precise adjustment of the balance of the boom.



CAMERA MOUNT

A true PTZ unit wasn’t required at time of construction as the camera being used on it is already a all in one PTZ HD camera, only a stable constant horizontal platform for the camera is required.

The original plan for the camera mount arm was to bend a 2 1/2 foot section of 3/4" conduit pipe (used for fire alarm cables running through etc) and spray paint the entire length, including the hanger black.



This jib utilized a mount already on hand with the shape that was desired. This was a former CRT television stand that would go on the wall, so it is quite strong.



To attach the camera mount bar to the end of the boom and give it the horizontal movement needed, a 2x10 metal joist hanger was chosen to attach the fulcrum of the camera mount to.  A 3' section of 1 5/8" pipe was cut to slide into the very end of the jib's outside 1 7/8 pipe. The 1 5/8" pipe extends about 8" out with a joist hanger riveted to it, the hanger itself extending out to give about 3" of clearance between the pipe and the end of the joist hanger. This is the point where the "L" shaped camera mount pipe comes through.

About midway in the 3" gap of the joist hanger a hole was drilled to allow a 1/4 high grade bolt to be connected through the joist hanger and the camera arm.  This design allowed the camera bar to move up and down, unimpeded from ground level up to approximately 50 degrees of pitch of the boom upwards. I used a couple of washers to center the "L" pipe in the middle of the joist hanger.  The 1/4 bolt used was about 3" long, so to keep it centered, a nut was used on either side of the joist hanger to keep it tight.

Horizontal Stability of Camera Platform

To control the horizontal level of the camera mount, a metal bar is attached at the booms fulcrum point in a manner that regardless of the booms up or down pitch, it always remained perfectly vertical in line with the tripod center mast.

This jib design uses gravity to naturally pull the camera arm down, so to counter act this force evenly as the boom is moved up and down, a cable is run from the top of the camera arm all the way down the jib to this vertical rod.  As the camera is boomed up or down, the cable keeps a constant even pull on the camera mount causing it to stay in the same degree of horizontal plane.



With this cable attached to the vertical bar of the camera mount at the top, as you boom up or down, the camera platform always stays horizontal (or whatever angle you decide you need during setup) automatically.  Essentially the cable allows the horizontal mount to counter act the boom's pitch, causing it to stay horizontal.

In this application the metal bar purchased was for scaffolding and upon visual inspection at purchase appeared that it would fit with some minor modifications.

The cable has a turnbuckle on it that can be adjusted to make the camera mount line up on the same horizontal plane as the jib.



Although this job doesn't utilize it, the arm could probably be modified to allow for manual movement of the cable, which would give easy tilt adjustment of the camera if desired.

JIB BOOM STAND TRIPOD

This will NOT work with a camera tripod stand.  Don't even think about it.  The center point weight and momentum is tremendous.

An all steel PA stand was utilized from a parts bin.  What was used is discussed here, but you will need to do something that will handle the weight, momentum and movement of the boom.  You need something that is up to the task.

The tripod used for this project was a heavy duty steel stand.  Not aluminum, not white metal, nothing plastic.






Here's how the legs look spread out.  A 12" piece of pipe is slid onto the stand from the bottom of the fulcrum to the top of the leg supports coming out of the center. This maintains the legs spread out, and the center pipe support are "all one", meaning the entire stand legs are "locked" to not move.  You can pick up the light stand and the legs will maintain their stance pictured

BOOM UP/DOWN and PANNING (Fulcrum)

Now the boom needs to be mounted to a tripod in a way that would give reliable smooth panning and booming up and down motion.

What was decided on was a construction dolly wheel used on scaffolding. Designed to handle 750lbs+ of weight, a ball bearing rotation system that had a grease fitting and the supports for the axle for the wheel were ideal for handling the weight.



We removed the wheel and the 'brake' assembly. This left a great mount for the boom, and another connection point for the camera horizontal adjuster.



The mount for this dolly wheel is the same diameter of the center support bar on the tripod I'm using, so I need to ensure it stays upright. When its inserted, the base of the dolly wheel sits on the the center mast of the tripod, transferring the entire weight straight down.



A piece of 1 1/2" metal tube was fitted over the center mast of the tripod stand, extending up just enough to allow the fulcrum to be inserted and locked by a pin.


An additional pipe was slid over it again to double up the strength.  you see the two pipes slide over each other with the holes lining up for the bolts.



This is the final assembly of the support system. The bolts are in place holding it together. The entire unit is "one".  The bolts and pipe inserts keep it as one solid structure. I can pick it up from the dolly and the entire tripod lifts, but maintains its leg spread, since the extra pipes below hold the legs in their ideal length.



OPERATION

It worked. Exactly as hope, and better than anticipated!

Unfortunately at this point no production examples are available due to copyright, but here is a quick JIB video test done when it was first assembled.

JIB VIDEO

The jib really didn't take very long to make and wasn't complicated to manufacture.  Everything was off the shelf with some items modified using basic hand-tools.  There was no need for any custom fabrication using welding, CNC or 3D printing.

To ensure all holes were drilled precisely in the center from top to bottom, a drill press was used in conjunction with a "self centering" pipe jig.   This is placed on the drill press base plate and secured in place with bolts to prevent it from moving.  All pipes are laid in this jig and are center drilled every time.


When the balance is set on this jib, its amazing. The jib can be moved to almost any position and the operator can let go of it and it will stay there, not moving. You'll notice in the video, and this is the same with an actual camera on the end, it easily can be put into motion and let go, and it will continue in that motion autonomously.



The entire boom breaks down into some relatively easy to manage parts, albeit there are quite a few of them. A road case is used to contain all the necessary mounting hardware, as well as some basic had tools and spare bolts and washers that seem to get lost during every tear down.

NOTES ON CONSTRUCTION AND FUTURE CHANGES

1 5/8" pipe has a bit of a gap of 1 7/8" pipe when they are inserted together.  Initially electrical tape was wound around the 1 5/8 pipe on either side of the mount holes to accommodate this gap. Building this up evenly allowed the 5/8 pipe to slide and it works really well. The pipe is evenly centered, and allows for uniform snugging of the bolts when its connected.
This will be upgraded to fiberglass.

No pan/tilt lock on the boom yet. Will work on something as this is kind of a work in progress and I'll update the progress.

Doesn't have real monitor mount for it yet.  Possibly a self leveling monitor system that connects to the guy wire mast

Possible chop of boom to be 6' length (vs 7'6") to simplify transport.

Side guy wires are going to be installed.  At 15' its ok, but as it gets longer, they would really help i'm sure.  The plan is to use a 3' threaded road and use it at the fulcrum when required vs the 3/4 bolt going through it now.

Update of nut/bolt hardware to use darker material to make it as dark as possible.  Also at time bolts were purchased longer than required due to time constraints obtaining slight shorter ones.

Pipe material $100.  Bolts, turnbuckles and wire about $100. scaffolding wheel $50
Tripod $75 (had one already) and weights around $50(?) maybe?

The 1/2" steel square rod used for the weights will be replaced by (probably) full length barbell.  Unclear yet as to the exact design, but focus is being spent on more flexible mounting system for weights than currently used.

Friday, November 17, 2017

FORTINET PORT FORWARD

Want to port forward someone into your network.  This is how. 
In this example we are port forwarding someone on port 5000 into the network.

1. Creating virtual IP

Go to Policy & Objects -> Objects -> Virtual IPs - Create New -> Virtual IP

This example, we want to open up port 5000 from the external IP of 142.154.2.2 and point it to 192.168.10.5 internally.

Note: doing this doesn't expose the external to internal, were just getting ready, policy will need to be done in step 3.

The "NAME" will be the name that the VIP Group will refer to (step 2).  The VIP group name will be the one that the POLICY and OBJECTS will refer to when you actually open this IP up to the internet.(step 3)




2. Adding virtual IPs to a VIP group

Go to Policy & Objects -> Objects -> Virtual IPs - Create New -> Virtual IP GROUP

Create a VIP group. Under Members, include all three virtual IPs previously created.



3. Creating a security policy

Now you create your IPv4 Policy.

Create a new policy

Enter in the name of this inbound plicy and set the external IP of the network that you want to allow in.

Then select the appropriate OUTGOING interface,
Destination address is the Virtual IP name.



Select OK



Wednesday, November 15, 2017

Reset the root password on Centos7

1 – Boot up and when the GRUB menu is displayed, select option to edit.

2 – Select Option to edit (e)

3 – Go to the line of Linux 16 and change ro with rw init=/sysroot/bin/sh.

4 – Now press Control+x to start on single user mode.

5 – Now access the system with this command.
chroot /sysroot

6 – Reset the password.
passwd root

7 – Update selinux information
touch /.autorelabel

8 – Exit chroot
exit

9 – Reboot your system
reboot