GithubHelp home page GithubHelp logo

4ms / smr Goto Github PK

View Code? Open in Web Editor NEW
106.0 28.0 23.0 6.42 MB

Spectral Multiband Resonator

License: Other

Makefile 0.06% C 74.21% C++ 0.10% Assembly 0.59% GDB 0.01% Objective-C 25.04%

smr's Introduction

SMR

Spectral Multiband Resonator

Firmware for the Spectral Multiband Resonator, a Eurorack-format module from 4ms Company.

The SMR is a 6-channel highly resonant filter ("resonator") with a ring of RGB LEDs, six sliders, and stereo audio inputs and outputs. The main processor is the STM32F427 chip. For more details see http://www.4mspedals.com/smr.php

The SMR would make a nice platform for other audio projects, the hardware contains:

  • 180MHz 32-bit ARM chip with FPU (STM32F427)
  • Stereo codec chip (running at 96kHz/24bit in this firmware)
    • Two audio inputs, two audio outputs
  • Five 16-channel PCA9685 LED drivers (10-bits per channel)
  • 26 RGB LEDs, 20 are arranged in a circle/ellipse, 6 are arranged in a line
  • Six slider potentiometers with an LED on the shaft
  • Five potentiometers
  • Six momentary LED buttons
  • A rotary encoder and button
  • Six toggle switches (one is SP3T, others are SPST)
  • Twelve CV inputs
  • Six gate/digital inputs (can be used as unscaled CV inputs)
  • Six CV outputs (0V-8V), driven by PWM

As of writing this (March 2016), there are three PCB versions: 1.0, 1.0.1, and 1.0.2. These are functionally identical and this firmware will run exactly the same on all versions.

Setting up your environment

You need to install the GCC ARM toolchain. This project is known to compile with arm-none-eabi-gcc version 4.8.3, and version 4.9.3. It is likely that it will compile with future versions as well.

It's recommended (but not necessary) to install ST-UTIL/stlink. Without it, you will have to update using the audio bootloader, which is very slow (5 minutes per update). With ST-UTIL or stlink and a programmer, you can update in 5-20 seconds. The Texane stlink package contains a gdb debugger, which works with ST-LINK programmers such as the STM32 Discovery boards to connect to the Spectral's 4-pin SWD header. The STM32F4 Discovery Board is low-cost (under US$15) and works great as a programmer and debugger.

You also may wish to install and IDE such as Eclipse. There are many resources online for setting up GCC ARM with Eclipse (as well as commerical software). This is totally optional. Instead of an IDE you can use your favorite text editor and a few commands on the command line (Terminal) which are given below.

Continue below for Max OSX, Linux, or Windows instructions.

Mac OSX

