![]() |
Re: Shutting Down a Robot-Mounted Pi
Quote:
Also this from me in that topic: http://www.chiefdelphi.com/forums/sh...1&postcount=45 See later pages there are others on the forum about this. I don't have my fingers on the old official QA you'd have to dig that up and look but I meant this forum when I wrote this: "This topic has been done extensively elsewhere on the forum." If I really need to I am sure I can dig up that old e-mail from FIRST headquarters. |
Re: Shutting Down a Robot-Mounted Pi
Quote:
|
Re: Shutting Down a Robot-Mounted Pi
Quote:
So you say I'm almost guaranteed to sell a few hundred to prove I can keep up with demand? I'm not hearing the problem. Adafruit will sell me 85 per order |
Re: Shutting Down a Robot-Mounted Pi
I don't know the RoboRIO ecosystem, but I do know Linux and Java.
Code:
ssh user:password@rpihost 'sudo shutdown -h now'Add this when you detect end of match presuming you go the script route: Code:
java.lang.ProcessBuilder processBuilder = new java.lang.ProcessBuilder("ssh", "user:password@rpihost","/path/to/script.bash"); |
Re: Shutting Down a Robot-Mounted Pi
Quote:
Are you done yet? (quoting an old college professor 10 minutes into every test) Can we buy one? Remember you need a way to charge that integrated battery as well. If you sell this under COTS there's no minimum sale requirement - just that people in general can buy them. If you take this product into FIRST approval that's a more complex and lengthy process you will not complete this season. |
Re: Shutting Down a Robot-Mounted Pi
In 2012 we used a linux single-board computer on our robot and had to solve the shutdown problem. There are some details in this document:
http://www.chiefdelphi.com/forums/sh...ght=Kinect+987 Our final solution assumes that you've written a program on your vision processing computer that can respond to packets it recieves from the RoboRio or other computers. Our robot computer (crio at the time) sent a packet to the vision co-processor which caused it to run the shutdown script. We triggered all of this with a button on one of the joysticks at the drive station. For what it is, it was a lot of work to get right but we didn't want that 1 in a million chance of our vision computer corrupting its file system at the wrong time. |
Re: Shutting Down a Robot-Mounted Pi
Has anyone looked into the legality of this?
http://www.modmypi.com/raspberry-pi/...dules/ups-pico I'm going to ask on the Q&A myself tonight. |
Re: Shutting Down a Robot-Mounted Pi
Quote:
|
Re: Shutting Down a Robot-Mounted Pi
I await the Q&A response, but I expect this would not be legal, as it's not integral to the cots computing device. It's an add-on, but I suspect it is just outside the line. Could be an interesting option if they rule it legal.
|
Re: Shutting Down a Robot-Mounted Pi
Quote:
|
Re: Shutting Down a Robot-Mounted Pi
/sigh. No computer system that I've used from mainframes to Raspberry Pi, from MCP to Unix, including Windows and Linux deals well with hard power off when there are IOs in process. You've been lucky.
Lots of people have borked the SD card in a Raspberry Pi. The OP asked a good question, and people are trying to help. Your "whistling in the dark" isn't productive and I predict that someday you will either spend the night hand sewing inodes to restore a file system, or spend most of the day hoping your backup system really works while you boss yells at you about lost orders. |
Re: Shutting Down a Robot-Mounted Pi
Quote:
The issues is more about hardware than software. The FTL (flash transition layer) will remap storage on the fly as part of its wear leveling feature. If you kill power during a remapping, you pretty much lose the whole disk. This is different from flash storage on something like a roboRIO or a wireless router, which doesn't have that additional layer of abstraction. Linux does care when its file system is no longer usable. |
Quote:
Quote:
So please folks, don't question my intelligence. |
Re: Shutting Down a Robot-Mounted Pi
Quote:
We're toying with a few auto-shutdown features in our own code, but detecting the end of match (rather than disabling of robot) is proving a little tricky. |
Re: Shutting Down a Robot-Mounted Pi
Quote:
This is not to question to you, or anyone's intelligence, just a point that currently I have 50,000+ copies of Linux online and running in various public and private clouds and datacenters. The smart thing to do is do a proper shutdown unless you know for a fact you've controlled the risk or have no better option. For example I used to take Dell OptiPlex systems I had as leftovers from upgrades and put Ubuntu on them. Mess with the disk settings to spin down the hard drives and spin them up only on demand or every 6 hours (which ever was first and then spin them back down in 5 minutes). I would increase the write cache large enough that casual writes would come back from memory. I would remove the swap so that would not qualify to spin up the hard drive. Most of the drives lasted beyond 8 years and those that did not were already questionable (had de-allocated bad sectors that weren't mapped at the factory). These systems were used for print server farms like a giant version of the HP JetDirect driving down the cost of the printers because we could print to CUPS raw queues from Windows happily. So again - there's plenty of simple ways shown here to accomplish this task from using a button and a script or SSH. Why run any risk you don't need to? Unlike other applications out there you really might take the chance you have an issue in the next match that hurts your competitive edge. |
| All times are GMT -5. The time now is 21:07. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi