Navigation

    M5Stack Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    1. Home
    2. dclaar
    3. Topics
    D
    • Continue chat with dclaar
    • Start new chat with dclaar
    • Flag Profile
    • Profile
    • Following
    • Followers
    • Blocks
    • Topics
    • Posts
    • Best
    • Groups

    Topics created by dclaar

    • D

      Recent copy of Micropython used?
      Micropython • • dclaar

      1
      1
      Votes
      1
      Posts
      770
      Views

      No one has replied

    • D

      Brightness on m5stickc & core gray?
      Micropython • • dclaar

      2
      0
      Votes
      2
      Posts
      886
      Views

      Hello @dclaar I don't think this has been documented yet - but I could be wrong. But consider this. I have multiple M5Stack (Gray, Basic, Fire) and even with the same brightness setting the actual brightness differs visibly. Thanks Felix
    • D

      How do I access the mic on the m5stickc?
      M5 Stick/StickC • • dclaar

      6
      0
      Votes
      6
      Posts
      2410
      Views

      D

      @robalstona pin 0 is the clock, not ws, according to the sticker on the back. Don't know if that helps.
    • D

      Where is wifi config held redux
      Micropython • • dclaar

      2
      0
      Votes
      2
      Posts
      1765
      Views

      D

      Hmm, OK, get_wifi() works on 1.5.4, so maybe I just guessed wrong back then.
    • D

      Can't talk to atom Mini with rshell
      Micropython • • dclaar

      1
      0
      Votes
      1
      Posts
      1786
      Views

      No one has replied

    • D

      I think I killed my Gray
      M5stack Grey • gray adc • • dclaar

      4
      0
      Votes
      4
      Posts
      3446
      Views

      D

      Thanks, once I got the other computer to see the device (can't flash a device that doesn't show up in device manager), I was able to reflash it. Then I took it back to my laptop, and it still wasn't seeing it. So I switched USB cables, and it did. Then I switched back to the original USB cable, and it worked with that cable again. (Note that I had hooked up a M5StickC via the original USB cable, and it is working fine with that cable now, so the cable isn't bad). Gotta love Microsoft Windows sometimes.
    • D

      What are you using for "real" rs232?
      General • • dclaar

      9
      0
      Votes
      9
      Posts
      7100
      Views

      D

      @keesjan With micropython, port 22 works fine, and as expected: CDS_PIN = 33 TX = 19 RX = 22 As an aside, the idea that the labeling of the pins is "oriental logic" shows an unawareness of the history of rs232 and is a bit insulting. The question of what to label the pins depends on whether the manufacturer thinks of the device as DTE or DCE: StackExchange has a good explanation of the history. In particular: 'some manufacturers try to "help" by effectively labelling their DTE equipment as if it was a piece of DCE. They mark their data input pin as Tx so that user just connects "Tx" from the external device (which, if it's DTE, will be the data output from there) to the pin marked "Tx" on their equipment (which they know is an input). Thereby allowing them to say "just connect Tx on your device to Tx on our equipment". They think they are trying to help, but such labelling often just adds to the confusion.'
    • D

      Displaying Air Quality
      PROJECTS • • dclaar

      2
      0
      Votes
      2
      Posts
      2444
      Views

      Great project
    • D

      When are we going to get new Firmware?
      M5 Stick/StickC • • dclaar

      13
      0
      Votes
      13
      Posts
      8879
      Views

      In the REPL of any program you need to hit ctrl + c to kill any running processes in order to get to a command prompt
    • D

      m5burner gotcha
      SOFTWARE • • dclaar

      6
      0
      Votes
      6
      Posts
      4241
      Views

      Beta version (v2.0.0 for Mac) looks nice. Thanks @m5stack.
    • D

      Where is the WiFi config held?
      Micropython • • dclaar

      9
      1
      Votes
      9
      Posts
      7222
      Views

      D

      Rshell works pretty well, although the newer M5 releases are a lot harder to get into the correct mode, particularly on the atom. Uiflow is micropython: I have often written something in uiflow and then switched to the micropython side to see what the python is for a given uiflow thing. And then I can cut and paste into repl. For long-term debugging (fails once a day or week), I leave the device connected to putty. I have considered adding code that would catch Exception () in the main loop, do a stack trace, and save it into a file so that I don't need it to always be connected, but have never implemented it.
    • D

      Maximum recursion depth?
      Micropython • • dclaar

      7
      0
      Votes
      7
      Posts
      5722
      Views

      D

      As I'm not doing recursion explicitly, there must be something going on behind the scenes. Or I've got an error! Or maybe event-driven isn't clean and somehow keeps calling itself.
    • D

      Running code with ampy or rshell or REPL?
      Micropython • • dclaar

      6
      0
      Votes
      6
      Posts
      6057
      Views

      J

      @ajb2k3 Adding to this: I'm using the pymakr extension to VS Code. It handles selective code upload (only changed ones). Note that pymakr does not handle binary file transfer eg. jpg.
    • D

      isPressed? wasPressed? What's the difference?
      Micropython • • dclaar

      3
      0
      Votes
      3
      Posts
      3840
      Views

      J

      @dclaar isPressed() reflects current state of the button (is it pressed?), and returns a Boolean. wasPressed() is an event trigger you use to execute code when the button is pressed. Sample code below (generated from uiflow) to illustrate. from m5stack import * from m5ui import * from uiflow import * lcd.setRotation(1) setScreenColor(0x111111) isExit = None def buttonB_wasPressed(): global isExit isExit = True pass btnB.wasPressed(buttonB_wasPressed) setScreenColor(0x000000) axp.setLcdBrightness(40) isExit = False while isExit == False: lcd.print((btnA.isPressed()), 3, 0, 0xffffff)
    • D

      OMG, serial console!
      Micropython • • dclaar

      6
      1
      Votes
      6
      Posts
      5314
      Views

      The serial console access is known as REPL. If you didn't know about REPL then it is no wonder that you are surprised.
    • D

      Code only works from Visual Studio
      Micropython • micropython • • dclaar

      8
      0
      Votes
      8
      Posts
      5731
      Views

      D

      Given that I can now see the console, I determined that it throws OSError if the http GET fails. Which is a weird error to throw, but OK. So I put that in my except: clause, and it's humming away!
    • D

      lcd.print disappears with rotate 270 and Y > 104
      Micropython • • dclaar

      8
      0
      Votes
      8
      Posts
      6463
      Views

      D

      I will finally note that lcd.print works fine with lcd.orient(lcd.LANDSCAPE) and lcd.orient(lcd.LANDSCAPE_FLIP)
    • D

      Combining files?
      UIFlow • • dclaar

      6
      0
      Votes
      6
      Posts
      4597
      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++.
    • D

      How does one use Block Maker?
      Custom Blocks • • dclaar

      3
      0
      Votes
      3
      Posts
      3162
      Views

      D

      Thanks! Yeah, one can't scroll down to it: You have to have a display that is big enough (or a resolution high enough) to see it.