Python Forum
a class to memory map a disk - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: General (https://python-forum.io/forum-1.html)
+--- Forum: News and Discussions (https://python-forum.io/forum-31.html)
+--- Thread: a class to memory map a disk (/thread-14418.html)



a class to memory map a disk - Skaperen - Nov-29-2018

i have fuzzy memory of a class that would let me expose each sector of a disk. what i want to do is write a program to update selected bytes of a drive's partition table. it would let you get sectors in the form of a bytearray. then if the bytearray was modified, it would write it back to disk. it would be nice work with whole sectors. if not, i might have to do this in C.


RE: a class to memory map a disk - Larz60+ - Nov-29-2018

You won't get me to use it.
I have written disk access programs by cylinder, sector, etc. and was weary of my own code.
It took a long time for gparted to be accepted.


RE: a class to memory map a disk - Skaperen - Dec-10-2018

was gparted written in Python? or are you saying that people are generally weary of things that reach down to bare metal? should i quit listening to nordic dark metal music?


RE: a class to memory map a disk - Gribouillis - Dec-10-2018

Gparted is written in C++. You could perhaps translate it to python as a proof of pythonic mastership and virtuosity.


RE: a class to memory map a disk - Larz60+ - Dec-10-2018

Quote:was gparted written in Python? or are you saying that people are generally weary of things that reach down to bare metal? should i quit listening to nordic dark metal music
Not saying I wouldn't accept it, but only after it had been around for a long time without bugs.

Can't advise on nordic dark metal music, but I wouldn't listen to that either.