How to convert list from "pads" object in LEMUR to "matrixctrl" format in M4L ?

all's icon

Hello

Can you help me about "matrixctrl" object in M4L.

I use jazzmutant's lemur with M4L.
I would like tu use lemur object "Pads" with 8 col and 8 row (like a
monome 64 : 8 x 8).
In short, I would like to use this "Pads" object like a monome 64.

However, monome send x, y and value. Very easy for "matrixctrl"
object in M4L (my purpose is to use "matrixctrl" object in M4L for my
futures lemur programings). I have write some programs for monome
that work fine.
But "Pads" object from lemur in 8 x 8 form send a list : 0 1 2 3
4....63 (from left to right and from top to bottom).
It's not the same "language".

Do you know how "translate" lemur "language" to matrixctrl object (or
monome 64) "language" : "translate" a list (0 1 2 3 4...63) to x, y,
and value (value +++) ?

Obviously, I have the same problem for the back :
My solution : I obtain list of values from row 0, row 1, row 2....row
7 from matrixctrl object in M4L (with message getrow $1).
I must to add these lists for the lemur : row 0 + row 1 + row 2 + row
3....+ row 7.
I have write a program to add this but the result is not perfect.

Do you know a program to make this (with robustness) ?

In short :

"Pads" object with 8 col and 8 row in lemur (list) ------->
"matrixctrl" object in 4L --------> "Pads" with 8 col and 8 row in lemur

How to get this robust program ?

Thank for yur help
Best regards

Alexandre

Noob4Life's icon

maybe you could take a look at how monemur does it(monome40h is same in communication as monome64):
http://forum.jazzmutant.com/viewtopic.php?t=2174

if you have trouble, you could even ask on the monome forums, user 'bar|none' who created monemur and molamur is a longtime veteran there... perhaps even if you asked nicely(without hijacking it too much) on this thread, he might be able to help you further:
http://post.monome.org/comments.php?DiscussionID=1551&page=1#Item_0

all's icon

Thank for your information
All