If I'm understanding you correctly, you want to design an interface in Max that will allow you to remotely control the mixer and transport in Pro Tools, correct? So my suggestion was, in general, to choose a MIDI control surface you want to emulate (such as MotorMix or Mackie) and then send/receive the proper MIDI messages -- either through a MIDI interface if you want your emulator to be on a completely different computer, or via the virtual MIDI ports "from Max 1" and "to Max 1" if your emulator will be on the same computer as Pro Tools.
To be clear, I haven't done it myself, and now that I think about it, trying to emulate the Mackie HUI is not the best choice because Mackie and Digidesign are rather secretive about providing a complete listing of the MIDI messages they use. If you have an actual Mackie HUI in your possession, you could sniff its messages by sending its output directly into Max, but that would be rather time-consuming. A simpler way to go is probably to emulate the MotorMix control surface, because that company readily provides the complete MIDI specification for the MotorMix.
So, first of all, in Max, create a MIDI output object with the output port "from Max 1" specified as an argument, as in [midiout "from Max 1"], and create a MIDI input object such as [midiin "to Max 1"]. Also, to fool Pro Tools into thinking you actually have a MotorMix connected, you'll need to respond to its "active sensing" ping messages. The DAW sends note 0 with velocity 0 on channel 1, and expects to receive note 0 with velocity 127 on channel 1 in response. So you need to make a little patch that responds appropriately. Like this:
[notein "to Max 1"]
[144 0 127]
[midiout "from Max 1"]
That way, every time Pro Tools sends a ping, your patch will respond, and Pro Tools will be content that it's in touch with a control surface.
If you're interested to see what Pro Tools will send out to the control surface, you could also make a little sniffer like this:
[midiin "to Max 1"]
[capture] or [print]
Then, in ProTools, choose Peripherals... from the Setup menu, click on the tab for MIDI Controllers, choose MotorMix as your first controller, choose "from Max 1" in the Receive From popup menu and "to Max 1" in the Send To popup menu. Click OK.
At this point, if you were to be sniffing the "to Max 1" port, you would see a bunch of MIDI from Pro Tools -- sysex messages and controller messages -- telling the control surface what's going on in Pro Tools, plus a steady stream -- every 500 or 750 ms or so -- of MIDI notes "144 0 0" for active sensing pings. That's why setting up your pinger in advance is so useful: it creates the virtual ports "to Max 1" and "from Max 1" and it gets ready to respond to those pings.
Then you can start sending Pro Tools messages from your virtual "control surface" according to the MIDI specifications of the actual control surface you're trying to emulate. For example, to control fader 1, you'd need to send the message that you have touched fader 1 on the control surface, then start sending fader position messages, which are stated in 512 steps by sending the 0-127 coarse value on controller 0 and the 0-3 fine value (on bits 6 and 7, thus as decimal numbers 0, 32, 64, and 96) on controller 32.
Here's an example:
That much I have actually done and tested, so I know it works. Making an entire virtual control surface is up to you! :)
@DRKOSS I see two flaws in the message you say you're sending to the MotorMix. One is that you have too many commas, so the meaning of your message is now incorrect. The other is that you have changed the last number to 67; it should be 47. The correct message to ctlout would be "1 15, 64 47" to touch fader 2, and "1 15, 0 47" to release it.
Yes, sorry, I "misspoke"; I meant "sending to Pro Tools".
I'll bet almost anything your problem is that you are not changing the control number on which you're sending the fader values. That is, you not only need to touch the correct fader by sending the messages I mentioned in my previous post, you also need to send its values on the correct fader-specific controller numbers. See the revised example below, which I have tested and works for me. In this version, you choose your fader number, touch it, then send it values. (Then release it, choose a new fader, touch it, send it values, release it, etc.)