 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
cruzer
Joined: 11 Feb 2009 Posts: 13
|
Posted: Tue Oct 27, 2009 9:43 am Post subject: Did I damage my RAM using ahk ? |
|
|
hi,
I got lots of blue screens, pc hanging-up, applications crashing, games crashing... the last couple days.
they all give me error messages regarding memory.
the pc is actually crashing every 2-3 hours, and sometimes even my windows user profile can't be loaded!
I used scandisk after every crash, and it found no problems.
yesterday I've tested my RAM using the tool from the vista repair console (F8 before windows boot) and it told me that my RAM indeed is damaged!
the wierd thing is that I tested a script to read and write memory with ahk that day the problems begun.
during development my pc crashed, and from then on I had those problems.
I even checked the creation dates of the ahk files, and compared it to the windows system reports, the heavy problems started at the same date as I tried those scripts!
my question now is:
can any of these scripts have damaged my RAM ? is that possible? (scripts attached at the end of this post)
I tried reading on 3 programs: notepad, calculator, and warcraft 3.
on notepad and calculator reading worked, on warcraft 3 it didnt return no value (but I think it's because of anti cheat or it requires debugging privelegs).
btw I don't wanna cheat on that game, I tried to make a useful tool (http://www.autohotkey.com/forum/viewtopic.php?t=50285)
and I tried writing memory on notepad and calculator, and it also worked (I checked the value's using the tool CheatEngine and they changed).
But I remember that I sometimes executed the script, trying to read or write memory to calculator, but I didn't had calculator running.
and another thing is that the CheatEngine tool, that I used to search valid adress points sometimes also showed me adresspoints of other processes instead of notepad/calc/warcraft3 only, so I might could have read or even written to an adresspoint of a random process, but I'm not sure if that is possible because the scripts ask for a PUID.
I also tried things like ReadMemory(0x453000, "Warcraft III") with 0x453000 as well as just 453000 (without the 0x) because it didn't work so I just tried it..
on the other side, my notebook is just 1 year old now, but it had a few crashes (blue screens, haning-up), but only about less than once per month and not lots of successive crashs like I have now. and as far as I can remember the bluescreens usually showed up something about the soundcard driver or the ACPI and not about the memory, while now ALL bluescreens AND application errors tell me about memory problems.
so what do u think?
yes I need new RAM
btw I'm using Vista 32bit, got 4 GB DDR3 RAM (2 GB + 2 GB dual channel, 3068 MB because vista 32bit restrictoin) if that matters..
I used the fscripts form this thread (first and 2nd post):
http://www.autohotkey.com/forum/viewtopic.php?t=37007
| Code: | ReadMemory(MADDRESS,PROGRAM)
{
winget, pid, PID, %PROGRAM%
VarSetCapacity(MVALUE,4,0)
ProcessHandle := DllCall("OpenProcess", "Int", 24, "Char", 0, "UInt", pid, "UInt")
DllCall("ReadProcessMemory","UInt",ProcessHandle,"UInt",MADDRESS,"Str",MVALUE,"UInt",4,"UInt *",0)
Loop 4
result += *(&MVALUE + A_Index-1) << 8*(A_Index-1)
return, result
}
Run calc.exe
winwait, Calc
StartTime := A_TickCount
loop 1000
value:=ReadMemory(0x41000C,"Calc")
ElapsedTime := A_TickCount - StartTime
msgbox, Memory address 0x41000C = %value%`nTake %ElapsedTime% ms to loop 1000 times |
| Code: | WriteMemory(WVALUE,MADDRESS,PROGRAM)
{
winget, pid, PID, %PROGRAM%
ProcessHandle := DllCall("OpenProcess", "int", 2035711, "char", 0, "UInt", PID, "UInt")
DllCall("WriteProcessMemory", "UInt", ProcessHandle, "UInt", MADDRESS, "Uint*", WVALUE, "Uint", 4, "Uint *", 0)
DllCall("CloseHandle", "int", ProcessHandle)
return
}
WriteMemory(10, 0x41000C,"Calc")
;(InputValue, Address, Program) |
and later on I used the last one of page 1
| Code: | ; Automatically closes handle when a new (or null) program is indicated
; Otherwise, keeps the process handle open between calls that specify the
; same program. When finished reading memory, call this function with no
; parameters to close the process handle i.e: "Closed := ReadMemory()"
ReadMemory(MADDRESS=0,PROGRAM="")
{
Static OLDPROC, ProcessHandle
VarSetCapacity(MVALUE,4,0)
If PROGRAM != %OLDPROC%
{
WinGet, pid, pid, % OLDPROC := PROGRAM
ProcessHandle := ( ProcessHandle ? 0*(closed:=DllCall("CloseHandle"
,"UInt",ProcessHandle)) : 0 )+(pid ? DllCall("OpenProcess"
,"Int",16,"Int",0,"UInt",pid) : 0)
}
If (ProcessHandle) && DllCall("ReadProcessMemory","UInt"
,ProcessHandle,"UInt",MADDRESS,"Str",MVALUE,"UInt",4,"UInt *",0)
return *(&MVALUE+3)<<24 | *(&MVALUE+2)<<16 | *(&MVALUE+1)<<8 | *(&MVALUE)
return !ProcessHandle ? "Handle Closed: " closed : "Fail"
} |
|
|
| Back to top |
|
 |
pajenn
Joined: 07 Feb 2009 Posts: 384
|
Posted: Tue Oct 27, 2009 11:41 am Post subject: |
|
|
| Quote: | | btw I'm using Vista 32bit, got 4 GB DDR3 RAM (2 GB + 2 GB dual channel, 3068 MB because vista 32bit restrictoin) if that matters.. |
if you are not doing anything else with the spare Gig, let eBoostr 4 (free beta) use it to boost performance, or make a RamDisk of it with SuperSpeed RamDisk (not sure if they still have a free version).
About testing RAM: I was in your position several years ago (before ever using AHK), and the recommended RAM tester at the time was memtest86+ (freeware). Also, I was told to test each RAM card separately. i.e. take one out, leave the test to run over night (or until errors are found). then repeat with the other stick.
disclaimer: I've used above softwares with Windows XP only. _________________ Hardware: 1.8 GHz laptop with 4 GB ram, Windows XP/SP3
Software: Prevx, Privatefirewall, KeyScrambler. |
|
| Back to top |
|
 |
engunneer
Joined: 30 Aug 2005 Posts: 8255 Location: Maywood, IL
|
Posted: Tue Oct 27, 2009 1:39 pm Post subject: |
|
|
the short answer - no. Programs cannot damage your hardware RAM. The RAM itself might be cheap or fragile, but software won't make it worse.
It /is/ possible to corrupt Windows in multitudes of ways. I would suggest downloading and burning a linux live CD, botting your computer from that, and seeing how things go. If you still get crashes, you might have a hardware problem like a badly configured CPU (overclocked), or the heatsink might be coming off! The video card can have the same heatsink problem as well.
If the linux CD runs ok, then you might consider reinstalling windows to fix any corrupted system files. _________________
(Common Answers) |
|
| Back to top |
|
 |
sinkfaze
Joined: 18 Mar 2008 Posts: 5044 Location: the tunnel(?=light)
|
Posted: Tue Oct 27, 2009 2:29 pm Post subject: |
|
|
| engunneer wrote: | | If the linux CD runs ok, then you might consider reinstalling windows to fix any corrupted system files. |
You might also try running System File Checker to see if that properly replaces the corrupted/outdated system files before re-installing Windows entirely. _________________ Try Quick Search for Autohotkey or see the tutorial for newbies. |
|
| Back to top |
|
 |
cruzer
Joined: 11 Feb 2009 Posts: 13
|
Posted: Wed Oct 28, 2009 12:11 pm Post subject: |
|
|
oh my god..
I tired the SFC, first by using "sfc /verifyonly" because I thought it would be better if i just run it in "read only" mode. It said that it found something.. so I used "sfc /scannow", the scan&fix mode and as I feared it crashed during the process, got a bluescreen .. memory something..
after this my windows crashed at every single startup, even in console safe mode..
only thing that still worked was the repair console. then I spent more than 8 hours to use the repair console, chkdsk, sfc (which also crashed in safe mode...), the vista dvd and so on. great! btw its not even possible to use sfc inside the repair console.
then I gave it up and opened the laptop and removed each RAM and used the RAM check tool. one of the RAMs is corrupted, the other has no problems, so now my PC works with that single RAM, but with working RAM I still couldn't fix my old windows anymore... so here I'm now waiting for 93 vista updates to be downloaded..)
| engunneer wrote: | | the short answer - no. Programs cannot damage your hardware RAM. The RAM itself might be cheap or fragile, but software won't make it worse. |
well I wouldn't be too sure about that.
working software might won't damage your computer hardware, but bad, corrupt, defective or malicious software can do.
- the easiest thing would be overclocking or disabling the cooling fans..
- sending wrong commands to the drives can damage the HD or can even completly kill a be/dvd/cd writer and disk.
- overwriting firmware of any device
- old CRTs could easily be damaged by sending unsupported signals...
those things are the things I know about.
but I do not know about RAM. and I don't know about programming RAM so I (or the function I used) might have done some fatal things to it.
| engunneer wrote: | It /is/ possible to corrupt Windows in multitudes of ways. I would suggest downloading and burning a linux live CD, botting your computer from that, and seeing how things go. If you still get crashes, you might have a hardware problem like a badly configured CPU (overclocked), or the heatsink might be coming off! The video card can have the same heatsink problem as well.
If the linux CD runs ok, then you might consider reinstalling windows to fix any corrupted system files. |
I've tried it, and the linux live-cd also crashed. the windows vista dvd also crashed.
I never overclocked anything, and never had any warnings about the heat. And I'm not using much power of the pc (only old direct-x 8 games). not even carrying the laptop around so the RAM shouldn't have died so fast.
| pajenn wrote: |
if you are not doing anything else with the spare Gig, let eBoostr 4 (free beta) use it to boost performance, or make a RamDisk of it with SuperSpeed RamDisk (not sure if they still have a free version). |
thanks but you need a special mainboard that supports some special things to use all the 4 GB RAM under 32bit, and mine doesn't support that.
and I don't wanna mess around with RAM anymore after this..
I had a RAMdisk before (the microsoft driver) but I uninstalled because I was concerned that it could have something to do with bluescreen crashes. |
|
| Back to top |
|
 |
sinkfaze
Joined: 18 Mar 2008 Posts: 5044 Location: the tunnel(?=light)
|
Posted: Wed Oct 28, 2009 2:50 pm Post subject: |
|
|
I'd say it's more likely that the RAM damaged the software/system files than the other way around. Given your description of usage if it happens again you might also check into the possibility of a faulty power supply. _________________ Try Quick Search for Autohotkey or see the tutorial for newbies. |
|
| Back to top |
|
 |
pajenn
Joined: 07 Feb 2009 Posts: 384
|
Posted: Wed Oct 28, 2009 3:20 pm Post subject: |
|
|
| cruzer wrote: | thanks but you need a special mainboard that supports some special things to use all the 4 GB RAM under 32bit, and mine doesn't support that.
and I don't wanna mess around with RAM anymore after this..
I had a RAMdisk before (the microsoft driver) but I uninstalled because I was concerned that it could have something to do with bluescreen crashes. |
fwiw, I'm using a 32-bit Windows XP with 4 GB of ram. I don't recall reading about any special mainboard requirements. For SpeedDisk Plus the instructions said to add /pae at the end of the boot.ini line for WinXP:
My boot.ini now:
| Code: | [boot loader]
timeout=3
default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /noexecute=optin /fastdetect /pae
C:\CMDCONS\BOOTSECT.DAT="Microsoft Windows Recovery Console" /cmdcons
|
*CMDCONS is just the standard MS Recovery Console (nothing to do with RAM). it's only 7MB to add as a boot option and loads much faster than booting to it off the CD - I use it for the occasional chkdsk type operations, for deleting stubborn locked files, or for loading System Restore (well, ERUNT) backups if Safe Mode doesn't work... Most of the time though I just use Bart XPE or Acronis True Image for dealing with Windows problems... _________________ Hardware: 1.8 GHz laptop with 4 GB ram, Windows XP/SP3
Software: Prevx, Privatefirewall, KeyScrambler. |
|
| Back to top |
|
 |
tank
Joined: 21 Dec 2007 Posts: 3700 Location: Louisville KY USA
|
Posted: Wed Oct 28, 2009 6:02 pm Post subject: |
|
|
windows xp manages memory usage and does not allow direct control of memory space or cpu time. if your code did damage it is because windows itself was damaged _________________
We are troubled on every side‚ yet not distressed; we are perplexed‚
but not in despair; Persecuted‚ but not forsaken; cast down‚ but not destroyed; |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|