#!/bin/sh
echo "Setting User Permissions for USB port for EXPEYES: AVR, FT232 and MCP2200"

echo "SYSFS{idVendor}==\"03eb\", SYSFS{idProduct}==\"21ff\", MODE=\"666\"" > /etc/udev/rules.d/99-phoenix.rules
echo "SYSFS{idVendor}==\"0403\", SYSFS{idProduct}==\"6001\", MODE=\"666\"" >> /etc/udev/rules.d/99-phoenix.rules
echo "SYSFS{idVendor}==\"04d8\", SYSFS{idProduct}==\"00df\", MODE=\"666\"" >> /etc/udev/rules.d/99-phoenix.rules

cat /etc/udev/rules.d/99-phoenix.rules
service udev restart
/etc/init.d/udev restart
echo "Reconnect EXEYES on USB Port for permissions to take effect"
