Grasshopper

generative modeling for Rhino

Information

Firefly

Firefly offers a set of comprehensive software tools dedicated to bridging the gap between Grasshopper, (a free plug-in for Rhino) the Arduino microcontroller and other input/output devices. It allows near real-time data flow between the digital and physical worlds – enabling the possibility to explore virtual and physical prototypes with unprecedented fluidity.

Website: http://www.fireflyexperiments.com/
Location: Cambridge, MA
Members: 316
Latest Activity: on Monday

Firefly Experiments

Firefly offers a set of comprehensive software tools dedicated to bridging the gap between Grasshopper (a free plug-in for Rhino) and the Arduino micro-controller. It allows near real-time data flow between the digital and physical worlds – enabling the possibility to explore virtual and physical prototypes with unprecedented fluidity.

As a generative modeling tool, Grasshopper offers a fluid visual interface for creating sophisticated parametric models, but by default, it lacks the ability to communicate with hardware devices such as programmable microcontrollers or haptic interfaces. Firefly fills this void. It is an extension to the Grasshopper’s parametric interface; combining a specialized set of components with a novel communication protocol (called the Firefly Firmata or Firmware) which together enable real-time communication between hardware devices and the parametric plug-in for Rhino.

A notable distinction for Firefly is that it is the first visual microcontroller programming environment designed specifically for a 3-D parametric CAD package (such as Rhino). This feature means that real-world data, acquired from various types of sensors or other input devices (video cameras, internet feeds, or mobile phone devices, etc.) can be used to explicitly define parametric relationships within a Grasshopper model. Firefly completes the communication feedback loop by allowing users the ability to send information from Grasshopper back to the microcontroller in order to incite specific actuations (ie. lights, motors, valves, etc). Ultimately, this workflow creates a new way to create interactive prototypes.

Discussion Forum

Remembering values with rotary switching 10 Replies

Hi Everyone.I am using a rotary switch with firefly that sends values to a stream gate. I want to remember the last set of data sent via the stream after switching. Can VB scripting do this? In the image below stream 1 is reading data but stream 2…Continue

Tags: gate, stream, switching, firefly

Started by Scott Mayson. Last reply by Andy Payne May 14.

Serial read problem in Firefly 6 Replies

Hi guys,I'm communicating with a 3D printer via Grasshopper / Firefly (and eventually) Silkworm.So far, I can quite happily send G-Code move commands to the printer  - which is a Leapfrog Creatr, based on Arduino Mega / RAMPS electronics - via the…Continue

Tags: GCode, Read, Serial, Firefly

Started by fergal.coulter. Last reply by fergal.coulter May 10.

Possible to connect 12 micro servos to Arduino Uno board and control each one separately? 4 Replies

I am as much of a novice to Firefly and Arduino as one can get. I have 12 servos and an Arduino Uno board... is it possible to connect them all to a single board and control their rotation values in Firefly...? I'm investigating myself as of writing…Continue

Started by Adam Roark. Last reply by Andy Payne Apr 23.

Pleated Skin Actuation

Hi I'm trying to actuate the pleated skin shown in this model. I am planning on using servos to move the pleated skin in the form of a sin wave. I have a series of structural columns in the model that would be the base for the servos, but I was…Continue

Tags: pavilion, firefly, pleats

Started by Nicholas Murao Apr 9.

News


Drag & Drop Programming

Using Grasshopper's visual programming interface, Firefly gives you the ability to create interactive programs and devices by manipulating elements graphically rather than by specifying them textually.  It attempts to bridge the gap between the digital and physical worlds by simplifying the prototyping process for interactive objects.  It combines a specialized set of components with a novel communication protocol (called the Firefly Firmata, or Firmware) which together enable real-time feedback between hardware devices such as the well-known Arduino microcontroller and the Rhino / Grasshopper modeling environment.  All this happens instantly -  so there's no compiling.  Your program runs as you build it, making development and prototyping an extremely rapid process.


Advanced Code Generation


Leveraging Grasshopper's visual programming interface, Firefly gives you the ability to quickly mock-up and prototype ideas for interactive objects and devices.  It achieves this mostly by sending data back and forth over the serial port really quickly.  But, what if you want your device to stand-alone... meaning you don't want to be tethered to your computer by a pesky USB cable.  In order to do this, the microcontroller must be programmed, typically using some C++ or Arduino code.  

Fortunately, Firefly has an advanced Code Generation feature which translate the spatial representation of your Grasshopper code directly into Arduino compatible code.  And it does this all on the fly.  Now, you don't need to worry about writing all of that code yourself.  Simply, prototype your design as you normally would, and the Code Generator will work in the background writing all of the code necessary to make your design come to life!

