Asked — Edited
Resolved Resolved by DJ Sures!

Robot Embedded Rock Pi X Power Down

I was wondering how those of you that have the Rock Pi X onboard your robot handle powering down the robot and the Rock PI. Do you/should you log out of windows and then power down the Rock Pi and then the robot? Or do you just flip the robot's power switch off and let everything die? I know it frowned upon to just pull the plug on a computer running Windows.

I've tested a sudden power down of the Rock PI X without going though logging out of Windows and then reapplying power to the Rock Pi X. I had Windows 10 running and my robot project running in ARC. I disconnected the power cord from the Rock Pi X and it shut off as expected. I reconnected power and the Rock Pi simply booted into windows and ARC started as usual. (I have ARC in my windows Start up folder).

Any thoughts on issues or advantages in simply turning off your robot with a onboard SBC without shutting down ARC and Windows first?


Related Hardware Rock Pi X

ARC Pro

Upgrade to ARC Pro

Unleash your creativity with the power of easy robot programming using Synthiam ARC Pro

PRO
Synthiam
#1  

Never flip the switch on a computer:D. If you flip the switch a few times, it'll eventually corrupt the file system. For operating systems to run quickly, the cache files are in memory. This is because writing and reading from the file system are slower than memory. When you flip the switch, any unwritten data is lost. This would be specifically bad for you if it were the ARC project file - always make sure to save your project file to the cloud in ARC.

You can always add a speech recognition command or a button on the screen that shuts the computer down. You can call this command in ARC: https://synthiam.com/Support/javascript-api/Utility/shutdownPC

#2   — Edited

Thanks DJ. That's not the answer I wanted to hear. LOL. I will however practice safe computing and shut down properly.

The shutdownPC(); JavaScript command is the way I'll go. However I don't know JavaScript yet. Would you or someone start me in the right direction and show me how to use this command in a script I can call when it's time to shut down?

#4   — Edited

Thanks DJ. I had actually read and will reread your migration tutorial. It really has helped me to understand JS (a little. LOL).

Before I had asked for help I had tried to make a JS script with the "shutdownPC()" command. However I didn't realize I had to place the class before it. Once I placed "Utility." like you showed the script worked.

Very nice! My first JS script! I have a lot to learn. LOL.

EDIT: And everything is case sensitive. I didn't capitalize "Utility" and the script didn't work. Once capitalized it worked.

PRO
Synthiam
#5  

If intellisense is on, it’ll show you as you type

#6  

I shut down, but I did notice something not sure if its just specific to me or if its the same for you.

When I shut down or close ARC without disconnecting the EZ-Bs (arduino megas in my case) my servos go crazy.

So my shutdown order is: Disconnect EZB Shutdown windows Kill power

PRO
Synthiam
#7  

Servos that go crazy are most likely due to floating signal lines and picking up static. If you use digital servos, that shouldn't be an issue.