"Controlling" the LED on the Pico :)

Just installed Micropython onto it and used the serial REPL interface

2 Likes

Simon, have you tried the MU editor? You can then directly interact with the board using the REPL.
The downside is it will then be Off Topic :slight_smile:

I want to programmtically control the pins.

But until someone ports Firmata to it - then I need some other way of doing it :slight_smile:

I'm using Node-RED to test the concept out - which was very quick to get going :slight_smile: before writing a simple Scratch interface

1 Like

Hi Node-Red fans,
I have an idea with Pico:
Run Node-Red on Pico :blush:
Node-Red produce on save a JSON file.
Import this file in Pico and run it.
The nodes are written in c++ on Pico for better performance.
Or is this a bad idea and Nick is angry when we use the editor for an other runtime ? :angry:
When I finish my ladder logic nodes then I can start with this.

1 Like

So are you going to port nodejs to the Pico?

Why would that make me angry?

In fact, I'm planning something similar to what you describe as it will be an interesting exercise to validate whether we have the right APIs in place for creating more custom runtimes.

Node-RED wouldn't run on the Pico, but I think it would be interesting to create a custom palette of nodes that, when you hit deploy, generates then necessary Python code and then upload to the Pico.

A very similar model would work for existing boards of a similar type, such as those running Espruino or ESP.

My Pico should arrive in the next couple of days. I waited until too late on Thursday for Pimoroni to get it into the first post.

4 Likes

I use the Node-Red editor for generating the JSON file.

There are 4 options:

  1. The runtime is written in C++ and the important nodes are fix built in the c++ runtime.
    Its runs depends on JSON data from Node-Red editor.
  2. The nodes are written in C++ and compiled as binary. A program on Linux or Windows links this node library files to an whole binary Node-Red runtime and transfer it to Pico for example.
  3. The runtime and nodes are written in Python in Pico. The Python runtime reads the JSON file from editor.
  4. Same as option 2 with Python.

I hope, that I can explain my idea with my bad english :blush:

OK, I understand now.

Any progress about that?

I would really like a possibility to:

  • upload a unified code to the pico (like Firmata)
  • Add names to these "extension boards"
  • Add password
  • plug in with a 5m USB cable
  • ... and it would auto-detect + communicate with the "main NR", allowing to easily handle IO / PWM / I2C through those.

That would be my "plug&play IoT dream". :slight_smile:

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.