User Tools

Site Tools


push_buttons_-_find_and_change_function

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
push_buttons_-_find_and_change_function [2019/05/02 07:17]
ispyisail created
push_buttons_-_find_and_change_function [2019/05/05 02:00]
ispyisail [Edit and Test Function]
Line 9: Line 9:
 WinSCP WinSCP
  
-log into your router with both of these programs, defaults are: +log into your router with both of these programs, the defaults are: 
-hostname: 192.168.1.1 +  hostname: 192.168.1.1 
-port: 22 +  port: 22 
-username: root +  username: root 
-password: yourpassword+  password: yourpassword
  
-In WinSCP make sure you set File Protocol to SCP, and also tell it to remember your password for the session or you will be typing it over and over.+In WinSCP make sure you set File Protocol to **SCP** (Not "SFTP" as is the default) , and also tell it to remember your password for the session or you will be typing it over and over.
  
 ===== Find Button Name ===== ===== Find Button Name =====
  
-Open //gargoyle_button_handler// file to see button functions +Open //gargoyle_button_handler// file to edit and add a line of code to find button name
 <code> <code>
 /etc/rc.button/gargoyle_button_handler /etc/rc.button/gargoyle_button_handler
Line 55: Line 54:
 logread logread
 </code> </code>
 +
 +look for the following phrase
 +<code>
 +Wed May  1 19:23:39 2019 user.notice root: the button was wps and the action was pressed
 +</code>
 +
 +Write this button name down exactly as stated, we will need it soon. 
 +
 +In the example above the TP-Link C7 v2 button is "wps" with action "pressed"
 +
 +===== Edit and Test Function =====
 +Open Config File
 +
 +<code>
 +/etc/config/system
 +</code>
 +
 +<code>
 +..
 +config button 'reset_button'
 +   option button 'New_Button_Name'
 +   option action 'released'
 +   option handler 'logger restore defaults ; /sbin/firstboot -y; reboot ;'
 +   option min '3'
 +   option max '90'
 +..
 +</code>
 +
 +change 'reset' to 'New_Button_Name'
 +
 +you’ll also need a symlink from that button to the Gargoyle button handler like the other buttons
 +
 +<code>
 +ln -s /etc/rc.button/gargoyle_button_handler /etc/rc.button/New_Button_Name
 +</code>
 +
 +Where //New_Button_Name// is your new found button name.
 +
 +
 +
 +
 +
  
  
  
push_buttons_-_find_and_change_function.txt · Last modified: 2019/05/05 02:00 by ispyisail