Renumber Cue Lists

My Tech numbered his cue list 1, 2, 3, .......100 etc!

We know we can intersperse new cues with decimals (eg. 1.5, 1.5.5 etc) values but I think I read a while back that ETC were looking for a way to be able to renumber such a list to say, 10,20,30 . . . 1000. Is this still on the books somewhere?

Way back in the dim past I remember being able to do this to long gone computer programs (Fortran BASIC) that used line numbers.

Parents
  • This code solves the problem. If you don't have a Python environment, just download Blender and run it from its text editor. Will work. 

    Only works on whole number cues, let me know if you want decimal cues too.

    import time
    import socket
    
    OSC_IP_ADDRESS = "192.168.1.9"
    OSC_PORT = 8000
    
    
    def send_udp(osc_addr, addr, port, string):
        def pad(data):
            return data + b"\0" * (4 - (len(data) % 4 or 4))
    
        if not osc_addr.startswith("/"):
            osc_addr = "/" + osc_addr
    
        osc_addr = osc_addr.encode() + b"\0"
        string = string.encode() + b"\0"
        tag = ",s".encode()
    
        message = b"".join(map(pad, (osc_addr, tag, string)))
        try:
            sock.sendto(message, (addr, port))
    
        except Exception:
            import traceback
            traceback.print_exc()
    
    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
    
    
    def lighting_command(command):
        send_udp("eos/newcmd", OSC_IP_ADDRESS, OSC_PORT, command)
    
    
    def expand_integer_cues(current_cue_list, new_cue_list, start_cue, end_cue, factor):
        for i in range(start_cue, end_cue):
            lighting_command(f"Cue {current_cue_list} / {i} Copy_To Cue {new_cue_list} / {i*factor} Enter Enter")
            time.sleep(.3) # Give Eos time to keep up
            
            
    expand_integer_cues(1, 2, 1, 100, 10)

Reply
  • This code solves the problem. If you don't have a Python environment, just download Blender and run it from its text editor. Will work. 

    Only works on whole number cues, let me know if you want decimal cues too.

    import time
    import socket
    
    OSC_IP_ADDRESS = "192.168.1.9"
    OSC_PORT = 8000
    
    
    def send_udp(osc_addr, addr, port, string):
        def pad(data):
            return data + b"\0" * (4 - (len(data) % 4 or 4))
    
        if not osc_addr.startswith("/"):
            osc_addr = "/" + osc_addr
    
        osc_addr = osc_addr.encode() + b"\0"
        string = string.encode() + b"\0"
        tag = ",s".encode()
    
        message = b"".join(map(pad, (osc_addr, tag, string)))
        try:
            sock.sendto(message, (addr, port))
    
        except Exception:
            import traceback
            traceback.print_exc()
    
    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
    
    
    def lighting_command(command):
        send_udp("eos/newcmd", OSC_IP_ADDRESS, OSC_PORT, command)
    
    
    def expand_integer_cues(current_cue_list, new_cue_list, start_cue, end_cue, factor):
        for i in range(start_cue, end_cue):
            lighting_command(f"Cue {current_cue_list} / {i} Copy_To Cue {new_cue_list} / {i*factor} Enter Enter")
            time.sleep(.3) # Give Eos time to keep up
            
            
    expand_integer_cues(1, 2, 1, 100, 10)

Children
No Data
Related