🤖Have you ever tried Chat.M5Stack.com before asking??😎

Subcategories

  • Lessons and Guides for Uiflow

    125 Topics
    434 Posts
    A
    Hi, I'm a new user of M5stack products, having got an M5StickC Plus2 recently. It's a nice device, but the documentation isn't always accurate which makes learning how to use it a slow process. I tried to use the example for drawing a raw buffer to the screen here But it resulted in different garbled output each time and not a green rectangle. It seems that the len parameter is expecting 16-bit entries in the buffer so needs to be halved. Here's the code that works on my device (note the //2 for len parameter): width, height = 40, 30 green565 = 0x07E0 raw_buf = bytearray(width * height * 2) for i in range(width * height): raw_buf[2*i] = (green565 >> 8) & 0xFF raw_buf[2*i+1] = green565 & 0xFF Display.drawRawBuf(raw_buf, 100, 100, width, height, len(raw_buf)//2, swap=False) Hopefully this will help others and eventually get changed in the docs - assuming it's the same for all UIFlow2 supported devices? If anybody knows a fix to make it work properly for lower than 16bit depth screens so I can draw a raw buffer to a 1-bit canvas properly, please let me know!
  • 212 Topics
    790 Posts
    Y
    Hello I faced problem about digi-clock write charcter block. Problem is 3rd and 4th digit can not display with this block. I created below flow. Then Digi-Clock displays "0.1.:" for 1st and 2nd digit and colon. [image: 1778319992199-1aae8860-52c1-4c60-9097-5668ed98e2ee-image.jpeg] Howerver, index of write character block can be set only 0 to 4. Therefore it could not display 3rd and 4th digit. I think this index shoud be set 0 to 8. It doesn't work if index forced set to 5 to 8. (It was same behavior as 0 if index is set to 5.) I think the index for DigiClockUnit.set_char should be 0–8, not 0–4. https://uiflow-micropython.readthedocs.io/en/latest/unit/digi_clock.html Could you please kindly consider to fix this issue? (Or let me know please if any other solution available.) #Write raw data and write string blocks are works correctly. Using device -AtomS3 lite -Digi-clock UIFlow version:2.4.4 FW version:2.2.5 OS:Windows11 Thank you in advance Best Regards Yamada
  • 11 Topics
    33 Posts
    A
    @jeanfabre On web, just choice block type. [image: 1729260517944-86b7a25c93207d9a32e5b33471bb1f0.png] For code, add return description like this: def func(self) -> int: return 0
  • UIFlow - Where is the Firmware?

    7
    0 Votes
    7 Posts
    15k Views
    L
    @lukasmaximus Hi. I just replayed the first video you mentioned and yes this is very helpful. You clearly state in this video how I can find the additional modules I need to add to the basic micropython to support the M5Stick. I much prefer to program at the low level python level rather than use something like UIFlow. Thanks again for your help.
  • Ui Flow upload made persistent?

    10
    1 Votes
    10 Posts
    23k Views
    R
    I use uPyCraft to load/write files. There is another graphics editors like Mu or Tonny
  • UIFlow Desktop can't connect to M5Stick

    3
    0 Votes
    3 Posts
    8k Views
    lukasmaximusL
    Check out this video I did a while back on using M5Stack devices on linux https://www.youtube.com/watch?v=ZZdTl0400uM you need to make sure to add the device to the dialout group, I can't remember the exact line of code but it's in the video if you watch it
  • IMU Get ACC reports gyro

    3
    0 Votes
    3 Posts
    6k Views
    ajb2k3A
    it could be that the gyro is in Gravities which would explain the low reading. I was watching a vid and normally the readings shoud be in miligravities.
  • How to make M5StickC go into light sleep?

    5
    -1 Votes
    5 Posts
    10k Views
    J
    @m5stack Did a quick machine.deepsleep(10000) test and it seems to work! Will add more code to see how this extends battery life. Thanks!
  • Subscribing to MQTT doesn't work

    8
    2
    0 Votes
    8 Posts
    12k Views
    world101W
    @lederschnautz Great. Glad I could help.
  • UI flow - connexion problem usb port

    6
    0 Votes
    6 Posts
    8k Views
    ajb2k3A
    @bww1340 Repost this one in the official updates forum under the 1.5.1 (or which ever version you are struggling with.)
  • UIFlow Desktop on MacOS mojave 10.14.5 cannot connect to Faces Dev Kit

    10
    3
    0 Votes
    10 Posts
    14k Views
    indrajaalI
    @lukasmaximus thanks for verifying that my setup is correct. Will check out the urequests video as well. Fortunately, USB mode is working for me, so, for now, I'll just use that to play around with my Faces dev kit. Thanks y'all for the help 🙏🏽
  • Custom Hostname

    1
    0 Votes
    1 Posts
    4k Views
    No one has replied
  • Resource Manager cant Load blocklys

    2
    0 Votes
    2 Posts
    4k Views
    X
    @xis After some attempts it worked.
  • UIFlow and unit grove ultrasonic distance sensor

    7
    0 Votes
    7 Posts
    15k Views
    S
    Thank you.You re right, i send that post after i tried that module. That HCSR-04 module isn't for Grove, it use 4 pins (VCC, ground, trigger pin, echo pin) . It works very well but.. This is my project : i have a mini-robot made with arduino (Uno, motor shield, ultrasonic sensor, servo) and i want to make it again in M5Stack and micropython context. So i bought the GOPlus element that provides controls for 4 servos connexions, 2 independant motors, 3 more grove ports. The problem is : when i use at the same time 1 servo and the basic 4 pins Ultrasonic function, the Echo Pin creates an ERROR on the M5Stack . That s why i wanted to try the grove Ultrasonic. But it s using only 1 pin for trigger and echo.
  • 0 Votes
    3 Posts
    7k Views
    S
    This worked well for me with pin 21 (trigger) and pin 22 (echo) https://github.com/rsc1975/micropython-hcsr04
  • UiFlow needs https

    3
    2 Votes
    3 Posts
    6k Views
    world101W
    @m5stack Thank you!
  • text formatting

    4
    0 Votes
    4 Posts
    7k Views
    R
    @fonzies83 try this commands [image: 1587847760098-img_20200425_224437444_hdr-2-resized.jpg]
  • UIFLOW Measure input pulse

    3
    0 Votes
    3 Posts
    6k Views
    lukasmaximusL
    @PhilG1300 the latest Uiflow firmware 1.5.0 is based on micropython v1.12 which introduced a new feature called RMT, https://docs.micropython.org/en/latest/library/esp32.html#rmt it supposedly can generate and receive pulses as low as 12.5ns, I haven't experimented much with this library, but it may serve your purpose. To use those micropython commands you could just paste them into an execute block in your code
  • UIFlow basics, few beginner questions

    6
    0 Votes
    6 Posts
    10k Views
    S
    I don't know why but, now i have the SD card items in Advanced Menu. May be because i plugged once a SD card ? The white cross icon to add UNITS is here too. I ve notice that : when modification is done with Blocky and i save the file : the saved file is OK, when the same modification is done with micropython : the file can't be saved. As if the micropython screen wasn't really a part of the UIflow. Related to the issue n°4 above ??
  • Ui Flow support for onewire and ds18x20

    26
    0 Votes
    26 Posts
    98k Views
    K
    U mnie działa bardzo dobrze. Dzięki
  • Combining files?

    6
    0 Votes
    6 Posts
    11k Views
    C
    @dclaar I'm using 2 techniques: Use Notepad++ as an editor. If you name your program *.py, it will highlite the code as in Blockly/Python. You can then copy and paste the code into UIflow (but you cant save them there). So if the code works, I copy and paste the code back into Notepad++ and save it as a *.py file. Using the standard editor programming ESP32 and ESP8266 in microphyton: yPyCraft or Thonny (https://randomnerdtutorials.com/getting-started-micropython-esp32-esp8266/). The UIFlow Python editor probably is a clone of one of these. With these editors you can even do a simple code/syntax check, then copy and paste back and forth as I described with Notepad++.
  • This topic is deleted!

    2
    0 Votes
    2 Posts
    1 Views
    No one has replied
  • M5StickC HAT PIN control in UIFlow

    6
    0 Votes
    6 Posts
    11k Views
    world101W
    Unless I’m not understanding it correctly, according to the docs, you would select a pinX from the drop down list and type the pin number (ex: 26) into the Init pin block. Then you can get or set the pin via the other blocks. As far as pin0 through pin5, those seems to be a designator for the pin you are controlling. BAT = battery