# Commands

##### Ports configuration commands  


In terms of ports configuration it is possible to change parameters like: service, baud rate, data bits, parity, stop bits and so on. UART commands are provided below.

- **uart**
    - **uart help**  
        Print the help message.
    - **uart list** List available uarts in the system.  
          
        Example:  
        uart list  
        0: baud: 9600 bits: 8 stop\_bits: 1 parity: none (service console)  
        1: baud: 115200 bits: 8 stop\_bits: 2 parity: odd (covered by cons.)  
        2: baud: 9600 bits: 8 stop\_bits: 1 parity: none  
        3: baud: 1200 bits: 8 stop\_bits: 2 parity: even termination: ON (R-COM)  
        3: baud: 38400 bits: 8 stop\_bits: 2 parity: none termination: OFF
    - **uart PORT\_NUMBER baud BAUD** Set PORT\_NUMBER baudrate to BAUD. BAUD value can be one of the following:  
        2400, 4800, 9600, 14400, 19200, 38400, 57600, 115200.  
          
        Example:  
        uart 1 baud 9600  
          
        WARNING: UART covered by console. Changes will take place after the reset.
    - **uart PORT\_NUMBER bits BITS** Set bit length to BITS. BITS value can be one only 8.  
          
        Example:  
        uart 2 bits 8
    - **uart PORT\_NUMBER stop\_bits STOP\_BITS** Set stop\_bits length to STOP\_BITS. STOP\_BITS value can be only 1 or 2.  
          
        Example:  
        uart 2 stop\_bits 1
    - **uart PORT\_NUMBER parity PARITY** Set uart parity to PARITY. PARITY value can be one of the following: none, odd, even.  
          
        Example:  
        uart 3 parity even
    - **uart PORT\_NUMBER termination STATE**  
        Set uart termination to new STATE. STATE can be only ON or OFF.  
          
        Example:  
        uart 3 termination ON
- **uart\_service**
    - - **uart\_service help**  
            Print the help message.
        - **uart\_service list** List of uarts services status.  
              
            Example:  
            uart\_service list  
            1 state: ON service: Remote COM port: 1504 enc: YES  
            2 state: OFF service: TCP Socket port: 1510  
            3 state: OFF service: UDP Socket port: 1510
        - **uart\_service UART\_NUMBER state STATE**  
            Set UART\_NUMBER state to STATE. STATE value can be only ON or OFF.  
              
            Example:  
            uart\_service 1 state ON
        - **uart\_service UART\_NUMBER service SERVICE** Set UART\_NUMBER service to SERVICE. SERVICE value can be one of the following: Remote COM, TCP Socket, UDP Socket.  
              
            Example:  
            uart\_service 1 service TCP Socket
        - **uart\_service UART\_NUMBER port PORT\_NUMBER** Set UART\_NUMBER port to PORT\_NUMBER. PORT\_NUMBER value can be any in the range: 1-65535.  
              
            Example:  
            uart\_service 1 port 1501
        - **uart\_service UART\_NUMBER enc ENC\_STATE** Set UART\_NUMBER encryption to ENC\_STATE. ENC\_STATE can be only YES or NO.  
              
            Example:  
            uart\_service 1 enc YES  
              
            If ENC\_STATE is YES then it will ask for a new password for encryption.


##### Network settings

The following commands might be helpful to change network settings according to target LAN parameters.

- **ipconfig**
    - **ipconfig addr ADDRESS**  
        Set IP address to ADDRESS.  
          
        Example:  
        ipconfig addr 192.168.0.10
    - **ipconfig mask NETMASK** Set subnet mask to NETMASK (in dot-decimal format).  
          
        Example:  
        ipconfig mask 255.255.255.0
    - **ipconfig mask BIT\_COUNT** Set subnet mask to BIT\_COUNT bits.  
          
        Example:  
        ipconfig mask 24
    - **ipconfig gateway GATEWAY\_IP** Set network gateway to GATEWAY\_IP.  
          
        Example:  
        ipconfig gateway 192.168.0.1
    - **ipconfig dhcp enable/disable** Enable or disable DHCP client.  
          
        Example:  
        ipconfig dhcp enable
    - **ipconfig dns1 ADDRESS** Set primary DNS to ADDRESS, disable getting DNS from DHCP if enabled.  
          
        Example:  
        ipconfig dns1 192.168.100.1
    - **ipconfig dns2 ADDRESS** Set secondary DNS to ADDRESS, disable getting DNS from DHCP if enabled.  
          
        Example:  
        ipconfig dns2 1.1.1.1
- **eth\_mac**
    - **eth\_mac help** Print the help message.
    - **eth\_mac default** Set device’s MAC address to factory-default one.
    - **eth\_mac set MAC\_ADDR** Set device’s MAC address to MAC\_ADDR. Accepts both dash and colon-separated formats.  
          
        Example:  
        eth\_mac set 01-02-03-04-05-06  
          
        Example:  
        eth\_mac set 01:02:03:04:05:06
- **http\_port**
    - **http\_port help** Print the help message.
    - **http\_port PORT\_NUMBER** Set http port to PORT\_NUMBER. A PORT\_NUMBER value must be in range: 1-65535.  
          
        Example:  
        http\_port 80
    - **http\_port status** Print current http port.  
          
        Example:  
        http\_port status  
        A current http port is 80
- **telnet\_port**
    - - **telnet\_port help** Print the help message.
        - **telnet\_port PORT\_NUMBER** Set Telnet port to PORT\_NUMBER. A PORT\_NUMBER value must be in range: 1-65535.  
              
            Example:  
            telnet\_port 23
        - **telnet\_port status** Print current Telnet port.  
              
            Example:  
            telnet\_port status  
            A current telnet port is 23

##### Changing username or password  


To change username or password, use user command. Available commands:

- **user help**  
    Print the help message.
- **user mod\_name USER\_NAME NEW\_NAME**  
    Change the user name to NEW\_NAME. It fails if the name is used by another user.  
      
    Example:  
    user mod\_name admin john
- **user passwd USER\_NAME**  
    Change USER\_NAME's password.  
      
    Example:  
    user passwd admin  
    \*\*\*\*\*\* &lt;- here is entered password, but '\*' appears instead  
      
    Note: Everyone can change the password for themselves.