edeca.net logo
  • rss
  • Home
  • Graphics
  • Electronics
    • PCB0002 – LED matrix
  • Computing
    • ROT Util
    • MOTD maker
    • GNU screen config
    • VB6 reverse DNS
    • VB6 RichTextBox control
  • About

BatchPCB

David | April 17, 2011

I have previously raved about BatchPCB, a low cost prototyping service run by SparkFun out of the USA. However, it seems that you now can’t select shipping to the UK (and perhaps other parts of Europe) and they don’t seem to be doing too much about it.

I emailed a few weeks ago and have received no reply, so all I have to go on is a few posts on their forums which confirm I’m not the only one experiencing the issue.

So BatchPCB, unless you can get this fixed I’m afraid I’ll be seeking an alternative. Comments suggesting other cheap PCB fabrication houses welcome, I’ll probably try DorkbotPDX first.

Comments
No Comments »
Categories
Electronics
Tags
batchpcb, pcb
Comments rss Comments rss
Trackback Trackback

Using the Razor view engine with S#arp architecture

David | March 12, 2011

Whilst the Sharp Architecture maintainers have little interest in Razor (see here), I have been using it recently and like the syntax.

Swapping out a default project to use Razor instead of (or in addition to) the default engine isn’t too difficult.

Enabling the view engine

In Global.asax, find the few lines below in Application_Start():

ViewEngines.Engines.Clear();
ViewEngines.Engines.Add(new AreaViewEngine());

We need to register Razor here, by adding the line below:

ViewEngines.Engines.Add(new RazorViewEngine());

If you do not plan on using the default view engine then you can comment the existing line and remove all the .aspx files from the Views directory.

Configuring the default layout

Create an empty file called _ViewStart.cshtml in the root of your Views folder:

@{
Layout = "~/Views/Shared/_Layout.cshtml";
}

This code runs before any other view code in this directory or below and sets the default layout so you don’t have to set it manually in every view (see the MVC3 release notes for more information).

Create a basic template

Lastly we need the layout which was referenced above, created as Views/Shared/_Layout.cshtml. You could copy and paste this from a new MVC Razor application, which is what I did to end up with the template below:

<!DOCTYPE html>
<html>
<head>
    <title>MyApp - @ViewBag.Title</title>
    <link href="@Url.Content("~/Content/Site.css")" rel="stylesheet" type="text/css" />
    <script src="@Url.Content("~/Scripts/jquery-1.4.4.min.js")" type="text/javascript"></script>
</head>
<body>
    <div class="page">
        <div id="header">
            <div id="title">
                <h1>MyApp</h1>
            </div>
           
        </div>

        <div id="main">
            @RenderBody()
            <div id="footer">
            </div>
        </div>
    </div>
</body>
</html>

Conclusion

This is all that should be necessary to enable Razor and start to return basic views from your controllers. From here on you can create views just like in the MVC3 tutorials.

Comments
1 Comment »
Categories
Computing
Tags
mvc, razor, sharp architecture
Comments rss Comments rss
Trackback Trackback

Updated Eagle library posted

David | February 12, 2011

I have just uploaded the latest version of my Eagle library, containing a bunch of new parts.  These include:

  • Maxim DS1337 RTC
  • RFM12 radio module (with pins)
  • Keystone CR123A battery holder
  • Memsic MXC6202 I2C accelerometer
  • ON Semi CAT6219 500mA LDO regulator
  • Texas Instruments TSL2560 / TSL2561 light-to-digital converter
  • Maxim DS620 Low-Voltage, ±0.5°C Accuracy thermometer

The library can be found on the Electronics page.

Comments
2 Comments »
Categories
Uncategorized
Comments rss Comments rss
Trackback Trackback

PCB antenna design

David | December 20, 2010

One of the circuit boards I’m developing would benefit from an onboard antenna, so I started hunting for design tips.  The following three PDF documents do a great job of explaining the basics:

  • Freescale “Compact Integrated Antennas“
  • Kent Smith “Antennas for low power applications“
  • Ingecom “V / UHF Antenna Design“

I will update the blog once the circuit board is designed and I have managed to test range and effectiveness.

Comments
No Comments »
Categories
Electronics
Tags
antenna, pcb, rf
Comments rss Comments rss
Trackback Trackback

