Revision 5e8f735d
Changed URLs to match actual server
mainbox/main.c | ||
---|---|---|
33 | 33 |
printf(" -d specifies the serial port for Modbus\n"); |
34 | 34 |
printf(" defaults to /dev/ttyUSB0\n"); |
35 | 35 |
printf(" -s specifies the server where the CRM is running\n"); |
36 |
printf(" defaults to minecraft.roboclub.org:8000\n");
|
|
36 |
printf(" defaults to roboticsclub.org\n");
|
|
37 | 37 |
} |
38 | 38 |
|
39 | 39 |
int main(int argc, char **argv) { |
40 | 40 |
int i, opt; |
41 | 41 |
struct sigaction sigact; |
42 | 42 |
const char *device = "/dev/ttyUSB0"; |
43 |
const char *server = "minecraft.roboclub.org:8000";
|
|
43 |
const char *server = "roboticsclub.org";
|
|
44 | 44 |
|
45 | 45 |
while ((opt = getopt(argc, argv, "hd:s:")) != -1) { |
46 | 46 |
switch (opt) { |
mainbox/query.c | ||
---|---|---|
74 | 74 |
if (handle == NULL) |
75 | 75 |
return 0; |
76 | 76 |
|
77 |
sprintf(url, "http://%s/roboauth/%08x/%d/", server, user_id, tool_id); |
|
77 |
sprintf(url, "http://%s/crm/roboauth/%08x/%d/", server, user_id, tool_id);
|
|
78 | 78 |
error_code = curl_easy_setopt(handle, CURLOPT_URL, url); |
79 | 79 |
if (error_code) goto error; |
80 | 80 |
|
... | ... | |
124 | 124 |
struct tm *timeinfo; |
125 | 125 |
long response = 0; |
126 | 126 |
|
127 |
return 0; |
|
128 |
|
|
127 | 129 |
#ifdef DEBUG_EVENT_RESPONSE |
128 | 130 |
FILE *fdebug; |
129 | 131 |
fdebug = fopen("debug.html", "w"); |
... | ... | |
174 | 176 |
CURLFORM_COPYCONTENTS, event->succ? "1" : "0", |
175 | 177 |
CURLFORM_END); |
176 | 178 |
|
177 |
sprintf(buf, "https://%s/add_card_event/", server); |
|
178 |
//sprintf(buf, "http://%s/add_card_event/", server); |
|
179 |
sprintf(buf, "https://%s/crm/add_card_event/", server);
|
|
180 |
//sprintf(buf, "http://%s/crm/add_card_event/", server);
|
|
179 | 181 |
error_code = curl_easy_setopt(handle, CURLOPT_URL, buf); |
180 | 182 |
if (error_code) goto error; |
181 | 183 |
|
Also available in: Unified diff