Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: EthernetInterface IrcBot mbed-rtos mbed
Revision 2:23c9ee69c999, committed 2015-01-17
- Comitter:
- deton
- Date:
- Sat Jan 17 05:20:55 2015 +0000
- Parent:
- 1:ea78e4c80750
- Commit message:
- Join channel.
;
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Thu Oct 02 11:32:02 2014 +0000 +++ b/main.cpp Sat Jan 17 05:20:55 2015 +0000 @@ -2,11 +2,12 @@ #include "EthernetInterface.h" #include "IrcBot.h" -#define NICKNAME "detonPHS" +#define NICKNAME "[PHSdeto]" //#define IRCSERVER "192.168.0.2" #define IRCSERVER "10.254.166.45" -#define RINGNOTIFYCMD "PRIVMSG deton :@deton RING" -#define DEADTIME 10 // [sec] +#define CHANNEL "#splab" +#define RINGNOTIFYCMD "PRIVMSG " CHANNEL " :@deton RING" +#define DEADTIME 20 // [sec] Serial pc(USBTX, USBRX); // tx, rx AnalogIn ain(p17); @@ -16,7 +17,7 @@ EthernetInterface eth; eth.init(); //Use DHCP eth.connect(); - IrcBot irc(NICKNAME, IRCSERVER, 6667, NULL); + IrcBot irc(NICKNAME, IRCSERVER, 6667, CHANNEL); irc.connect(); set_time(1408859241); // need for time(NULL), otherwise time(NULL) returns -1 time_t prevOnTime = 0;