Skip to content

Commit

Permalink
Merge pull request #20 from xiangxistu/master
Browse files Browse the repository at this point in the history
[fix] modify ppp macro defined
  • Loading branch information
Lawlieta authored Apr 22, 2020
2 parents 91eb196 + c89bd7d commit 184caf8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions inc/ppp_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#endif

#define PPP_DAIL_CMD "ATD*99#" /* common dailing cmd */
#ifndef USING_PUBLIC_APN
#ifndef PPP_USING_PUBLIC_APN
#define PPP_APN_CMD "AT+CGDCONT=1,\"IP\","PPP_PRIVATE_APN
#else
#ifdef PPP_APN_CMCC
Expand All @@ -46,8 +46,8 @@
#define PPP_DROP_BUF PPP_FRAME_MAX


#define PPP_DEVICE_SW_VERSION "1.1.1"
#define PPP_DEVICE_SW_VERSION_NUM 0x10101
#define PPP_DEVICE_SW_VERSION "1.1.0"
#define PPP_DEVICE_SW_VERSION_NUM 0x10100

enum ppp_trans_type
{
Expand Down
4 changes: 2 additions & 2 deletions src/ppp_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -586,10 +586,10 @@ static rt_err_t ppp_device_open(struct rt_device *device, rt_uint16_t oflag)
ppp_set_usepeerdns(ppp_device->pcb, 1);
LOG_D("ppp_set_usepeerdns has set a dns number.");

#ifdef USING_PRIVATE_APN
#ifdef PPP_USING_PRIVATE_APN
/* set authorize */
#if PAP_SUPPORT
ppp_set_auth(ppp_device->pcb , PPPAUTHTYPE_PAP, PRIVATE_APN_ACCOUNT, PRIVATE_APN_PASSWORD);
ppp_set_auth(ppp_device->pcb , PPPAUTHTYPE_PAP, PPP_PRIVATE_APN_ACCOUNT, PPP_PRIVATE_APN_PASSWORD);
#elif CHAP_SUPPORT
ppp_set_auth(ppp_device->pcb, PPPAUTHTYPE_CHAP, ppp_device->config.user_name, ppp_device->config.user_name);
#else
Expand Down

0 comments on commit 184caf8

Please sign in to comment.