Menu

Running locally on a Raspberry Pi?

2021-07-30
2021-12-23
  • Eric Landahl

    Eric Landahl - 2021-07-30

    I would like to run raspi locally, so that I can use Octave (instead of Python or C) to control GPIO pins without a second computer involved. Unfortunately, I have can not install the instrument-control package later than version 3.1, since I can't get an Octave version later than 4.4.1 running on Buster. Any ideas on a workaround?

     
  • lostbard

    lostbard - 2021-12-06

    Sorry for not answering sooner.

    You need at least instrument-control 4.0.0 in order for it to work as some of the functions require features from that version.

    Instrument control should work on anything greater than Octave 3.8, so should compile ok - so it sounds more like an issue with instrument control that shold be fixed.

    Any details on what is failing in instrument control ?

     
  • lostbard

    lostbard - 2021-12-23

    As an update, I tried using 2021-10-30-raspios-bullseye-armhf-lite installed to my raspberry pi.

    Installed octave and liboctave-dev (it installed octave 6.2.0), and then in octave ran:

    pkg install -verbose -forge instrument-control
    

    I saw that it very quickly maxed out swap and cpu as it was running make rules in parallel

    Setting the number of threads used first:

    setenv('OMP_NUM_THREADS', "1")
    

    before running pkg install stopped that.

    Then installing raspi,:

    pkg install https://sourceforge.net/projects/octave-raspberrypi/files/v0.0.2/raspi-0.0.2.tar.gz
    

    Then:

    pkg load
    r = raspi()
    

    There is a pigpio octave file that is installed as part of the raspi package that provides a wrapper around the pigpio protocol if you want to use that instead.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.