Requirements
- Apple PC or MacBook with MacOS
- One free USB type A port and a LAN port
- USB type A to USB type C cable
- Ethernet cable
- Latest firmware
Connecting the Gateway
Make sure the gateway is off.
Connect the USB-C end of the cable to the gateway and the Type-A end to the PC/laptop
Connect the Ethernet cable between the Gateway and the PC/laptop.
Do not power the gateway, leave it off.
Serial Communication Configuration
To be able to interact with the serial console of the gateway you need to open the serial terminal. In this guide, we will use the “screen”.
Open an OS X terminal session by pressing Cmd+Space, type terminal and start it.
List the connected devices ls /dev/cu.*
If there are no other USB serial devices connected the one starting with cu.usbserial* will be the gateway.
To establish a connection, type in screen /dev/cu.usbserial-XXXXX 57600
(Change the XXXXX with your specific USB serial port number.)
The terminal will clear.
Power on the gateway.
If everything is configured correctly, you will see the booting of the gateway with some additional options.
LAN Card Configuration
To be able to send the firmware to the gateway, you need to set the LAN card to a static address.
Go to the Network Preferences of your MAC OS and select the LAN card settings. In this example, it is a USB LAN card.
Change the Configure IPv4 option to Manually.
Change the IP Address to 192.168.1.10 and the Subnet Mask to 255.255.255.0.
Apply the changes by pressing the Apply button.
Downloading the Firmware
Based on the used model, download the latest available firmware:
After downloading, unzip it and rename the WisGateOS_X.Y.Z.bin file to recovery.bin.
Set Up the TFTP
You can use the built-in TFTP server in the MAC OS X. Usually, the server uses the /private/tftpboot folder. Have in mind that by default, the folder is hidden in the finder. To access it, open the finder. Use Cmd+Shift+G and enter /private/ftpboot.
Copy the recovery.bin file from earlier into the tftpboot folder.
Open another terminal and run the following commands:
To start the TFTP server:
sudo launchctl load –F /System/Library/LaunchDaemons/tftp.plist
sudo launchctl start com.apple.tftpd
To set the permissions to the tftpboot folder and the files inside:
sudo chmod 777 /private/tftpboot
sudo chmod 777 /private/tftpboot/*
Flashing the Gateway
Go back to the terminal you used to configure the communication.
Restart the gateway with the reset button.
A dialog will appear in the terminal, press 2 on the keyboard to select the Load system code then write to Flash via TFTP option.
For the next dialog enter the answers below:
- Are you sure? (Y/N) – press Y;
- Input device IP - type 192.168.1.1, then press Enter;
- Input server IP - type 192.168.1.10, then press Enter;
- Input Linux Kernel filename - type recovery.bin, then press Enter.
If everything is ok you should see the firmware transfer and flash. It takes some time to download, flash, and boot. Do not power off or disconnect anything.
When the console output prints Boot done, you are good to go. You should be able to see the Wi-Fi AP and connect to your gateway as usual.
Stopping the TFTP
To stop the TFTP server, type in the terminal:
sudo launchctl unload -F /System/Library/LaunchDaemons/tftp.plist
Updated