Code Monkey home page Code Monkey logo

ofxdmx's People

Contributors

danomatika avatar danzeeeman avatar evsc avatar kylemcdonald avatar smallfly 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ofxdmx's Issues

OF 0.10.1 "Unknown type name 'string'"

Hi :)

I use ofxDMX a lot and it works beautifully.

But when trying to compile it in OF 0.10.1 I get a bunch of compile errors like this:

/Applications/of_v0.10.1_osx_release/addons/ofxDmx/src/ofxDmx.h:16:18: Unknown type name 'string'; did you mean 'std::string'?
/Applications/of_v0.10.1_osx_release/addons/ofxDmx/src/ofxDmx.h:31:2: Unknown type name 'vector'; did you mean 'std::vector'?

adding std:: does solve it.
is that now needed in OF 0.10.x ?

screen shot 2019-01-16 at 2 11 04 pm

suggested change on how to connect to device

Hey Kyle.

Sometimes I don't want to connected to a specific indexed device, nor know the exact name.
So, I changed the code a bit to look for a partial name match.

dmx.connect("serial-EN", 512 );

maybe you think it makes sense to include it.

bool ofxDmx::connect(std::string device, unsigned int channels) {
     vector<ofSerialDeviceInfo> serialDevices = serial.getDeviceList();
    
     string deviceLine;
     for(int i=0; i<serialDevices.size();i++){
         deviceLine = serialDevices[i].getDeviceName().c_str();
         
         if(ofIsStringInString(deviceLine, device)){
             connected = serial.setup(deviceLine.c_str(), 57600);
             setChannels(channels);
             return connected;
         }
     }
    
}

bug in example-controller causing channel jump

I think there is a bug in example-controller at line 47 causing to jump over every 3th channel. Its one channel++ too much...
This:

	for(int module = 1; module <= modules; module++) {
        dmx.setLevel(channel++, red[module]*255);
		dmx.setLevel(channel++, green[module]*255);
		dmx.setLevel(channel++, blue[module]*255);
		channel++;
	}

should be

	for(int module = 1; module <= modules; module++) {
        dmx.setLevel(channel++, red[module]*255);
		dmx.setLevel(channel++, green[module]*255);
		dmx.setLevel(channel++, blue[module]*255);
	}

examples not running on latest XCode / MacOS with OF 0.9.3

When running the examples on OSX 10.11 with XCode 7.2 with OF 0.9.3 I'm noticing several issues when running the examples. For instance "The run destination My Mac is not valid for Running the scheme 'ofxDmxExample'." The example-controller has several more, including issues with "AssertMacros.h". Is it possible to update them? Thanks!

Flickering when using multiple channels

Just wanted to report that I've had some issues with the ofxDMX addon recently.

I've been using this device together with an Enttec DMX Usb Pro:
http://www.enttec.com/?main_menu=Products&pn=71003

The issue I had was occasional weird flickering when I was sending different data to each channel. I had no visual glitches when sending the same data to all four channels (testing with a sinusoidal signal).

I looked at the code but couldn't find any obvious bugs. I then swapped to ofxGenericDmx and my problems were gone.

I think it could be the serial driver vs FTDI driver....not sure really, but thought I'd flag it in case anyone else has had problems. This was on Ubuntu 12.10, 64 bit.

Also posted this here:
http://forum.openframeworks.cc/index.php/topic,7277.new/topicseen.html

low framerate

I'm using the addon together with Enttec Dmx USB Pro and having low framerate (about two updates per second only) using only 6 channels.
The same setup runs nice with other applications.

here is the relevant part of the test code. Thanks

//--------------------------------------------------------------
void ofApp::setup(){
    //  dmx.connect("tty.usbserial-EN077864", 6*3);
    dmx.connect("cu.usbserial-EN077864", 6*3);

}

//--------------------------------------------------------------
void ofApp::update(){
    for (int a=0; a<6; a++) {
        int gray = ofNoise(ofGetFrameNum()/10.0f)*255.0;
        float qual = a/(float)6.0;
        float r = gray;
        float g = gray;
        float b = gray;
        dmx.setLevel(a*3 + 1, b);
        dmx.setLevel(a*3 + 2, g);
        dmx.setLevel(a*3 + 3, r);
    }
    //  if(dmx.isConnected()) {
    dmx.update();

    //  }
}

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.