DMX Input for p2
Mag748
Posts: 268
in Propeller 2
Hello,
I don't see a DMX input object (Is that what they are still called in p2?)
Is it possible to port P1 objects to P2?
Is anyone working on a DMX input for the P2 before I dive into it?
Thanks,
Marcus
Comments
I am. If you're not in a rush I can do it for you. I already have DMX out for the P2. I've been doing DMX in and out on the P1 for a long time.
Hey Jon, thank you!
Speaking of you working on your own, where is your gold mine of quality objects hiding? I see none in the "new" Obex.
Thanks,
Marcus
https://github.com/parallaxinc/propeller/tree/master/libraries/community/p2
Oh yes, I meant for the P1 (since I grabbed a P1 to use for the DMX project)
I don’t see any of the jm_ objects in the p1 repository
Here's a collection of Jon's P1 files.
In case it's not in the archive Jim posted, here's my DMX input for the P1. As you can see, it takes advantage of the both timers in the cog, hence this has to be handled differently in the P2.
Here is Jon's Nuts and Volts article.
Hey JonnyMac,
I'm still trying to get the DMX output on my p1 to work, for some reason I'm at a loss. I'm only able to get 1 single packet to output right after boot up, but then the line just remains high. I can't find an example of using the dmx_out object, so I'm not sure if I'm using it correctly. I've tried (2) different Prop1s and different pins without success. The Serial debugger is working, so I know the prop is ticking along.
I've attached my example if anyone wants to take a look.
I appreciate it.
Thanks,
Marcus
Well... your debug setup seems a bit convoluted; I would start by simplifying that. That attached demo uses an updated version of the driver. A significant change is moving the DMX buffer from the object to the parent so that it can be sized as needed (I frequently do projects with a small universe, and I haven't found any fixture that has a problem with it).
Your first loop writes the level 13 to slots 0 (the start byte) to 255. This is probably confusing your fixture because DMX fixtures expect a start byte of $00. If you meant to write that level to slot 13, you need to reverse the parameters; the first parameter is the slot (1..512, the second is the level 0..255). It even says so in the object documentation.
Hey JonnyMac,
Thanks for the response!
I'm not sure what you mean about the convoluted debug setup. It seems to work well for me, as I've been using that method for a very long time.
I have switched over to using the new version of dmx_tx that you have provided in your previous response. It works! Now it outputs DMX continuously. Unfortunately I was not able to update values with the "write" method. But if I manipulate the buffer directly from my top level object, things seem to work ok.
Thanks again for the help!
-Marcus
Hmmm... I will have a look at that. I tend to do direct buffer manipulation, too, so I may have missed a "gotcha."
A few minutes later...
Well, darn. I looks like I fouled an operator on a beautification pass -- silly me. Could you help me by verifying the attached file? I've got another project on my desk at the moment. Thanks.
Hey @JonnyMac ,
Any update on the jm_dmx_rx project you were (are) working on?
I'm still interested
Thanks,
Marcus
It looks like I finished but didn't do clean-up. I'm at a convention this weekend -- I will have a lot and test when I get back.
Ooh, sounds fun!
When you’re back, let me know if you need any help testing.
Thanks,
Marcus