I am trying to over clock my rasbian raspberry pi, but when I change any files beyond /sys/devices/system/cpu and restart, the changes are not saved. I tried echoing to the files and nano and cat. Nothing will work.
SysFS (mounted on /sys) is not a regular filesystem, the elements in this FS represent different aspects and options exposed by the kernel and modules, as such, those parameters are not persisted on secondary memory.
Is normal that changes under that directory are not saved (the only ones I recall to be saved are some settings about power saving in some notebooks, those settings were saved in the BIOS), in order to have the changes on every reboot you should create a init script or modify /etc/rc.local (on Debian based systems as Raspbian).
My SDcard was doing the same thing.
I tried to re-burn the image to the card, but it still had the same problem.
I burnt the image to another SD card, and it worked right away.
More than likely the card was corrupted or damaged
Related
I have just started to work in a project where the product uses a imx8m mini module together with Yocto Linux (Zeus).
Currently we have a problem related to the shutdown behavior of the product, and we need to modify what happens during a shutdown.
As today when we shutdown or a thermal emergency happens, the PMIC_ON_REQ(That controls the external power regulator) goes low, but we need to change this behavior that it keeps the current value on PMIC_ON_REQ, as we have other diagnostic devices that needs to talk to the PMIC after that the imx8mm has turned off. In other words: I want to keep the value of the gpio as long as possible, until the control is out of reach.
But my current problem is that I don't know where to start, or what kernel module I shall look into.
Does any one have any clue where I shall start to look to be able to find the code for patching?
I have tried commands in devtool like "devtool modify power/thermal/soc" but without finding the needed code..
Please observe that this is my first Yocto project ever, so if I write something strange, bare with me
I want to do something like "clone" entire system partition but it destroy filesystem. I want to save filesystem type, owner, permissions and everything else.
I did try to use xcopy(almost work, but stuck on running), on xrobocopy crashing at boot. Why? Needed many times in some kind of system repairs. Maybe someone have tested and working idea? Programs tested - nothing can do like only clone with destory system.
There is a Raspberry Pi 3 B+ which was already used.
I need to bring it to the default settings, i.e. to the state which you get it from the store (so that I can start using from scratch again, I want raspberry to forget all the previous actions, like it is new. Or simply cancel all the previous actions one has done).
What I did:
I tried to search "how to reset" or bring to the default, I could not find anything. Everything is about factory default and reinstalling some image.
Among useful commands I didn't find: https://raspberrytips.com/raspberry-pi-commands/
Isn't it not simple like resetting a smartphone? I may google differently.
The only way I could find to reset my raspberry pi is to rewrite (reflash) an SD card of it.
https://www.youtube.com/watch?v=ntaXWS8Lk34
The thing that I am trying to do is I need to constantly check if a file on a shared corporate network location is available. The network admin performs a copy command and copies a large disk image file .iso to this target network location. The upload (copy) process takes about 4-5 hours, and in order to copy this file to my local computer, I need a way to determine whether this file has been fully copied or not.
I have tried using System.IO.fileinfo::Open, and it worked on my local experiment.
But yesterday when it checks, it failed to tell if the file is locked--the file is not constantly locked, and since it takes 5 hours, it seems that occasionally the file becomes unlocked briefly (possibly due to OS's trying to allocate another continuous space for that file). Hence my powershell script failed.
I also tried checking the size of the file as it is being copied over, but apparently the size of the file is constantly its original size, so this would not work.
So does anyone have any ideas how can this be verified? Thank you in advance.
There is a FileSystemWatcher but I am not sure if it works reliably on network folder. Another option is try check last write time of the file, and if the last write time is not changed for, say, 3 minutes, chances are that the copy is finished. You can also combine this with your lock check.
I am looking for a solution on how to setup the Windows CE 6.0 design image to integrate my custom application.
I want after building the image and starting it on the target machine to be able
to access my application from the \Hard Disk\Program Files\CustomApp folder.
In addition I require the application to be persistent. It must not be lost after reboot.
I am aware of copying the application to the Hard Disk out of the NK.BIN but if is possible I want a solution like adding dlls or other files to Windows folder.
I am usign an SQL CE database along with the application so I want the data to be persistent too.
Thanks in advance.
If the \Hard Disk folder contents are not persistent (and I assume they aren't since you're asking this questions), then getting the app to "persist" can be done only as a slight-of-hand trick, just like the contents of the Windows Folder. At boot, the OS will get expanded into RAM, and if you've included your app in that OS, it will get extracted too.
First, you must include your app files (exe, dlls, all dependencies, etc) into the OS image by adding them to a BIB file.
Next, you must understand that all files get extracted to the \Windows folder. There are no exceptions. If you want it in a different folder, you must use a DAT file to tell the OS where to put it one the OS has been extracted. Be aware that the DAT file does a copy, not a move, so if you want it elsewhere, you'll have two copies of the app on the device. A typical solution is to use the DAT file to place a shortcut, not a full copy.
The last part of your question is the hard, or maybe impossible, part. Your database is not going to persist. You could include a copy in the OS, but every time you hard reset, a new copy of the database as it was when the OS was built will get copied out. No new data will survive.
To get that to work, you need a persistent file store on the device. If you're the OEM, you might be able to implement one with any remaining on-board storage (where the OS image file resides) or with separate mounted USB/CF/SD/HDD media. How you do this is highly hardware and BSP dependent, plus it's way more complex than can be described here on SO.Without knowing anything about the target device, it difficult to even give you any pointer on where to begin. Here's a very generic starting point for Flash storage.