Skip to content

Commit

Permalink
Develop (#18)
Browse files Browse the repository at this point in the history
* Improve debug logging.

* Version bump
  • Loading branch information
vveljko authored and MaxPresman committed Jun 27, 2017
1 parent d3fa0c1 commit 9eeedee
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
6 changes: 4 additions & 2 deletions PubNubDefs.h
Expand Up @@ -485,8 +485,10 @@ inline PubNub_BASE_CLIENT *PubNub::publish(const char *channel, const char *mess
t_start = millis();
/* connect() timeout is about 30s, much lower than our usual
* timeout is. */
if (!client.connect(d_origin, 80)) {
DBGprintln("Connection error");
int rslt = client.connect(d_origin, 80);
if (rslt != 1) {
DBGprint("Connection error ");
DBGprintln(rslt);
client.stop();
return 0;
}
Expand Down
8 changes: 8 additions & 0 deletions README.md
Expand Up @@ -128,6 +128,14 @@ a note about timeouts below.
This is not an officially supported API, it is there mostly for
convinience for people that used it

### Debug logging

To enable debugg logging to the Arduino console, add

#define PUBNUB_DEBUG

before `#include <PubNub.h>`

## Installation

Since version 1.1.1, Pubnub SDK is part of the Arduino Library
Expand Down
2 changes: 1 addition & 1 deletion library.properties
@@ -1,5 +1,5 @@
name=Pubnub
version=2.1.0
version=2.1.1
author=Vladimir Veljkovic <vlada@pubnub.com>
maintainer=Vladimir Veljkovic <vlada@pubnub.com>
sentence=Pubnub SDK for Arduino.
Expand Down

0 comments on commit 9eeedee

Please sign in to comment.