For Mac OSX, follow these instructions to install brew and then the arm toolchain and st-link (taken from https://github.com/nitsky/homebrew-stm32):

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew tap nitsky/stm32
brew install arm-none-eabi-gcc
brew install stlink

That's it! Continue below to Clone the Projects

Linux

For linux, check your package manager to see if there is a package for arm-none-eabi-gcc or gcc-arm-embedded or gcc-arm-none-eabi. Or just download it here:

Download GCC ARM toolchain from Launchpad

Next, install st-link from texane:

sudo apt-get install git libusb-1.0.0-dev pkg-config autotools-dev
cd (your work directory)
git clone https://github.com/texane/stlink.git
cd stlink
./autogen.sh
./configure
make
export PATH=$PATH:(your work directory)/stlink

The last command makes sure that the binary st-flash is in your PATH so that the Makefile can run it to program your module.

That's it! Continue below to Clone the Projects

Windows

Download GCC ARM toolchain from Launchpad

Download ST-UTIL

Install both. Please contact me if you run into problems that you can't google your way out of!

Clone the Projects

Make sure git is installed on your system. (OSX: type "brew install git" into the Terminal)

Create a work directory, and enter it.

Clone this project (SMR), stmlib, and the stm-audio-bootloader projects:

git clone https://github.com/4ms/SMR.git  
git clone https://github.com/4ms/stmlib.git
git clone https://github.com/4ms/stm-audio-bootloader.git

Create a symlink for stm-audio-bootloader so that it works with python (required to generate the .wav file for audio bootloading)

 ln -s stm-audio-bootloader stm_audio_bootloader

Verify that your directories are as follows:

(work directory)
|  
|--SMR/  
|--stm-audio-bootloader/  
|--stm_audio_bootloader/   <----symlink to stm-audio-bootloader
|--stmlib/

Compiling

Make your changes to the code in the SMR directory. When ready to compile, make the project like this:

cd SMR
make

If you want to flash the file onto the SMR, attach an ST-LINK programmer in SWD mode using a 4-conductor cable and run:

make flash

Read the Discovery Board's manual for how to set it to program external devices. On the STM32F4 Discovery board, you have to remove two DISCOVERY jumpers to put it in ST-LINK mode. Connect the 4-pin cable to the SWD header starting at the dot (pin 1) on the Disco board. On the SMR, pin 1 is labeled with a "1". Any 4-pin cable or even 4 breadboard jumper wires will work. A 10-to-16 pin eurorack power cable is fine too, if it's short enough.

When ready to build an audio file for the bootloader, make it like this:

make wav

This requires python to run. It creates the file main.wav in the build/ directory. Play the file from a computer or device into the SMR by following the instructions in the User Manual on the 4ms SMR page.

Troubleshooting: If you have trouble getting python to create a wav file, such as this error:

ImportError: No module named stm_audio_bootloader

Then try this command:

export PYTHONPATH=$PYTHONPATH:'.'

Bootloader

The bootloader is a separate project, slightly modifed from the stm-audio-bootloader from pichenettes.

The bootloader is already installed on all factory-built SMRs.

License

The code (software) is licensed by the MIT license.

The hardware is licensed by the CC BY-NC-SA license (Creative Commons, Attribution, NonCommercial, ShareAlike).

See LICENSE file.

I would like to see others build and modify the SMR and SMR-influenced works, in a non-commercial manner. My intent is not to limit the educational use nor to prevent people buying hardware components/PCBs collectively in a group. If you have any questions regarding the license or appropriate use, please do not hesitate to contact me!

Guidelines for derivative works

Do not include the text "4ms" or "4ms Company" or the graphic 4ms logo on any derivative works. This includes faceplates, enclosures, or front-panels. It's OK (but not required) to include the text "Spectral Multiband Resonator" or "SMR" if you wish.

smr's People

Contributors

danngreen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

smr's Issues

Missing initialisation

SMR/rotation.c

Line 199 in 2e75101

test_motion[1]=99;

test_motion[2] is not initialised. I guess that you'd have to be pretty unlucky for this to make a difference that would ever be noticeable...

Panel Vector / DXF / SVG Files?

Good day.

I was wondering if the panel design files without the logos are available somewhere or if I have to do a redraw of the panel vectors myself?

Trigger mode will not affect PercAll trigger input

Hi there,

I have a confusing issue, my SMR, when using ENV-OUTS in trigger mode, will trigger anything I have apart from the PercAll - and I can't work out why that might be. Confirmed triggers seen on Zadar, for example, and will operate the Gate on the mother-32.
Pink firmware light (not sure how to confirm if i'm on v5, 5.1, or 5.1.1).
Can you advise on possible reasons?

Kind regards,
Gaz

No V/OCT output for 1-Pass/MAXQ

It appears that V/Oct output should not work for the 1-Pass/MAXQ setting

SMR/filter.c

Line 577 in 2e75101

}

There is no equivalent setting of ENVOUT_preload[channel_num] as is done for 2-Pass. I don't think there is a reason why it shouldn't work.

Licensing for the SMRF Eagle files?

Hi Dan,

A question was raised on MW about the licensing of the Eagle files for your SMR filter design. All the firmware source code for it is clearly licensed under the MIT license, but the text of that license refers to software only. There doesn't seem to be any explicit licensing for the hardware design files - something like CC-BY-SA, which is what Olivier Gillet uses for his hardware design files. Just a line added to the README or LICENSE files for the repo would suffice, i think.

Regards,

Tim C

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.