Forums > MaxMSP

How can I close a serial port in MAX?


Mar 19 2008 | 1:50 am

If I understand correctly, the serial object opens the specified port (if available) as soon as the patch containing it starts running. Is there any way to close or disconnect the object’s connection to a port other than closing the whole patch?

Mar 19 2008 | 9:13 am

On 19 mars 08, at 02:50, Chris Vecchio wrote:

>
> If I understand correctly, the serial object opens the specified
> port (if available) as soon as the patch containing it starts
> running. Is there any way to close or disconnect the object’s
> connection to a port other than closing the whole patch?

I’m afraid [serial] doesn’t understand any close message, but jasch
ported Pure Data’s [comport] object, which can close a serial port.
-> http://www.jasch.chl/dl/jasch_objects_beta/comport_UB_20070508.zip

p

_____________________________
Patrick Delges

Centre de Recherches et de Formation Musicales de Wallonie asbl
http://www.crfmw.be/max

Mar 19 2008 | 10:22 am

i ported [comport] specifically because of the infamous hang on close
bug when using the arduino-board/editor etc.

the correct URL is:

http://www.jasch.ch/dl/jasch_objects_beta/comport_UB_20070508.zip

you can ‘sort of’ close a port with [serial] by selecting a different
‘built in’ port like for example "Bluetooth-Modem" (at least on my
system – send the message "print" to [serial] to see available ports).

hth

/*j

>> If I understand correctly, the serial object opens the specified
>> port (if available) as soon as the patch containing it starts
>> running. Is there any way to close or disconnect the object’s
>> connection to a port other than closing the whole patch?
>
> I’m afraid [serial] doesn’t understand any close message, but jasch
> ported Pure Data’s [comport] object, which can close a serial port.

Mar 19 2008 | 5:38 pm

Thanks alot for the help.
Redirecting to another port is a clever work-around.
At least it will let my students bounce back and forth between programming a Basic Stamp and receiving data from it during development.

– Chris
http://www.noisemantra.com

Mar 20 2008 | 2:50 am

For what it’s worth, serial in Max 5 will offer a ‘close’ message.

Jeremy

Viewing 5 posts - 1 through 5 (of 5 total)

Forums > MaxMSP