Connect to Physical Devices​ in Real-Time

Firefly alleviates the hastle of interfacing with external hardware. The Firefly toolset has pre-built components that allow you to connect to many of the most popular hardware devices including data acquisition devices, mobile phones, cameras, game controllers (like the Wii Nunchuck and Microsoft Kinect) and audio interfaces to name but a few.


Computer Vision Tools


Firefly has an extensive suite of computer vision, analysis, and effects tools.  Integrate video feeds (now with multiple camera support), load individual images (.jpg, .tif, .png, .bmp, etc.), play video files and more.  Firefly also includes several filtering, graphic effects, and compositing tools to manipulate live image data.  In addition, you can create your own custom filters using convolution kernels.  You can also take advantage of computer vision algorithms such as optical flow, gradient vectors, contour vectors, and color analysis to make your next interactive project a visual success.

Comment Wall

Comment

You need to be a member of Firefly to add comments!

Comment by Miguel Vidal on January 24, 2013 at 2:03pm

Hi Andy!

Thanks for your reply, I´ll try that.

One more question: in the last version of Firefly, did you erase the functions for sound management?

Comment by Andy Payne on January 23, 2013 at 9:39pm

Hi Miguel,

The IsKeyPressed component makes use of the built in User32.dll Microsoft library (http://en.wikipedia.org/wiki/Microsoft_Windows_library_files)  Once this library is imported into the project, you can tap into key events (and potentially other events... although I'm not sure this is entirely necessary for mouse events... Grasshopper is already doing some stuff for mouse events).  

Comment by Miguel Vidal on January 23, 2013 at 3:34pm

Hello! As there is a keyPressed component, is there other one for mousePressed?

what windows functions are you using for this tools in case I would need to use them in a script?

thanks!

Comment by philipp hornung on November 22, 2012 at 5:15pm

yes, as far as i read thru the documentations.. it should work as well.

sorry.. you are rigth.. new thread.

Comment by Andy Payne on November 22, 2012 at 5:10pm

No.  Unfortunately, I haven't tried that particular driver.  But as far as I know, it should work with the Firefly Quad Stepper sketch.  Are you still having difficulty?  BTW, it might be best to start an actual discussion thread (above) instead of on the general message board... that way we can track the entire conversation.

Comment by philipp hornung on November 22, 2012 at 5:07pm

andy,

btw.. do you got experience with the polulu stepper driver? ;)

Comment by philipp hornung on November 22, 2012 at 4:59pm

hi andy,

great.. now it seems to work!

..and the upload worked too! thanks mate! :)

but unfortunately my setup is still not working.. wondering why...

have to check the polarity of the steppers... hmm..

but thank you so far andy!

will post something if i manage to get it workin..

best

philipp

Comment by Andy Payne on November 22, 2012 at 3:40pm

Hi Phillip,

No, I do not think it has anything to do with the Code Generator (in your last image).  The code generator is unnecessary unless you want the arduino to run autonomously (and not connected to your computer).  As long as your board is connected to the computer via a USB cable, then we can send serial information back and forth.... so we can just use Firefly natively through Grasshopper.

I think the main issue is uploading the code onto your board.  Nothing will work properly if the Quad Stepper sketch isn't loaded onto your board.  In looking at the screenshots you've posted, it looks like all of the Firefly sketches (including the Firefly Firmata, Quad Stepper Sketch, and Wii Sketch) are located in your libraries folder.  However, these should be placed in the root Arduino folder (in MyDocuments/Arduino)... not inside the libraries folder.  You still need the libraries folder there, and in that folder should be the Accel Stepper library... but the Firefly sketches should be placed in the root sketchbook folder.  I'm not exactly sure if this is what's causing the issue... but when you open the Quad Stepper sketch, you shouldn't see the other tabs (AccelStepper and FireflyFirmata) like it does in the original screenshot you posted.  I think it's trying to load these sketches as well, and causing a conflict.  Try the suggestion above and let me know if that fixes your problem.

HTH,

Andy

Comment by philipp hornung on November 22, 2012 at 1:49pm

..thats outlined while trying to run firefly's quadstepper definition:..any clue?

thank you!

Comment by philipp hornung on November 22, 2012 at 1:23pm

hi andy,

thank you for your quick reply!

yes, i had installed the accelstepperlib..

what else could it be.. any idea?

thank you

 

Members (316)

 
 
 

Translate

Search Grasshopper

Photos

  • Add Photos
  • View All

© 2013   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service