Re: General discussion chat Cardinal thinks he somehow got you, little does he know he's just being a fag
Re: General discussion chat got a nice fancy analog sensor wired up to a 5v system? great, now don't expect it to work when you swap to a 3.3v system :|
Re: General discussion chat So I traded my graphics card in my desktop for this. Call me cray. I love it. Needs read tire but I'm gonna use a smaller tire and rim I have for my other project to drive it around. Motor runs solid. needs oil change though soon. Sent through the stars by my Galaxy with a Note for you!
Re: General discussion chat Germany don't have a speed limit on their highways so im pretty sure you can go as fast as you want.
Re: General discussion chat Autobahns only. I want to visit one some day - - - Updated - - - I am the king of micro-optimisation I have decided. Code: float adcToCelcius(int adcPin) { int rawvoltage= analogRead(adcPin); float millivolts= (rawvoltage/1024.0) * 5000; float kelvin= (millivolts/10); float celsius= kelvin - 273.15; return celcius; } original code modified from here to be reusable across multiple sensors (I have 3). Terribly inefficient. floating point division (painfully slow even on hardware with a dedicated floating point unit and this is a piece of hardware which does not), floating point multiplication (slow), another floating point division, floating point subtraction (bizarrely slower than division when done purely in software as here) before getting our final value. Code: const float multiplierVolts = (1.0 /1024.0) * 5000; const float multiplierKelvin = 1.0 / 10.0; const float totalMultiplier = multiplierVolts * multiplierKelvin; float adcToCelcius(int ADCpin) { return (analogRead(ADCpin) * totalMultiplier) - 273.15; } much faster. the const floats will only be calculated once and their value stored in memory for later retrieval. This simplifies the math in our subroutine down to a single floating point multiplication and a single floating point subtraction. Much much faster. Also a perfect demonstration of space vs time constraints. My alternative solution is significantly faster however we now have 3 variables of 4 bytes each permanently held within RAM which would not have been there before. 12 bytes isn't alot, but this is code for a small microcontroller not a big desktop system, the one I am using is an AtMega2560 with 8192 bytes of RAM to play with and that is a fair bit considering I also own a chip with just 128 bytes. The previous solution was significantly slower, however kept no additional bytes in RAM permanently (of course it used memory while executing, but that wouldn't remain allocated full time). So the older solution may potentially have a smaller memory impact. The newer solution offers a smaller delay in getting the data I want (and still has room for improvement, I dont need to keep 3 floats in memory there is a way to do it with 1)
Re: General discussion chat guys. i just used almost all 8 gigs of my ram! i never thought i would need 8 gigs
Re: General discussion chat I just found out I could use the bluetooth of my motherboard to connect my dualshock 3 and not use a cable
Re: General discussion chat my computer locked up. i couldnt navigate or anything. at least not with out waiting a couple minutes