Robonaut: Difference between revisions

From London Hackspace Wiki
(replacement-services)
 
(37 intermediate revisions by 14 users not shown)
Line 1: Line 1:
'''[http://github.com/RJ/irccat irccat]''' is now running on [[System naming|Babbage]], to help link [[IRC]] to things happening in the space
'''[https://github.com/londonhackspace/irccat IRCCat]''' is running on [[Equipment/Blanton#replacement-services|replacement-services]], to help link [[IRC]] to things happening in the space. The documentation below reflects the refreshed instance on [[Equipment/Blanton#replacement-services|replacement-services]].


It's called '''robonaut'''. If you wish to add commands to it, drop scripts in <code>/usr/share/irccat</code> on Babbage.
== Contributing commands ==


== Starting Robonaut ==
During the migration to [[Equipment/Blanton#replacement-services|replacement-services]] we decided to overhaul the command system to make it more flexible and maintainable. We have introduced '''breaking''' changes, so it is important to upgrade your scripts.
 
=== Persistent commands ===
 
We (the maintainers) of Robonaut maintain a supervised set of persistent commands on [https://github.com/londonhackspace/irccat-commands irccat-commands]. If one wants to add a command to the persistent set of commands, one would need to fork this repository and issue a pull request so we can safeguard the quality of essential and commonly used commands. Each revision will have to go through this process.
 
=== Contributed commands ===
 
Users can create commands for Robonaut in the <code>/opt/irccat/irccat-commands-contrib</code> directory. No guarantee will be provided on the availability of these commands, and if the system needs to be migrated in the future, we will potentially discard the commands in this folder. This would be a great location for temporary and/or fun commands, or to test your own commands before committing them to the main command set.
 
=== Write access ===
 
One of the major changes to Robonaut compared to the old instance running on babbage is that write access to the persistent commands directory is prohibited, and that all data should be written to <code>/opt/irccat/irccat-data</code>. While it would also be possible to write to <code>/opt/irccat/irccat-commands-contrib</code>, this would be a very bad idea since this would prevent you from promoting your command to a persistent command. All commands writing outside of the <code>/opt/irccat/irccat-data</code> will be rejected, as well as commands which don't perform proper input filtering and thus offer an opportunity to write outside this directory.


To start robonaut, from [[babbage]] run the following commands:


$ sudo su
$ screen -dr irccat
$ /home/jonty/irccat/irccat.sh


== Robonaut Commands ==
== Robonaut Commands ==
Line 16: Line 24:


=== Really useful commands ===
=== Really useful commands ===
*acnode - Query current usage of a tool and it's status. Current tools are
** laser - Silvertail A0 lasercutter
** 3in1 - 3 in 1 lathe
** lulzbot - Lulzbot 3d printer
** biolab - BioHacking lab
** tig - Tig welder
*board - Change message on the message board, syntax ?board[ message]. An empty message will clear the board.
*board - Change message on the message board, syntax ?board[ message]. An empty message will clear the board.
*board2 - Changes the message on the [[Project:BigClock|Big Clock]] above the vending machine. Limited to about 5 characters a line. syntax as above.
*board2 - Changes the message on the [[Project:BigClock|Big Clock]] above the front entrance. Limited to about 5 characters a line. syntax as above.
*sixteen - Changes the message on the [[Orange_led_strips|Sixteen Segment display]], n.b. only 6 characters.
*commands - robonaut will PM you a list of all available commands.
*commands - robonaut will PM you a list of all available commands.
*laser - current laser status. To change status ?laser <message>
*laser - current laser status. To change status ?laser <message>
*makerbot - current makerbot status. To change status ?makerbot <message>
*makerbot - current makerbot status. To change status ?makerbot <message>
*subscribers - Current number of paying members of London Hackspace. Useful for updating the topic in the channel.
*subscribers - Current number of paying members of London Hackspace. Useful for updating the topic in the channel.
*netleft - says how much bandiwdth we have left for our internets


=== Not so useful commands ===
=== Not so useful commands ===
Line 29: Line 46:
*babel - Uses Google translate to automatically translate text. Use [from]|[to] before the text to specify language.
*babel - Uses Google translate to automatically translate text. Use [from]|[to] before the text to specify language.
*beacon - a symlink to beacons.
*beacon - a symlink to beacons.
*beacons - Flashes lights within the space to attract attention.
*bikes - Tells you how many Boris bikes are available near the space
*boris - Alias of bikes
*cancer - simply prints hi..., as people who abuse the bot are the cancer that's killing IRC - marked for possible archiving.
*cancer - simply prints hi..., as people who abuse the bot are the cancer that's killing IRC - marked for possible archiving.
*cc - generates credit card numbers that pass the MOD 10 check (Luhn formula). Pass [visa|mastercard|amex] for certain formats.
*cc - generates credit card numbers that pass the MOD 10 check (Luhn formula). Pass [visa|mastercard|amex] for certain formats.
Line 40: Line 60:
*donate - points to github and the source of a donation page, until it's re-added to the members page.
*donate - points to github and the source of a donation page, until it's re-added to the members page.
*echo - simply echos whatever you type after ?echo
*echo - simply echos whatever you type after ?echo
*excuse - gives a programmer excuse for something not working
*fight - followed by two words, or two strings, the two are compared by their google hit count.
*fight - followed by two words, or two strings, the two are compared by their google hit count.
*following - lists how many people are following the group on twitter
*following - lists how many people are following the group on twitter
*ham - gives the date for the next ham radio meeting
*hax - links to the Hacking Is Easy video.
*hax - links to the Hacking Is Easy video.
*hits - uses google to give a hit count to the word or string.
*hits - uses google to give a hit count to the word or string.
Line 62: Line 84:
*members - links to the members page on the wiki.
*members - links to the members page on the wiki.
*meter - provides a reading from the power meter [[Electricity meter]]. Useful ones: ?meter UA and ?meter KW
*meter - provides a reading from the power meter [[Electricity meter]]. Useful ones: ?meter UA and ?meter KW
*ning - shouts MORNING!
*minilathe - echos the status of the mini lathe.
*ning - shouts MORNING! or EVENING! depending on [[Equipment/Landin#Chomsky|Chomsky]]'s time. (also see noon)
*noon - shouts AFTERNOON!
*notify - displays a message on the board within the space.  Will scroll if above 21 characters, and maximum is 162.
*notify - displays a message on the board within the space.  Will scroll if above 21 characters, and maximum is 162.
*phone - gives the telephone number for the space.  If a domain name is passed, attempts (naively) to find its phone number.
*phone - gives the telephone number for the space.  If a domain name is passed, attempts (naively) to find its phone number.
Line 72: Line 96:
*reports - links to the the foundation's monthly reports.
*reports - links to the the foundation's monthly reports.
*rm - Deleting the Internet.
*rm - Deleting the Internet.
*roll - Rolls D&D style dice e.g. ?roll 2D6
*roulette - play some Russian roulette.
*roulette - play some Russian roulette.
*setBoard - see notify.
*setBoard - see notify.
*shutup-dev  
*shutup-dev  
*slamthedoor - just what you'd expect from a slammed door - *BANG*
*slamthedoor - just what you'd expect from a slammed door - *BANG*
*snitch - msgs the user the last 5 ?board commands (with usernames)
*spies - lists how many people are watching the webcams.
*spies - lists how many people are watching the webcams.
*summon-dev
*summon-dev
Line 81: Line 107:
*time - Gives the date and time rather accurately
*time - Gives the date and time rather accurately
*unwatch
*unwatch
*users - Lists who is logged in to babbage
*users - Lists who is logged in to [[Equipment/Landin#Chomsky|Chomsky]]
*vrms
*vrms
*watch
*watch
Line 89: Line 115:
*wiki - Searches the wiki for a particular phrase/page name
*wiki - Searches the wiki for a particular phrase/page name
*workshops - Links to the workshops page on the wiki
*workshops - Links to the workshops page on the wiki
*yarnold - A very special command for a very [[User:Solexious|special person]]
*zork - See https://en.wikipedia.org/wiki/Zork
*tube - gets the London Underground status - PM ?tube list for a list of available lines
*tube - gets the London Underground status - PM ?tube list for a list of available lines
*morning - plays the first few seconds of [http://www.youtube.com/watch?v=PAbwMGZtIsY Edvard Grieg - Morning Mood], and cycles the light through dawny colours, and sets the board to say "Good Morning, hackspace"
*morning - plays the first few seconds of [http://www.youtube.com/watch?v=PAbwMGZtIsY Edvard Grieg - Morning Mood], and cycles the light through dawny colours, and sets the board to say "Good Morning, hackspace"
*patriot - initiates enforced patriotism mode
*patriot - initiates enforced patriotism mode
=== Proposed commands to be implemented soon ===
(work in progress by xk_id)
*last20 - PMs the most recent 20 chatlines (useful when you've just joined the room)
*addquote <quote> - used in PM only, it adds the quote to the wiki list of IRC quotes.
== Administrative Notes ==
To start robonaut, from [[Equipment/Landin#Chomsky|Chomsky]] run the following commands:
# /etc/init.d/irccat start
For some bizzaro reason, irccat requires a TCP connection to localhost (and doesn't time out if it can't establish one), so I've also run this:
$ sudo ip6tables -I INPUT 2 -i lo -j ACCEPT
=== Important Paths ===
* Data directory: <code>/opt/irccat/irccat-data</code>
* Contributed scripts directory: <code>/opt/irccat/irccat-commands-contrib</code>
* Persistent scripts directory: <code>/opt/irccat/irccat-commands</code>
* IRCcat installation directory: <code>/opt/irccat/irccat-bin</code>
[[Category:Reference]]
[[Category:Software]]
[[Category:Infrastructure]]
[[Category:Guides]]

Latest revision as of 00:49, 24 October 2021

IRCCat is running on replacement-services, to help link IRC to things happening in the space. The documentation below reflects the refreshed instance on replacement-services.

Contributing commands

During the migration to replacement-services we decided to overhaul the command system to make it more flexible and maintainable. We have introduced breaking changes, so it is important to upgrade your scripts.

Persistent commands

We (the maintainers) of Robonaut maintain a supervised set of persistent commands on irccat-commands. If one wants to add a command to the persistent set of commands, one would need to fork this repository and issue a pull request so we can safeguard the quality of essential and commonly used commands. Each revision will have to go through this process.

Contributed commands

Users can create commands for Robonaut in the /opt/irccat/irccat-commands-contrib directory. No guarantee will be provided on the availability of these commands, and if the system needs to be migrated in the future, we will potentially discard the commands in this folder. This would be a great location for temporary and/or fun commands, or to test your own commands before committing them to the main command set.

Write access

One of the major changes to Robonaut compared to the old instance running on babbage is that write access to the persistent commands directory is prohibited, and that all data should be written to /opt/irccat/irccat-data. While it would also be possible to write to /opt/irccat/irccat-commands-contrib, this would be a very bad idea since this would prevent you from promoting your command to a persistent command. All commands writing outside of the /opt/irccat/irccat-data will be rejected, as well as commands which don't perform proper input filtering and thus offer an opportunity to write outside this directory.


Robonaut Commands

Robonaut will respond to the commands below either publicly in the irc channel or privately. To get robonaut to respond publicly simply send one of the commands prefixed with a ? e.g. ?beacons. For a private response use /msg e.g. /msg robonaut ?dc

Really useful commands

  • acnode - Query current usage of a tool and it's status. Current tools are
    • laser - Silvertail A0 lasercutter
    • 3in1 - 3 in 1 lathe
    • lulzbot - Lulzbot 3d printer
    • biolab - BioHacking lab
    • tig - Tig welder
  • board - Change message on the message board, syntax ?board[ message]. An empty message will clear the board.
  • board2 - Changes the message on the Big Clock above the front entrance. Limited to about 5 characters a line. syntax as above.
  • sixteen - Changes the message on the Sixteen Segment display, n.b. only 6 characters.
  • commands - robonaut will PM you a list of all available commands.
  • laser - current laser status. To change status ?laser <message>
  • makerbot - current makerbot status. To change status ?makerbot <message>
  • subscribers - Current number of paying members of London Hackspace. Useful for updating the topic in the channel.
  • netleft - says how much bandiwdth we have left for our internets

Not so useful commands

  • 8ball - Will make a decision for you.
  • access - Provides a link to the wiki, with info about how to get there, access and facilities.
  • ampm - Tells you if it's morning or afternoon. Was created when everyone used to say "Morning" whenever they came on IRC.
  • babel - Uses Google translate to automatically translate text. Use [from]|[to] before the text to specify language.
  • beacon - a symlink to beacons.
  • beacons - Flashes lights within the space to attract attention.
  • bikes - Tells you how many Boris bikes are available near the space
  • boris - Alias of bikes
  • cancer - simply prints hi..., as people who abuse the bot are the cancer that's killing IRC - marked for possible archiving.
  • cc - generates credit card numbers that pass the MOD 10 check (Luhn formula). Pass [visa|mastercard|amex] for certain formats.
  • cz - enter a postcode to determine if it's inside the congestion zone
  • coffee - provides a link to a google map of coffee shops in London from http://worldbaristachampionship.com/
  • date - provides the Never Ending September Date
  • daysofar - links to the last 24hrs of webcam feed from the space.
  • dc - gives details of the next dc4420 event.
  • define - pass in a word to get the definition from urbandictionary.com
  • df - gives the available drive space.
  • donate - points to github and the source of a donation page, until it's re-added to the members page.
  • echo - simply echos whatever you type after ?echo
  • excuse - gives a programmer excuse for something not working
  • fight - followed by two words, or two strings, the two are compared by their google hit count.
  • following - lists how many people are following the group on twitter
  • ham - gives the date for the next ham radio meeting
  • hax - links to the Hacking Is Easy video.
  • hits - uses google to give a hit count to the word or string.
  • howmuch - a short text on how much membership costs.
  • info - links to this wiki
  • join - links to the group signup page.
  • journeytoalphacentauri - it's a gamer thing, see http://en.wikipedia.org/wiki/Journey_to_Alpha_Centauri_(In_Real_Time) for more info.
  • kegerator - echos the status of the beer kegerator.
  • keyholders - provides a list of the current keyholders, as listed on the wiki.
  • klingon - gets robonaut to speak "Klingon".
  • last24 - links to the last 24 hours of space webcam activity.
  • lastseen - followed by an irc nickname will give you the time that a person last used their rfid to enter the space.
  • layzor - gives information about the laser cutter.
  • lightsoff - turns the DMX lights off.
  • lightson - turns the DMX lights on and sets the colour using html colour codes.
  • load - gives the cpu load average over the last minute, ideally below 1.00
  • man - prints "You must be kidding".
  • map - followed by a place, gives a link to google maps.
  • meet - gives a link for the weekly meetings page.
  • members - links to the members page on the wiki.
  • meter - provides a reading from the power meter Electricity meter. Useful ones: ?meter UA and ?meter KW
  • minilathe - echos the status of the mini lathe.
  • ning - shouts MORNING! or EVENING! depending on Chomsky's time. (also see noon)
  • noon - shouts AFTERNOON!
  • notify - displays a message on the board within the space. Will scroll if above 21 characters, and maximum is 162.
  • phone - gives the telephone number for the space. If a domain name is passed, attempts (naively) to find its phone number.
  • ping - if robonaut is alive it'll respond with a pong!
  • procexp - links to a download of procexp.exe the MS Windows process explorer.
  • ps - gives the time until the next pub standards meet.
  • quote - links to the quotes page on the wiki.
  • ragelevel - sets the current level of rage in IRC / the space on a traffic light
  • reports - links to the the foundation's monthly reports.
  • rm - Deleting the Internet.
  • roll - Rolls D&D style dice e.g. ?roll 2D6
  • roulette - play some Russian roulette.
  • setBoard - see notify.
  • shutup-dev
  • slamthedoor - just what you'd expect from a slammed door - *BANG*
  • snitch - msgs the user the last 5 ?board commands (with usernames)
  • spies - lists how many people are watching the webcams.
  • summon-dev
  • swap - Links to the wiki page where members have things to swap.
  • time - Gives the date and time rather accurately
  • unwatch
  • users - Lists who is logged in to Chomsky
  • vrms
  • watch
  • waxon - Wax off!
  • where - Provides a link to the wiki, with info about how to get there, access and facilities.
  • who
  • wiki - Searches the wiki for a particular phrase/page name
  • workshops - Links to the workshops page on the wiki
  • yarnold - A very special command for a very special person
  • zork - See https://en.wikipedia.org/wiki/Zork
  • tube - gets the London Underground status - PM ?tube list for a list of available lines
  • morning - plays the first few seconds of Edvard Grieg - Morning Mood, and cycles the light through dawny colours, and sets the board to say "Good Morning, hackspace"
  • patriot - initiates enforced patriotism mode


Proposed commands to be implemented soon

(work in progress by xk_id)

  • last20 - PMs the most recent 20 chatlines (useful when you've just joined the room)
  • addquote <quote> - used in PM only, it adds the quote to the wiki list of IRC quotes.

Administrative Notes

To start robonaut, from Chomsky run the following commands:

# /etc/init.d/irccat start

For some bizzaro reason, irccat requires a TCP connection to localhost (and doesn't time out if it can't establish one), so I've also run this:

$ sudo ip6tables -I INPUT 2 -i lo -j ACCEPT

Important Paths

  • Data directory: /opt/irccat/irccat-data
  • Contributed scripts directory: /opt/irccat/irccat-commands-contrib
  • Persistent scripts directory: /opt/irccat/irccat-commands
  • IRCcat installation directory: /opt/irccat/irccat-bin