Bohyun Bang / WIZnetInterface

Dependents:   w7500-paho-mqtt openHAB_mqtt_W7500 kakaoIoTchatbot w7500-RFID-mqtt

Fork of WIZnetInterface by WIZnet

Files at this revision

API Documentation at this revision

Comitter:
Soohwan Kim
Date:
Tue Jun 16 13:00:20 2015 +0900
Parent:
11:b319c1859f9b
Child:
13:ec1c34e9ec45
Commit message:
on debuggin

Changed in this revision

arch/ext/W5500.cpp Show annotated file Show diff for this revision Revisions of this file
arch/ext/W5500.h Show annotated file Show diff for this revision Revisions of this file
--- a/arch/ext/W5500.cpp	Tue Jun 16 12:54:49 2015 +0900
+++ b/arch/ext/W5500.cpp	Tue Jun 16 13:00:20 2015 +0900
@@ -472,8 +472,8 @@
 }
 
 int ethernet_link(void) {
-	
-    return (getPHYCFGR()& 0x01);
+
+	return (WIZnet_Chip::getPHYCFGR()& 0x01);
 }
 
 void ethernet_set_link(int speed, int duplex) {
@@ -483,10 +483,10 @@
 	} else {
 		val = (((speed&0x01)<<1)+ (duplex&0x01))<<3; 
 	}
-   setPHYCFGR(PHYCFGR_RST&(PHYCFGR_OPMD|val));
-   wait(0.2);
-   setPHYCFGR((~PHYCFGR_RST)|(PHYCFGR_OPMD|val));
-   wait(0.2);
+	WIZnet_Chip::setPHYCFGR(PHYCFGR_RST&(PHYCFGR_OPMD|val));
+	wait(0.2);
+	WIZnet_Chip::setPHYCFGR((~PHYCFGR_RST)|(PHYCFGR_OPMD|val));
+	wait(0.2);
 }
 
 #endif
--- a/arch/ext/W5500.h	Tue Jun 16 12:54:49 2015 +0900
+++ b/arch/ext/W5500.h	Tue Jun 16 13:00:20 2015 +0900
@@ -611,7 +611,7 @@
  * @ingroup Common_register_access_function
  * @brief Set @ref PHYCFGR register
  * @param (uint8_t)phycfgr Value to set @ref PHYCFGR register.
- * @sa getPHYCFGR()
+ * @sa setPHYCFGR()
  */
    void setPHYCFGR(uint8_t phycfgr) {
         reg_wr<uint8_t>(PHYCFGR, phycfgr);
@@ -621,7 +621,7 @@
  * @ingroup Common_register_access_function
  * @brief Get @ref PHYCFGR register
  * @return uint8_t. Value of @ref PHYCFGR register.
- * @sa setPHYCFGR()
+ * @sa getPHYCFGR()
  */
     uint8_t getPHYCFGR() {
         return reg_rd<uint8_t>(PHYCFGR);