BrightLedSigns / LedSign

Perl API to control programmable LED signs
9 stars 3 forks source link

Added the header to the beginning of the message #7

Open mik3rgit opened 7 years ago

mik3rgit commented 7 years ago

The header wasn't being sent to the device which was causing effects and possibly other options to not function properly.

mik3rgit commented 7 years ago

This addresses issue #6

budgetneon commented 7 years ago

I don't think this is the right fix. The header subroutine is left over from LedSign::BB, which is a completely different sign from a different manufacturer. That's also why, for example, the date/time tags had the wrong documentation...I started with the other code I did as a template. The header subroutine should actually be deleted.

See here: https://github.com/BrightLedSigns/LedSign/blob/master/lib/LedSign/BB.pm#L491

So, I do believe it's making something work for you, but only as a side effect. Something else is wrong. The messages for an m500 shouldn't have that header. They should start with ~128

So, I'm not going to bring in this pull request, because it's fixing something the wrong way...sending characters to the sign that it likely doesn't know what to do with.

budgetneon commented 7 years ago

If you want to compare, there's another piece of code that talks to M500 signs here: http://www.avbrand.com/projects/carpc/ledsign/technew.asp

mik3rgit commented 7 years ago

I used the following spec to look at the header: https://brightledsigns.com/downloads/Moving_Sign_Protocol_V2_1.pdf

Do you have another spec for how this device operates? Without this header I was unable to send any kind of effects to the device, so if this doesn't use the same protocol as linked above, it's a strange coincidence that it now works for me.

budgetneon commented 7 years ago

That spec is not for an M500 sign. The spec is for a BB sign. They look very similar though.

There is no published spec for the M500 signs. I had to reverse engineer it with a serial analyzer.

As mentioned above, another person did something similar for M500 signs, here: http://www.avbrand.com/projects/carpc/ledsign/technew.asp

Maybe you have a BB sign? They look similar.

budgetneon commented 7 years ago

You should try the LedSign::BB module if that header made things work for you...