Loading Items

About This Project

Here is a tutorial on accessing the ADC on the pycom board.
Request Access

Project Info

Skills

  • Micro Python
  • Wiring
  • Overall

Meet The Makers

Join Team
  • xjoexripx
    • User:xjoexripx
    • Rank:Master
    • Projects:31
    • Joined:2016
    • From:US
  • James
    • User:James
    • Rank:Master
    • Projects:30
    • Joined:2016
    • From:US
    Interests: Systems Architect. Love making robots and systems with moving parts.

No Comments yet. Why don't you add one?


.Connecting to the Pycom

In order to connect to the Pycom you can follow our guide here
Pycom Hello World

Pycom Hello World

  • 1962
  • Makes: 0
  • Watchers: 0
  • Rating:
  • Difficulty:
xjoexripx
  • User:xjoexripx
  • Rank:Master
  • Projects:31
  • Joined:2016
  • From:US
James
  • User:James
  • Rank:Master
  • Projects:30
  • Joined:2016
  • From:US
Interests: Systems Architect. Love making robots and systems with moving parts.
Sydney_Adair
Riley.Purvis
  • User:Riley.Purvis
  • Rank:Master Apprentice
  • Projects:12
  • Joined:2017
  • From:US
alexswym
  • User:alexswym
  • Rank:Master Apprentice
  • Projects:14
  • Joined:2017
  • Status:Work In Progress
  • Published:October 19, 2017
  • Est. Time:0 Hours
Overview: In this project we will be lighting the rgb led on the pycom different colors.

.Programming the Pycom



import machine
import time

adc = machine.ADC()
apin = adc.channel(pin='P16')

while True:
val = apin()
time.sleep(1)
print(val)

Reading Pycom Data
After flashing code to the Pycom readings will start appearing roughly every second. The readings are based on the voltage on pin 16 of the Pycom. If no voltage or ground is currently connected to pin 16, random values will appear.

You can test the ADC values by connecting a resistor from Vin to pin16, like so

If working properly, you will most likely see a value of 4095 as this is reading directly from Vin.


You have now successfully used the ADC feature of the Pycom!

There are no project files yet.

Qty   Item Where to Find Est. Cost More Info
1 Pycom WiPy 2.0 Item Number: C1015

Pycom WiPy 2.0

Item #: C1015

Powerful CPU, BLE and sta

$29.95