Przejdź do głównej zawartości

Deploy programs to an MC252

Ta treść nie jest jeszcze dostępna w Twoim języku.

The workspace deploys the edge programs of an MC252 endpoint to the device. What a deploy does, and when it runs on its own, is in deploying.

A deploy that loads programs restarts every program on the device. Values in memory that is not persisted are lost.

  1. Save the change to the device’s programs or to device-side logging: on the endpoint’s Programs tab (see Write programs for an MC252), through the assistant, the API, or hmi push.
  2. If Deploy on save is on (the default), the save starts the deploy.
  3. If Deploy on save is off, select Sync now on the Programs tab, or ask the assistant to sync the device’s programs.
  4. Check the deploy status. When it is In sync, the device runs the workspace’s programs.

To put back programs someone changed on the device, select Sync now. This works with Deploy on save on too.

  1. On the Programs tab, select Settings.
  2. Turn Deploy on save on or off, turn Device-side logging on or off, and set Readings import period, minutes (1–1440).
  3. Select Save. Device-side logging applies after the device restarts; until then the tab says that logging settings wait for a restart.

The settings are described in edge settings.

  1. Open the endpoint’s Programs tab. Programs on the device at its top shows the state and updates while a deploy runs. You can also ask the assistant for the device’s deploy status.
  2. Act on the state:
StateAction
Changes waitingWith Deploy on save off, select Sync now; otherwise the deploy starts in a moment
Blocked by errorsFix the errors in the programs and save; nothing is uploaded until then
Deploy failedFix the program and line that the compile error names, or the problem the tab shows, then save again or select Sync now
Device offlineBring the device online; the deploy runs when it is back
Connected in another workspaceResolve a deploy conflict
Changed on the deviceSelect Sync now to put back the workspace’s programs

Every state is described in deploy status.

A device connected in more than one workspace gets no deploys. Every tab of its status page shows a warning in each workspace that holds it.

  1. Open the device’s status page in the workspace that should manage it, and select Show connection in the warning.
  2. Disconnect the device from the other workspaces. See Disconnect an MC252 from other workspaces.

The next deploy runs as usual.

Deleting the endpoint does not touch the device, and an endpoint that still has programs cannot be deleted. Remove the programs through a deploy first.

  1. On the Programs tab, select Delete program for each program and confirm. With Deploy on save off, select Sync now. The device reloads without them.
  2. Wait until the deploy status is Nothing deployed. Until then the programs may still be on the device: if the status is Device offline, Deploy failed, or Connected in another workspace, resolve that first.
  3. To remove the device from the workspace, delete the endpoint.

To stop one program but keep it in the workspace, disable it with the switch in the editor’s toolbar instead. The next deploy removes it from the device.