🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Color Sensor UiFlow or micropython code

    Scheduled Pinned Locked Moved PRODUCTS
    3 Posts 2 Posters 9.8k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D Offline
      devros
      last edited by

      hello, just purchased Color Sensor module and want to use in micropython (or inflow)
      on wiki page wiki can't find code or info ...
      Anyone get this working ?

      thanks

      lukasmaximusL 1 Reply Last reply Reply Quote 0
      • lukasmaximusL Offline
        lukasmaximus @devros
        last edited by

        @devros Hi there, my apologies that we haven't got around to adding the colour sensor functionality in uiflow yet we only have examples for programming it with [arduino].(https://github.com/m5stack/M5Stack/tree/master/examples/Unit/Color) However there is a micropython library for this sensor which you can find here and some examples and documentation here . If you don't know how to get the library on to your m5stack follow this tutorial

        Hope this helps, let us know how you get on.

        Luke

        1 Reply Last reply Reply Quote 0
        • D Offline
          devros
          last edited by

          thanks it works great used this library
          and this basic code to test
          import tcs34725
          import time
          from machine import I2C, Pin
          i2c = I2C(0, sda=21, scl=22)
          sensor = tcs34725.TCS34725(i2c)
          print(sensor.read(True))

          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post