Go on the PhidgetSBC3 Part 2

Now that go is installed ([see Part 1](/2013/03/go-on-the-phidgetsbc3-part-1/)), you can get down to business and start using phidgets. I’ve written a go phidgets library (currently only `InterfaceKit` and `IR` phidgets are implemented, open an issue or pull request if you want more) at [github.com/samuelkadolph/go/phidgets](https://github.com/samuelkadolph/go/tree/master/phidgets).

Continue reading “Go on the PhidgetSBC3 Part 2”

Go on the PhidgetSBC3 Part 1

The latest version of the [PhidgetSBC line](http://www.phidgets.com/products.php?category=21) includes an ARMv5 processor which means it now has support for go. Unfortunately the current golang package in the debian repository does not work but I was able to [compile golang from source](http://golang.org/doc/install/source) on the PhidgetSBC3 and it worked (including [`cgo`](http://golang.org/cmd/cgo/)). Thanks to the [
“The Go Language Gophers” team](https://launchpad.net/~gophers/+archive/go) I downloaded the `golang-tip` package and built it on my PhidgetSBC3. I’ve made this `deb` available in my apt repository so you can easily install go and get rocking.

Continue reading “Go on the PhidgetSBC3 Part 1”

Fix locales on the PhidgetSBC3

If you are using a PhidgetSBC3 you might see this a lot:

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = “en_CA.UTF-8”
are supported and installed on your system.
perl: warning: Falling back to the standard locale (“C”).
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory

This is because perl is very vocal when you are missing the locales that your environment specifies. The fix is easy, just generate the locales that you want to use (`en_CA.UTF-8` is the default). This assumes you have already set up SSH on your PhidgetSBC3.

1. Enable full Debian Package Repository
Enable the full Debian Package Repository
2. Update apt
* `apt-get update`
3. Install the locales package
* `apt-get install locales -y`
4. Add the `en_CA.UTF-8` locale
* `echo “en_CA.UTF-8 UTF-8” >> /etc/locale.gen`
5. Generate the locale
* `locale-gen`

You should see it generating the locale you specified and once it’s done, you will no longer see the locale error messages.

PhidgetSBC3 and D-Link DWA-160

> There’s actually a much easier way of doing this. Just `apt-get install firmware-linux-free` and boom! You get the carl9170 firmware and the DWA-160 is recognized.

I recently got my hands on a [PhidgetSBC3](http://www.phidgets.com/products.php?product_id=1073_0) and plugged a [D-Link DWA-160](http://www.dlink.com/ca/en/home-solutions/connect/adapters/dwa-160-xtreme-n-dual-band-usb-adapter) into and found that it already had support built into the kernel but it had an error. So I went searching in the `/lib/firmware` directory and saw there was no `carl9170-1.fw` file. So I downloaded and when I plugged the DWA-160 back in it worked and correctly showed up in the web interface. Installing it is very easy:

apt-get install curl -y
curl -L http://linuxwireless.org/en/users/Drivers/carl9170/fw1.9.7?action=AttachFile&do=get&target=carl9170-1.fw > /lib/firmware/carl9170-1.fw