Welcome to the IPv6 world

David | November 7, 2010

This blog can now be reached over IPv6 (or ipv6.edeca.net), which is surely the final nail in the coffin of IPv4 across the internet.
Read the rest of this entry »

Comments
No Comments »
Categories
Computing
Tags
ipv6, security
Comments rss Comments rss
Trackback Trackback

PCB0002 – LED matrix

David | October 30, 2010

It has been ages since I have updated this site. I have started to document some of the PCBs I have created

The first is an 8×8 LED matrix, with code for some whizzy effects. More information and downloads on this page.

If anybody wants to see the code, I could tidy it up a bit and post with some explanation.

Comments
No Comments »
Categories
Electronics
Tags
electronics, pcb
Comments rss Comments rss
Trackback Trackback

O2 iPhone (iOS4) provisioning bug

David | July 10, 2010

I finally upgraded my old iPhone 3GS to iOS4, but it wasn’t a smooth process. It seems O2 have a problem with their provisioning process because, after the upgrade, all of the carrier settings had disappeared. There was no way to setup Visual Voicemail in the menu and no internet services worked when I wasn’t on wifi.

Every time the phone was plugged into the computer iTunes would say that there was an update for the carrier settings, but it never applied and the menu entries remained blank. O2 support were only slightly helpful, taking me through the settings which appear on their website but not fixing the Visual Voicemail issues or the prompt in iTunes.

There are threads on the O2 site here and here and a useful one on AVForums which gives the fix.

Unfortunately the fix is to completely reset the iPhone and start from scratch. Restoring from a backup simply brings the old (broken) settings back. I couldn’t find a way to only synchronise contacts back to the phone, though iTunes suggests it is possible.

Follow these steps to repair it:

  1. erase the phone from the menu: Settings -> General -> Reset -> Erase All Content and Settings
  2. connect the phone to iTunes and restore iOS4
  3. set the device up as a new phone, not from a backup!

Browsing through the carrier settings menu should now show the correct values for APN (idata.o2.co.uk). Importantly, the Visual Voicemail settings should also be in the menu.

Now to setup all my apps, account sand contacts from scratch..

Comments
No Comments »
Categories
General
Comments rss Comments rss
Trackback Trackback

Net::LibNIDS 0.1 released

David | June 30, 2010

The other day I pushed a new version of Net::LibNIDS to CPAN. It interfaces with the C library libnids in order to provide TCP stream reassembly and returns the data to your Perl callback.
Read the rest of this entry »

Comments
2 Comments »
Categories
Computing, Perl
Comments rss Comments rss
Trackback Trackback

Production music samples

David | June 6, 2010

Whilst looking for some music to use as jingles/beds for a charity radio project I assist I found FreeNotesMusic. From a quick listen there are some fantastic tracks, really nice composition and production.

Big thanks go to Simon from the company who responded to my queries very quickly.

Comments
No Comments »
Categories
General
Comments rss Comments rss
Trackback Trackback

Better than grep

David | May 29, 2010

Anybody who has used command-line systems for a serious amount of time will love grep. But today I stumbled across ack, which (for many things) is better than grep and a whole lot nicer to use.

The best bit? It’s pure Perl, therefore also uses real Perl regular expressions. Yes, there might be grep --perl-regexp, but nobody bothers compiling that in. Plus ack has some other neat features.

See more at the ack website.

Comments
No Comments »
Categories
Computing
Comments rss Comments rss
Trackback Trackback

« Previous Entries Next Entries »

Categories

  • Computing
  • Electronics
  • General
  • Perl
  • Photography
  • Uncategorized

Archives

  • February 2012
  • December 2011
  • November 2011
  • July 2011
  • June 2011
  • April 2011
  • March 2011
  • February 2011
  • December 2010
  • November 2010
  • October 2010
  • July 2010
  • June 2010
  • May 2010
  • April 2010
  • March 2010
  • February 2010
  • January 2010
  • November 2009
  • September 2009
  • August 2009
  • July 2009
  • June 2009

Links

  • My photo gallery
  • Pookey's site

Meta

  • Log in
  • Entries RSS
  • Comments RSS
  • WordPress.org
rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox