Mesh on Workbench

Hello,
Super excited to start using my new mesh modules.

Am I missing something or can I not program the mesh units yet with Workbench? All I see for targetPlatform is “photo” “electron”, and “p1”.

I know it was mentioned in another post about creating a Workbench guide. Do we know where that stands? Would sure help me as a new VS Code user.

Thanks for any input.

2 Likes

You can edit the .workspace file to set the firmware version and target platform for now and it will work

Hey Ken,
What do I put as the targetPlatform?

I tried “argon” and “mesh”.

Thanks

I’m on mobile now or I’ll he able to share the snippet.

Maybe simply set the firmwareVersion to 0.8.0-rc.25 and set your target device to your argon device name. Remove the targetPlatform setting mentioned

Updated:

  • edit .code-workspace
  • Set your targetPlatform and targetDevice accordingly
        "particle.targetPlatform": "xenon",
        "particle.firmwareVersion": "0.8.0-rc.25",
        "particle.targetDevice": "DEVICE_NAME_GOES_HERE"
2 Likes

Hi Ken,

I’m struggling with this as well. I have spent hours looking for something that resembles the
.code-workspace within VS. the closest I found were the workspace settings but when I put in

"particle.targetPlatform":"xenon",
"particle.firmwareVersion": "0.8.0-rc.25",
"particle.targetDevice": "DEVICE_NAME_GOES_HERE"

I got an error

{
	"resource": "/c:/Users/roger/Documents/Particle/projects/Aardvark/.vscode/settings.json",
	"owner": "_generated_diagnostic_collection_name_#1",
	"code": "1",
	"severity": 4,
	"message": "Value is not accepted. Valid values: \"photon\", \"electron\", \"p1\".",
	"startLineNumber": 2,
	"startColumn": 32,
	"endLineNumber": 2,
	"endColumn": 39
}

I’m obviously not editing the correct file but I’m lost. I have 20 Borons sitting in my office waiting for me to figure out how to flash my code with my libraries that I can’t seem to upload to the particle Web IDE. I don’t know why they won’t load. And the Boron is not supported by the Dev IDE.

Any help would be awesome. Thanks.

Update:

As usual all I have to do is ask and at least part of the answer is revealed. I was having trouble creating a new project in VS Code. I don’t really understand the work flow so after a few more stabs in the dark I got a project created with the NAME_OF_PROJECT.code-workspace file to show up. I entered the platform and firmware edits and am still getting errors. I’ll take another stab tomorrow.

2 Likes

My Workbench project workspace looks like:

KENMBP:xenon-modbus-slave kennethlimcp$ tree
.
├── README.md
├── project.properties
├── src
│   ├── python-compare.txt
│   └── xenon-modbus-slave.ino
└── xenon-modbus-slave.code-workspace

How does your workspace look like?

Hey Ken,

As usual, your right on the money. Update my workspace like yours replacing xenon with argon and works like a charm.

Now to start figuring out adding libraries in vs code.

Thanks again

How do you create a new workspace? I don’t see any menu item to do that. When I click on the “Create a Project” link in the welcome page, it says to open the folder that will contain your project. What needs to be in this folder, an empty one doesn’t seem to work? Is there a tutorial yet for how to use Workbench?

Do you know if the introduction of Workbench means that Dev is going away?

2 Likes

Not sure if you are part of the preview for Workbench but the getting started is here: Tutorial: Installing the Particle Workbench developer preview

Do you know if the introduction of Workbench means that Dev is going away?

As you guys know, I'm a community member like everyone here so I don't have an official answer.

However, I do know that moving forward, Particle Workbench will be the Desktop tool that will be given a lot of resources VS Particle Dev.

Yeah, I did the installation, but I still don’t know how to create a new project. The post about the features of Workbench says, “You can initialize a new project with the command, Particle: Create New Project. Doing so will open a new a Visual Studio Code Workspace…”. This gives me the same message I mentioned above about opening a folder, so it doesn’t create a new workspace for me.

1 Like

Launch the commands palette in View --> Command Palette then type Create New xxxx

Any screenshots to share?

Mine prompts me to enter project name etc…

I get that command palette just fine, and when I click on “Particle: Create New Project”, I get this in the lower right corner of the window,

I don’t know if there is something wrong with my installation. I didn’t download VS Code specifically for Workbench. I had downloaded it recently for Python development (within the last month). It is version 1.29.1

Hey Ric

Same thing I found.

Created an empty folder in a finder (Mac), then Open that empty folder in VS Code. Then create the new particle project from the Command Palette. The Particle Welcome “create” seems to have a glitch.

1 Like

Thanks, that worked. Definitely not intuitive. So, I guess that you then need to edit the settings file to look like Kenneth’s, or is there some other simpler way to get the required data in there? This is what I get by default,

{
    "settings": {
        "extensions.ignoreRecommendations": true,
        "C_Cpp.default.configurationProvider": "particle.particle-vscode-core",
        "files.associations": {
            "*.ino": "cpp"
        }
    },
    "folders": [
        {
            "path": "."
        }
    ]

Yep.

I set the device, firmware, and platform using the command pallet then went in a changed the specifics within the project_name.code-workspace file within the project.

This worked for me and I was able to compile using the command pallet Particle: Cloud Compilethe blink example. I haven’t tried flashing my device yet… baby steps.

I edited mine to be like Kenneths but changed my platform to “argon” instead of “xenon” as I was using the argon. It still shows a warning but it still worked.

Seems from other posts, that because the Workbench is so early on that a lot of features for mesh are still in the pipe.

Hey folks –

We are indeed in the process of adding support for 3rd Gen devices to Particle Workbench and will notify individuals on the Developer Preview list when we have a new release candidate. Given that we’ve recently started fulfilling our 3rd Gen hardware, it’s high on our priority list.

2 Likes

Hi @petek157,

We just sent a note about Alpha 5, which adds support for Particle Mesh hardware. See more details here: Developer Preview Changelog - December 4, 2018

3 Likes