lllangxx 发表于 2013-12-28 23:05:01

弱弱的问一下if (millis() > timer) {
    timer = millis() + 5000;
    ether.browseUrl(PSTR("/demo/"), "aphorisms.php", website, response_callback);
}
}有时间有什么限定么?太高太低都不行

sddxwyt 发表于 2014-3-10 16:22:24

tom 发表于 2013-6-30 09:28 static/image/common/back.gif
为什么我总是出现这个结果




不好意思,我也出现了相同的问题。你是怎么解决的最后?

wdb_9955 发表于 2014-3-25 16:02:00

sddxwyt 发表于 2014-3-10 16:22 static/image/common/back.gif
不好意思,我也出现了相同的问题。你是怎么解决的最后?

我也是出现这样的问题, 求大神帮助

顺流逆流 发表于 2014-3-29 21:12:57


为什么我总是出现这个结果


IP:192.168.0.3
GW:192.168.0.1
DNS: 192.168.0.1
DNS failed
SRV: 0.0.0.0

后知后觉 发表于 2014-6-12 11:12:57

顺流逆流 发表于 2014-3-29 21:12 static/image/common/back.gif
为什么我总是出现这个结果




把PROGMEM去掉试试

后知后觉 发表于 2014-6-12 16:52:17

弘毅 发表于 2012-10-9 09:06 static/image/common/back.gif
好贴。。。。

我按照他上面的操作一步步实验了,但是老是出现如下问题,百度无果,想向您请教一下
IP:192.168.0.149
GW:192.168.0.1
DNS: 192.168.0.1
SRV: 217.64.195.207

<<<REQ
HTTP/1.1 406 Not Acceptable
Date: Thu, 12 Jun 2014 08:52:05 GMT
Server: Apache
Vary: Accept-Encoding
Content-Length: 101
Connection: close
Content-Type: text/html; charset=iso-8859-1

Blocked by mod_slotlimit. More information about this error may be available in the server error log.

lbyc106 发表于 2014-6-15 12:44:45

谢谢啦!感谢老师发表.

manyman 发表于 2014-7-11 13:37:14

楼主,我用51移植的enc28j60现在ping通了但是我不知道咋个和自己搭的服务器进行数据交换   而且现在服务器和网卡也还没联通不知道咋个搞了现在服务器需要搭建路由吗

photoliao 发表于 2014-8-6 12:10:57

本帖最后由 photoliao 于 2014-8-6 12:21 编辑

#include <EtherCard.h>
static byte mymac[] = {0x74,0x69,0x69,0x2D,0x30,0x31};
byte Ethernet::buffer;

static uint32_t timer;
char website[] PROGMEM = "www.lucadentella.it";
static void response_callback (byte status, word off, word len) {
Serial.print((const char*) Ethernet::buffer + off + 207);
}

void setup () {

Serial.begin(57600);
Serial.println("");
if (!ether.begin(sizeof Ethernet::buffer, mymac, 10))
      Serial.println( "Failed to access Ethernet controller");
else
      Serial.println("Ethernet controller initialized");

if (!ether.dhcpSetup())
       Serial.println("Failed to get configuration from DHCP");
else
       Serial.println("DHCP configuration done");

ether.printIp("IP:", ether.myip);
ether.printIp("GW:", ether.gwip);
ether.printIp("DNS: ", ether.dnsip);

if (!ether.dnsLookup(website))
    Serial.println("DNS failed");
   
ether.printIp("SRV: ", ether.hisip);
}

void loop() {

ether.packetLoop(ether.packetReceive());
   if (millis() > timer) {
    timer = millis() + 5000;
    Serial.println();
    Serial.print("<<< REQ ");
    ether.browseUrl(PSTR("/demo/"), "aphorisms.php", website, response_callback);
}
}

蘰踄繧鍴灬 发表于 2014-9-7 17:18:41

为啥我的是 DNS failed? 我的是去连接百度的。。。
ether.browseUrl(PSTR(""), "", website, response_callback);这样空着应该没关系的吧?

yhy60 发表于 2014-9-10 10:17:10

本帖最后由 yhy60 于 2014-9-10 12:12 编辑

我出现这样的问题??什么原因?

IP:192.168.1.104
GW:192.168.1.1
DNS: 202.96.104.65
SRV: 115.239.211.110

<<< REQ
<<< REQ
<<< REQ
<<< REQ : 222
Connection: Close
Content-Type: text/html; charset=iso-8859-1



程序好了,网页是联通的,换了一个网站地址,就好了,不过显示的信息各不相同。

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>302 Found</title>
</head><body>
<h1>Found</h1>
<p>The document has moved <a >here</a>.</p>
</body></html>

wbzzx 发表于 2015-7-6 19:20:32

编译的时候出现了错误:variable 'website' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
根据提示在char前加上const就好了

Z-Maker 发表于 2015-7-8 07:58:06

后知后觉 发表于 2014-6-12 11:12 static/image/common/back.gif
把PROGMEM去掉试试

去掉也不行呢

Z-Maker 发表于 2015-7-8 08:17:24

顺流逆流 发表于 2014-3-29 21:12 static/image/common/back.gif
为什么我总是出现这个结果




请问您解决了吗    我也遇到这个问题

Neil·Chen 发表于 2015-7-28 01:35:38

Client Demo

Ethernet controller initialized

Failed to get configuration from DHCP
IP Address:        0.0.0.0
Netmask:        0.0.0.0
Gateway:        0.0.0.0

DNS failed
SRV IP:        0.0.0.0
我是有多头痛。。。
页: 1 2 [3] 4
查看完整版本: 【翻译教程】enc28J60 和 Arduino (3)——作为客户端