Update random_data.py
This commit is contained in:
parent
d732c49c9a
commit
bae611bb49
1 changed files with 3 additions and 3 deletions
|
|
@ -12,8 +12,8 @@ import json
|
|||
from Adafruit_IO import Client, Feed, RequestError
|
||||
|
||||
# Set to your Adafruit IO key.
|
||||
ADAFRUIT_IO_USERNAME = 'brubell'
|
||||
ADAFRUIT_IO_KEY = '6ec4b31bd2c54a09be911e0c1909b7ab'
|
||||
ADAFRUIT_IO_USERNAME = 'YOUR_IO_USERNAME'
|
||||
ADAFRUIT_IO_KEY = 'YOUR_IO_KEY'
|
||||
|
||||
# Create an instance of the REST client.
|
||||
aio = Client(ADAFRUIT_IO_USERNAME, ADAFRUIT_IO_KEY)
|
||||
|
|
@ -25,4 +25,4 @@ random_data = aio.receive_random(generator_id)
|
|||
# Parse the API response
|
||||
data = json.dumps(random_data)
|
||||
data = json.loads(data)
|
||||
print('Random Data: {0}'.format(data['value']))
|
||||
print('Random Data: {0}'.format(data['value']))
|
||||
|
|
|
|||
Loading…
Reference in a new issue