Discussion of Snapmaker 2.0 Firmware Updates

So spindle speed reported back to the controller twice a second?

That’s fast enough to do a stall check and stop the machine for a stall condition. It might also be fast enough to calc the deviation from the commanded speed and stop the machine for an overload condition (too deep of a cut)

1 Like

From the Documentation SN published on Gitub, in theory you could have the CNC module do that stuff internaly (to keep the controller less busy) and if anything starts going wrong tell the main controller to get Z up ASAP and turn of the spindle inside the Module a couple ms later. The Modules are updated via CAN btw found that yesterday ind Code and today in documentaton confirmed.

Yea, there’s a built-in panic function already, I’d just as soon call that. Stop all motion, stop the spindles, pause in place. It’s not like it should be happening frequently. The main controller would be the appropriate place to do that I think, since it controls motion. Additionally, since the toolhead source hasn’t been released and I don’t want to wait for it.

You would not want to turn off the spindle in the toolhead before stopping motion, that’s even worse, and there’s no mechanism currently to report that to the toolhead for confirmation.

1 Like

Have Snapmaker said whether they plan to release module firmware / touchscreen source?

Given that in Luban now they added also the possibility to upload and package the module FW besides the controller FW, I would assume that they are planning so :slight_smile:

1 Like

Here is the source for the controller and in the readme some information how to compile and pack the firmware to get it on the machine.

1 Like

Hurrah, first change done! I was getting fed up with turning on the LEDs on the enclosure every time so I made them turn on on boot. It would have been better to make the change in the touchscreen (so the user can toggle the behavior), but this works for now.

Am I right in thinking there is basically no risk of a bad flash? The touchscreen puts the controller into download mode, and the firmware doesn’t include a bootloader?

No, the touchscreen based updating routine depends on a working controller to accept the update. So if you mess it up enough, you will no longer be able to use the touchscreen for updates. (As an experiment I tried flashing a firmware which just adds an endless loop shortly after boot and then the screen wouldn’t even start)

The firmware packages do not include the bootloader though, so it’s much harder to mess that up unintentionally. To flash though the bootloader you can e.g. use my package program uploaded under GitHub - zauguin/SnapmakerUpdate (see “Advanced usage” in the README)

2 Likes

Please please please add a mechanism where i can setup my PC once off as trusted so i don’t need screen confirmation each and every time i connect from Luban. My PC and Snapmaker are in different rooms on different levels so i am running steps all the time which is driving me crazy

2 Likes

That would require changes to the touchscreen code, which we don’t have. There has been no mention if we will ever get it.

We can decompile and rebuild it, but then getting that change into the touchscreen is non trivial.

Almost 3 month from last firmware update… Too much time.

I would also like to see the printer-side authentication operation removed.
In IdeaMaker (RAISE3D), there was no authentication on the printer side.
The operation screen is displayed on the computer in exactly the same configuration as the screen displayed on the touch screen.
I was able to start, pause, and stop printing via WIFI, without the need to use the touch screen.

3 Likes

At present the touchscreen click is a security lockout.

Consider what might happen if you could start a job across the internet without such a step.

What if someone else could?

That would require local access on the network. Many home automation systems (mine included) don’t require authentication to turn your lights or other appliances on because it’s already on the local secure network.

There’s no sound reason beyond “defense in depth” to require local authentication on a private secured local network.

On its own merit, requiring a button press on the touchscreen is only a nod to properly implemented security and weak at that.

Combined with the fact the token system is fundamentally mis-implemented in this device its security is laughable.

To break this machine and control it from the Internet we’re just going to consider the local network already compromised, since that’s a requirement anyways - this doesn’t phone home and allow for control via a remote cloud service, you’d have to be on the local network anyways via a compromised device used for command and control.

So since you’re on the network, just sniff the wireless traffic and pull the token from the REST request. Then you can indefinitely use that token to spoof commands until someone clicks “disconnect” on the touchscreen.

As far as we know now there is no lifetime on those tokens. Additionally they are not checked against the IP they are issued to, and will be accepted and commands will excecuted from any device.

5 Likes

I have searched the IdeaMaker (RAISE3D) forums and there is no discussion of the need for authentication.
Most of the users use it alone and do not need security. Aren’t there few environments where multiple users are using it at the same time?

If it is necessary for a multi-user environment, you can change the authentication method.
For WIFI connection, you set a password on the touch screen, right?
In the same way, why not set a password on the touch screen to allow connection requests from Luban?
When the passwords on Luban side and touch panel side are the same, we can connect automatically.

The above idea should solve the security problem, what do you think?

Are you still assuming any special circumstances?

3 Likes

Another solution is the one already available on 3D printers that’s not implemented on the Snapmaker: https://marlinfw.org/docs/gcode/M016.html. A small modification of the firmware could require M16 to be presented, which Luban could issue at connection.

2 Likes

I really hope Snapmaker will make it possible to change the Flowrate on the touchscreen. I really don’t understand why this feature is not there.

Also you should be able to change the Fanspeed, not as important as the fan is too weak to do much difference.!!!

Hell yeah! I agree completely.

The firmware has not been updated since September.
I wrote a request on GitHub, but no response.
There are so many posts on Cura, but they are replied within a few days.
Are there not many developers for SM2 firmware?

It’s hard to tell.
So far my guess would be one or less.

-S