Running the Processing environment on ARM SBCs Lessons learned - - PowerPoint PPT Presentation

running the processing environment on arm sbcs
SMART_READER_LITE
LIVE PREVIEW

Running the Processing environment on ARM SBCs Lessons learned - - PowerPoint PPT Presentation

Running the Processing environment on ARM SBCs Lessons learned & whats missing for having an Arduino equivalent on top of Linux Gottfried Haider @mrgohai Processing Processing a flexible software sketchbook and a language for


slide-1
SLIDE 1

Running the Processing environment on ARM SBCs

Lessons learned & what’s missing for having an Arduino equivalent on top

  • f Linux

Gottfried Haider @mrgohai

slide-2
SLIDE 2

Processing

slide-3
SLIDE 3

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts”

slide-4
SLIDE 4

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts” started 2001 by Casey Reas & Ben Fry at MIT Media Lab

slide-5
SLIDE 5

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts” started 2001 by Casey Reas & Ben Fry at MIT Media Lab since developed by a group of programmers, educators, designers (LGPL/GPL)

slide-6
SLIDE 6

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts” started 2001 by Casey Reas & Ben Fry at MIT Media Lab since developed by a group of programmers, educators, designers (LGPL/GPL) based on Java (but also p5.js, Processing.py)

slide-7
SLIDE 7

Demo

slide-8
SLIDE 8

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts” started 2001 by Casey Reas & Ben Fry at MIT Media Lab since developed by a group of programmers, educators, designers (LGPL/GPL) based on Java (but also p5.js, Processing.py) many resources, especially for education

slide-9
SLIDE 9
slide-10
SLIDE 10

Processing

“a flexible software sketchbook and a language for learning how to code within the context of the visual arts” started 2001 by Casey Reas & Ben Fry at MIT Media Lab since developed by a group of programmers, educators, designers (LGPL/GPL) based on Java (but also p5.js, Processing.py) many resources, especially for education https:/ /github.com/processing/

slide-11
SLIDE 11

Processing on the Raspberry Pi

slide-12
SLIDE 12

Processing on the Raspberry Pi

Google Summer of Code

slide-13
SLIDE 13

Processing on the Raspberry Pi

Google Summer of Code Motivation:

  • accessibiliy through price point (roughly equivalent

to Arduino)

slide-14
SLIDE 14

Processing on the Raspberry Pi

Google Summer of Code Motivation:

  • accessibiliy through price point (roughly equivalent

to Arduino)

  • more powerful than AVR (FFT, computer vision,

networking)

slide-15
SLIDE 15

Processing on the Raspberry Pi

Google Summer of Code Motivation:

  • accessibiliy through price point (roughly equivalent

to Arduino)

  • more powerful than AVR (FFT, computer vision,

networking)

  • prospect of a fully open 3D graphics stack (GLES2)
slide-16
SLIDE 16

Processing on the Raspberry Pi

Google Summer of Code Motivation:

  • accessibiliy through price point (roughly equivalent

to Arduino)

  • more powerful than AVR (FFT, computer vision,

networking)

  • prospect of a fully open 3D graphics stack (GLES2)
  • access to large repositories of FLOSS software - great

to introduce users to the benefits of working with existing communities (but: ARMv6)

slide-17
SLIDE 17

Processing on the Raspberry Pi

Google Summer of Code Results:

  • shipped in Processing 3.0.1 - try it out!
  • 3D works with the current, closed-source GLES2

driver - thanks to JOGL & Xerxes Rånby

  • also works with the in-progress DRM & Mesa Gallium

driver by Eric Anholt (image @ http:/ /sukzessiv.net /~gohai/vc4-buildbot/build/)

  • can build on x86, deploy on ARMv6
  • Hardware I/O library!
  • should run on any ARMv6+ hard-float SBC (minus

GLES2 upbringing)

slide-18
SLIDE 18

Processing on the Raspberry Pi

Hardware I/O processing.io.* Arduino UART x x GPIO x x I2C x x SPI x x PWM ~ x LED x

slide-19
SLIDE 19

Processing on the Raspberry Pi

Hardware I/O processing.io.* Arduino UART x x GPIO x x I2C x x SPI x x PWM ~ x LED x Caveats (non hard-realtime OS, etc) - best effort

slide-20
SLIDE 20

Processing on the Raspberry Pi

Hardware I/O - what’s missing? (and why is this in the mobile & embedded devroom?!)

slide-21
SLIDE 21

Processing on the Raspberry Pi

Hardware I/O - what’s missing? (and why is this in the mobile & embedded devroom?!) https:/ /github.com/gohai/arduino-like-linux Comments?

slide-22
SLIDE 22

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM
  • Runtime pullup configuration
  • Make PWM sysfs export show up in udev
  • Race-free export of GPIO, PWM in sysfs?
  • A way to get from PWM channel to GPIO number
slide-23
SLIDE 23

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM

kernel-land implementation using high-resolution timers Bill Gatliff had a patch in 2010 - there are others e.g. i2c-gpio wish: /sys/class/gpio/gpioN/software_pwm

  • Runtime pullup configuration
  • Make PWM sysfs export show up in udev
  • Race-free export of GPIO, PWM in sysfs?
  • A way to get from PWM channel to GPIO number
slide-24
SLIDE 24

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM
  • Runtime pullup configuration

currently only possible through device tree overlays w/ pinconf

  • vs. digitalWrite() on INPUTs in Arduino

wish: /sys/class/gpio/gpioN/bias (behind config option?)

  • Make PWM sysfs export show up in udev
  • Race-free export of GPIO, PWM in sysfs?
  • A way to get from PWM channel to GPIO number
slide-25
SLIDE 25

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM
  • Runtime pullup configuration
  • Make PWM sysfs export show up in udev

writing to /sys/class/pwm/.../export doesn’t trigger events for udev (works w/ /sys/class/gpio/export) hence currently root required

  • Race-free export of GPIO, PWM in sysfs?
  • A way to get from PWM channel to GPIO number
slide-26
SLIDE 26

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM
  • Runtime pullup configuration
  • Make PWM sysfs export show up in udev
  • Race-free export of GPIO, PWM in sysfs?

exporting a GPIO pin needs to wait for udev to do its thing currently: Thread.sleep(500) perhaps: default owner & mode taken from export node? ideas?

  • A way to get from PWM channel to GPIO number
slide-27
SLIDE 27

Processing on the Raspberry Pi

Hardware I/O - Wishlist

  • Software PWM
  • Runtime pullup configuration
  • Make PWM sysfs export show up in udev
  • Race-free export of GPIO, PWM in sysfs?
  • A way to get from PWM channel to GPIO numbers

sysfs doesn’t tell you this atm

slide-28
SLIDE 28

Processing on the Raspberry Pi

Hardware I/O - Any help greatly appreciated :) https:/ /github.com/gohai/arduino-like-linux Comments?

slide-29
SLIDE 29

Thank you FOSDEM!

Gottfried Haider @mrgohai