Looks like nVidia now allows paravirtualization of a single GPU between different virtual machines. This is really cool for AI work. Craft Computing shows you how to set up the graphics cards and virtual machines.
Check out some of his other great videos as well. I like this one where he was finally able to figure out how to use ANY graphics card for 3D Acceleration in a virtual machine:
Squirrel Eiserloh compares random number generators and noise functions. He does a great job summarizing the pros/cons of each and then shows how the noise functions can replace random number generators and then provide many other benefits (unordered access, better reseeding, record/playback, network loss tolerance, lock-free parallelization, etc) while often being smaller and faster than traditional random number generation.
Setting up dialup modems at home without a land line
If you’ve ever wanted to try out dialup connections for retro purposes, you might think you need a land phone line to do it. You could use a full-fledged telephone line simulator, but those are expensive and actually overkill. Instead, you can use certain voice over IP (VOIP) adapters to generate the dial tone you need. They can be found on eBay for about thirty bucks. Spend about fifteen minutes configuring it and any pair of modems will be able to connect through it. Even better, you could use IP forwarding to make the dialup-to-VOIP work with anyone else in the world via modem-over-TCP/IP.
No matter how bad your legacy code is, never EVER create a project to ‘clean up the code’. It will never get completed, you’ll inevitably have to stop, and it will end up worse than you started. This has happened every time in my experience.
The only proven way to get out of bad code requires EVERYONE on the team to get on the same page of how code is supposed to be written. Make them take the Clean Code class/read the book and then use the boyscout approach. That approach is every checkin you check in the code a little better than you found it. That’s it. In time, those little refactors move the ship in the right direction, become dominant, and then surround and destroy the bad code.
Code that has not been touched for years likely doesn’t NEED to be touched. Sure, it may be messy, but if it works, there’s no point in spending time on something you aren’t going to improve functionally.
Code reviews are largely useless. People go in, listen for 5 minutes and then at the end everyone leaves saying, “I sure hope he knew how it all worked because I toned out.”
TODO comments are fine, but should be completed before submission and never checked in. After they are checked in, they become TODON’T comments because they never get completed.
If people get into an argument about syntax/details and it lasts more than 5 minutes, then neither person has solid evidence for why it should be their way. Just flip and coin and move on.
I learned to program back on an old TRS-80 Model III computer as a kid. Long before Windows and even DOS, most home computers required you type in programs or load them from cassette tapes. If you were really rich, you might afford a floppy drive, but that was an expensive luxury I never had. My next computer was an IBM XT, and it ran the advanced and stalwart DOS 3.30 – which was dramatically better.
Running those old operating systems today requires you either buy one of those old systems and keep it running, or you have to emulate them. You can easily emulate DOS 3.3 and Windows 3.0 and higher on VMWare or Virtualbox, but going earlier than doesn’t seem to be supported anymore.
Enter 86Box – an emulator that lets you emulate REALLY old machines. In fact, I was able to get Dos 3.2 running Windows 1.0.
Start 86Box and set up 86Box by selecting Tools->Settings from the top menu, and set the system up with the following settings.
Part 2: DOS 3.2 and Windows 1.01 install
Start up the 86Box.
Set Media->Floppy 1 to disk01.img, then issue a ‘CTRL-ALT-DEL’ to reset it. The system should start up and boot to the dos 3.20 floppy drive
Run ‘fdisk’ and it should detect your hard drive. You’ll need to create a partition to set up the hard drive.
Reboot and boot from the DOS 3.20 disk again.
Format the hard drive by using ‘format c: /s’
Set Media->Floppy 1 to ‘DISK1-SETUP.IMG’ from the Windows 1.01 (5.25)
[optional] type ‘set prompt=$p$g’ if you want to see your full path in the command prompt
Run ‘setup’ from a: and follow the instructions to install Windows 1.01 on C:. Change the disks when prompted by selecting Media->Floppy 1 and setting it to each of the floppy disks for the Windows setup until it’s completed.
The real answer is to always use seconds since an epoch for logging – like the Unix epoch – with 64 bit integer representation (signed, if you want to allow stamps before the epoch). Any real-world time system has some non-linear, non-monotonic behaviour like leap hours or daylight savings.
Something I wish I knew before picking the Lenovo 730-13IKB in a super-sale open box deal. The Yoga 730-13IKB has 2 really common, and pretty unforgiveable, problems. One is display flickering issues and keyboards that have keys that are randomly flaky. I got the display fixed while it was under warranty (after trying re-seating of the display cable through the hinge and only getting a little improvement), but it went out of warranty when I started having keyboard issues. I would often have the A,S,D keys stop working, but it wasn’t always consistent and was sometimes different keys. One solution that helped was to pull the bottom off, clean the contacts, and re-seat the keyboard connection. That, however, only worked for a little while until it started again.
Time to replace the keyboard with a new one – fortunately it was only $29 in 2021. As for how to do it, It’s Binh Repaired & Reviewed gives a great disassembly demonstration. The most annoying part is the removal of the black plastic wrap over the keyboard. I actually tore the backlight layer – but since my replacement kit had a new one I just tossed the old one. Once you’ve done that, it seems to go pretty well.
Now it appears to work perfectly, hopefully it will continue to do so.
UPDATE: ASUS has issued a recall. You can check the capacitor, or check the serial and part numbers. See the bottom of this article.
I recently bought an ASUS Maximus Z690 Hero for my new i9-12900K build. In the last few weeks since release, some people are reporting their ASUS Z690 motherboards are burning up and quit working. Fortunately for me, I have been unable to find DDR5 memory, so my board is still sitting in the box – which is fortunate because it appears the board I got his this very issue.
What is the issue? Reporters say the system runs for some time, then there is often an audible pop and the system hangs. People report smelling smoke and even seeing the upper corner of the board glowing. After powering down, there is damage to the upper corner of the board by the digital readout. Powering on the board throws code 53 and never reboots.
As more reports came in, they seemed to focus on these two 4C10B MOSFET components getting fried.
Buildzoid started looking at these reports and noticed something strange. The boards that are blowing up have a capacitor that appears to be backwards. These polymer-aluminum polarized capacitors have defined positive and negative electrodes. According to the specs on these types of capacitors, if you reverse the polarity accidently (i.e. if you put them in backwards) then leakage current will increase and ‘the life span may decrease’. This would explain why they might work for a short time, but then burn out.
Here’s a picture of a burned up board with the backwards capacitor. You can see the polarity stripe on the left. All the boards that appear ok have the positive stripe on the right.
There is no official word from ASUS on this yet, but a big reddit thread has basically concluded that this is the issue and discourage anyone from using these boards immediately. If they happen to blow when you are away, the system does not always power down and could present a real fire hazard as people have reported the components becoming glowing hot by the time they can even shut the system down.
12/29/2021 Update: Here’s the recall information from ASUS
We have recently received incident reports regarding the ROG Maximus Z690 Hero motherboard. In our ongoing investigation, we have preliminarily identified a potential reversed memory capacitor issue in the production process from one of the production lines that may cause debug error code 53, no post, or motherboard components damage. The issue potentially affects units manufactured in 2021 with the part number 90MB18E0-MVAAY0 and serial number starting with MA, MB, or MC.
This seems to be a common problem. On my keyboard, I’d have ASD intermittently drop out or take a couple hits to register.
I used this technique to re-seat the cable and help it lay a bit better under the battery – but I also used 99% isopropanol alcohol to clean the contacts. I actually got quite a bit of gunk off the contacts. I re-connected things but was still having trouble with f and g keys. I tried once more, and it seems to have perhaps solved it.
Time will tell, but maybe give it a try if you are having trouble.