diff --git a/bsp/fh8620/rtconfig.h b/bsp/fh8620/rtconfig.h
index ed31025f93..cefbff053c 100644
--- a/bsp/fh8620/rtconfig.h
+++ b/bsp/fh8620/rtconfig.h
@@ -182,20 +182,11 @@
//
#define RT_LWIP_ETHTHREAD_STACKSIZE 512
//
-#define RT_LWIP_IPADDR0 192
-#define RT_LWIP_IPADDR1 168
-#define RT_LWIP_IPADDR2 1
-#define RT_LWIP_IPADDR3 30
+#define RT_LWIP_IPADDR "192.168.1.30"
//
-#define RT_LWIP_GWADDR0 192
-#define RT_LWIP_GWADDR1 168
-#define RT_LWIP_GWADDR2 1
-#define RT_LWIP_GWADDR3 1
+#define RT_LWIP_GWADDR "192.168.1.1"
//
-#define RT_LWIP_MSKADDR0 255
-#define RT_LWIP_MSKADDR1 255
-#define RT_LWIP_MSKADDR2 255
-#define RT_LWIP_MSKADDR3 0
+#define RT_LWIP_MSKADDR "255.255.255.0"
//
//
diff --git a/components/drivers/wlan/wlan_cmd.c b/components/drivers/wlan/wlan_cmd.c
index 21afd7020a..2ff0db903d 100644
--- a/components/drivers/wlan/wlan_cmd.c
+++ b/components/drivers/wlan/wlan_cmd.c
@@ -404,7 +404,7 @@ int wifi(int argc, char** argv)
wlan = (struct rt_wlan_device*)rt_device_find(argv[1]);
if (!wlan)
{
- rt_kprintf("no wlan:%s device\n");
+ rt_kprintf("no wlan:%s device\n", argv[1]);
return 0;
}
@@ -480,6 +480,7 @@ int wifi(int argc, char** argv)
rt_wlan_info_init(info, WIFI_AP, SECURITY_OPEN, argv[3]);
info->channel = 11;
+ result =rt_wlan_init(wlan, WIFI_AP);
/* start soft ap */
result = rt_wlan_softap(wlan, info, NULL);
}
@@ -489,6 +490,7 @@ int wifi(int argc, char** argv)
rt_wlan_info_init(info, WIFI_AP, SECURITY_WPA2_AES_PSK, argv[3]);
info->channel = 11;
+ result =rt_wlan_init(wlan, WIFI_AP);
/* start soft ap */
result = rt_wlan_softap(wlan, info, argv[4]);
}