GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — python-docs-samples/iot/api-client at master · mbrukman/python-docs-samples

Expand file tree

/

api-client

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
 
 
/

api-client

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
beta-features
beta-features
 
 
end_to_end_example
end_to_end_example
 
 
gcs_file_to_device
gcs_file_to_device
 
 
http_example
http_example
 
 
manager
manager
 
 
mqtt_example
mqtt_example
 
 
scripts
scripts
 
 
README.md
README.md
 
 
generate_keys.sh
generate_keys.sh
 
 

README.md

Outline

Cloud IoT Core Python Samples

Open in Cloud Shell

This folder contains Python samples that demonstrate an overview of the Google Cloud IoT Core platform.

Quickstart

  1. Install the gCloud CLI as described in the Cloud IoT Core documentation.

  2. Create a PubSub topic:

    gcloud beta pubsub topics create projects/my-iot-project/topics/device-events

  3. Add the service account [email protected] with the role Publisher to that PubSub topic from the Cloud Developer Console or by using the helper script in the /scripts folder.

  4. Create a registry:

    gcloud beta iot registries create my-registry
    --project=my-iot-project
    --region=us-central1
    --event-pubsub-topic=projects/my-iot-project/topics/device-events

  5. Use the generate_keys.sh script to generate your signing keys:

    ./generate_keys.sh

  6. Register a device:

    gcloud beta iot devices create my-python-device
    --project=my-iot-project
    --region=us-central1
    --registry=my-registry
    --public-key path=rsa_cert.pem,type=rs256

  7. Connect a sample device using the sample app in the mqtt_example folder.

  8. Learn how to manage devices programatically with the sample app in the manager folder.

You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.