Giter Site home page Giter Site logo

gatherera / micropython-ulab Goto Github PK

View Code? Open in Web Editor NEW

This project forked from v923z/micropython-ulab

0.0 0.0 0.0 1.82 MB

a numpy-like fast vector module for micropython

Home Page: https://github.com/v923z/micropython-ulab

License: MIT License

C 99.62% Makefile 0.38%

micropython-ulab's Introduction

micropython-ulab

ulab is a numpy-like array manipulation library for micropython. The module is written in C, defines compact containers for numerical data, and is fast.

Documentation can be found under https://micropython-ulab.readthedocs.io/en/latest/ The source for the manual is in https://github.com/v923z/micropython-ulab/blob/master/docs/ulab-manual.ipynb, while developer help is in https://github.com/v923z/micropython-ulab/blob/master/docs/ulab.ipynb.

Firmware

Firmware for pyboard.v.1.1, and PYBD_SF6 is updated once in a while, and can be downloaded from https://github.com/v923z/micropython-ulab/releases.

Compiling

If you want to try the latest version of ulab, or your hardware is different to pyboard.v.1.1, or PYBD_SF6, the firmware can be compiled from the source by following these steps:

First, you have to clone the micropython repository by running

git clone https://github.com/micropython/micropython.git

on the command line. This will create a new repository with the name micropython. Staying there, clone the ulab repository with

git clone https://github.com/v923z/micropython-ulab.git ulab

Then you have to include ulab in the compilation process by editing mpconfigport.h of the directory of the port for which you want to compile, so, still on the command line, navigate to micropython/ports/unix, or micropython/ports/stm32, or whichever port is your favourite, and edit the mpconfigport.h file there. All you have to do is add a single line at the end:

#define MODULE_ULAB_ENABLED (1)

This line will inform the compiler that you want ulab in the resulting firmware. If you don't have the cross-compiler installed, your might want to do that now, for instance on Linux by executing

sudo apt-get install gcc-arm-none-eabi

If that was successful, you can try to run the make command in the port's directory as

make BOARD=PYBV11 USER_C_MODULES=../../../ulab all

which will prepare the firmware for pyboard.v.11. Similarly,

make BOARD=PYBD_SF6 USER_C_MODULES=../../../ulab all

will compile for the SF6 member of the PYBD series. Provided that you managed to compile the firmware, you would upload that by running either

dfu-util --alt 0 -D firmware.dfu

or

python pydfu.py -u firmware.dfu

In case you got stuck somewhere in the process, a bit more detailed instructions can be found under https://github.com/micropython/micropython/wiki/Getting-Started, and https://github.com/micropython/micropython/wiki/Pyboard-Firmware-Update.

micropython-ulab's People

Contributors

v923z avatar gatherera avatar mdaeron avatar nickovs avatar

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.