Skip to content

Instantly share code, notes, and snippets.

@arangates
Forked from erikkallen/Raspberry PI Network.md
Last active August 29, 2015 14:16
Show Gist options
  • Select an option

  • Save arangates/c78ad0e56287d4f41526 to your computer and use it in GitHub Desktop.

Select an option

Save arangates/c78ad0e56287d4f41526 to your computer and use it in GitHub Desktop.

Revisions

  1. @erikkallen erikkallen revised this gist Jun 22, 2014. 1 changed file with 25 additions and 1 deletion.
    26 changes: 25 additions & 1 deletion VXI11 Ruby
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,27 @@
    ## VXI11 Ruby

    My next post will be about my ruby vxi11 gem
    When working with electronics there is a big chance you need a test setup, This setup often contains big and expensive products like oscilloscopes and signal generators.
    If your lab has big and expensive devices like this, chances are high that they can be controlled using the VXI11 protocol.

    So the generic way of doing this is using windows download the drivers for the device, install something like Labview pay someone a large amount of money and your good to go.

    But what if you don't like windows or paying a large amount of money, and you happen to have some ruby skills.
    Well that's where the VXI11 gem comes in handy.

    So how do you use it?

    # First require the gem
    require 'vxi11'
    # Create an instance of the VXI11 class
    v = VXI11.new
    # Search for devices
    v.find_devices
    # Connect to a found device
    v.connect "10.0.0.1"
    # Send the commands
    puts v.send_and_receive "*IDN?"

    The example above is for getting the identification of a vxi11 device and should be implmented on any vxi11 capable device.
    The other commands should be in the manual specific to your device.

    So that's it for now.
  2. @erikkallen erikkallen renamed this gist May 22, 2014. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion test → VXI11 Ruby
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    ## VXI11
    ## VXI11 Ruby

    My next post will be about my ruby vxi11 gem
  3. @erikkallen erikkallen revised this gist May 22, 2014. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions test
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    ## Test second page
    ## VXI11

    test test
    My next post will be about my ruby vxi11 gem
  4. @erikkallen erikkallen revised this gist May 22, 2014. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion test
    Original file line number Diff line number Diff line change
    @@ -1 +1,3 @@
    ## Test second page
    ## Test second page

    test test
  5. @erikkallen erikkallen revised this gist May 22, 2014. 3 changed files with 37 additions and 4 deletions.
    36 changes: 36 additions & 0 deletions Raspberry PI Network
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,36 @@
    ## Raspberry PI as Arduino network programmer ##


    This guide will show you how to program an Arduino connected to your Raspberry PI from the Arduino IDE on your local computer.
    Linux and OS X for now

    ###On your Raspberry PI

    First install avrdude

    apt-get install avrdude

    Install avrdude-rpi using the installation tips from https://github.com/deanmao/avrdude-rpi they boil down to this:

    wget https://raw.githubusercontent.com/deanmao/avrdude-rpi/master/autoreset
    wget https://raw.githubusercontent.com/deanmao/avrdude-rpi/master/avrdude-autoreset
    sudo cp autoreset /usr/bin
    sudo cp avrdude-autoreset /usr/bin
    sudo mv /usr/bin/avrdude /usr/bin/avrdude-original
    sudo ln -s /usr/bin/avrdude-autoreset /usr/bin/avrdude

    Next open the file /usr/bin/autoreset and change the reset pin to the pin you connected the Arduino reset to.
    The GPIO pin number corresponds to the number of the pin of the header.

    vim /usr/bin/autoreset

    ###On your computer

    Download and install Arduino IDE
    go to the folder containing avrdude
    On OS X this most likely is /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin

    cd /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin
    mv avrdude avrdude-original
    wget https://gist.github.com/erikkallen/11153072/raw/3e1cdfdef6aee12b9f0f47b50bc33849612f2a0d/avrdude
    chmod +x avrdude
    3 changes: 0 additions & 3 deletions site_new_post_test.md
    Original file line number Diff line number Diff line change
    @@ -1,3 +0,0 @@
    ## Test title

    test post
    2 changes: 1 addition & 1 deletion test
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    test
    ## Test second page
  6. @erikkallen erikkallen revised this gist May 22, 2014. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions test
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    test
  7. @erikkallen erikkallen created this gist Apr 27, 2014.
    3 changes: 3 additions & 0 deletions site_new_post_test.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    ## Test title

    test post