Planet-9 Porsche Forum banner
  • NOTICE - Before adding photos to posts on Planet-9, please review: Posting Photos on Planet-9

PIWIS 2 setup as a virtual machine

1 reading
133K views 172 replies 61 participants last post by  Hoster987  
#1 · (Edited)
This is a way to setup the PIWIS 2 software as a virtual machine (VM) inside Oracle’s VirtualBox, which is free VM software.

Videos of the setup process and using PIWIS are at the bottom of this post.

Link to programming options in development mode here:
Programming: - PIWIS 2: coding using development mode

Software setup

The setup procedure below is for the PIWIS software only. To connect to your car and do diagnostic procedures you will need to purchase the hardware (cable). You can just setup the VM and use the simulation mode in PIWIS to have a play prior to purchasing the hardware if you like.

To the people who made originally did the work to make this available, I take my hat off to you. There was clearly a lot of effort from some very smart people that allowed someone like me to get access to the software.

Background info:

PIWIS 2 runs natively in Windows XP. XP is no longer supported, and it is difficult to acquire an old computer that runs XP and keep it running. Using the software in a VM, whilst slower, will ensure you are able to keep the software forever regardless of the computer you use. I use a laptop that was pretty slick back in 2014, but is pretty slow by today’s standards. It takes a few minutes to get the VM loaded, but after that it’s as fast as any diagnostic software I’ve used in the past on other car types.

A while ago I was fortunate enough to stumble on a link to PIWIS 2 as a bunch of files that, through a specified process got software loaded and licensed on either an XP computer or a VM. Not having an XP computer, I went down the road of creating a VM.

Once the VM was created and the software licensed, it was a simple process of making a backup of the VM. This backup can then be imported to VirtualBox on any computer as an XP image with the PIWIS software already installed. There are only a few things that need to be done once the VM is created so that it’s good to go. It’s a surprisingly simple process.

Requirements:

  • A reasonably fast computer. Most modern laptops will easily do the job.
  • A minimum of 1.5GB of excess RAM (this is what is going to be allocated to the VM). Use Task Manager to see what is normally used. 8GB of RAM on a standard Windows 10 install should easily have enough to spare. 4GB probably won’t.
  • A minimum of 20 GB of spare hard drive capacity. This is what VirtualBox and the VM will take once installed.

For those who don’t know what a VM is, Google it and do some reading. Very simply you are creating a separate computer (guest) within your computer (host). You allocate resources from your host (RAM, etc.) and run the guest within a window on your normal desktop.

Here’s how to set it up.

1. Google ‘VirtualBox downloads’. Go to the download page and download the latest version of VirtualBox for the platform you use (PC, mac, etc.). On the same page, download the extension pack. The extension pack isn’t platform specific and is the same file for all operating systems.

Image


2. Log into your computer into the administrator account. Install VirtualBox. Once installed, open the program and then install the extension pack. You can’t install the extension pack unless you are logged in as an administrator. Installing the extension pack needs to be done from the preferences window of the VirtualBox program. If required, Google for how to do this. There are lots of videos how. Image below is what it should look like after the extension pack is installed. If not installed, it won’t be listed. Click the + button (red circle), find the extension pack file you downloaded and select it to be installed.

Image


3. Once VirtualBox and the extension pack have been installed you can log out of the administrator account if you want and login where you normally work.

4. Download the .ova file from the following link. It’s about 12.3 GB. This is the backup file of the VM. Depending on the browser you use, it might sometimes give a network error, and you will have to start again. Try another browser if you are getting this error. Also, when you ask to download the file, google drive will give you a warning that the file size is too large to virus scan. The machine where I created the file uses up to date virus scanning software. I’m confident it’s clean, but only you can make the decision of whether to download. I’ve downloaded the file to other machines and created the VM with no problems. Many thousands have downloaded the file with no adverse feedback.

PIWIS VM.ova

5. Open VirtualBox. Go to file, then import appliance. Go to the .ova file you just downloaded and select this. There are a few clicks of OK, and then allow the new VM to be created. It will take a few minutes.

6. If you have a cable, don’t connect it yet, we’ll do that later.

Update: For some reason after a few years the imprint for the tester expires and you will get blank menus, rendering the PIWIS diagnostics useless. KlausS98 came up with a very elegant solution, which is to start from a batch file that starts the VM and resets the date back to 2019, which stops the blank menu problem. Instead of starting the VM as described below in step 7, start Virtualbox, then click on the batch file. This will start the PIWIS VM and reset the date. I have saved the batch file to my desktop so it's easy to access. Note this only works for Windows platforms.

Update: Nov 22. The batch file isn't doing what it used to unfortunately. Klaus is looking into it. Until then I've found a workaround that is simple, but needs to be done each time you start the machine. Look at the video titled 'More PIWIS information' at the bottom of this post for the workaround.

Link to batch file:
PIWIS start window platform.bat

Link to thread explaining the problem:
PIWIS 2 virtual machine troubleshooting

7. Start the VM (should be called PIWIS) by either clicking the batch file as described above, or by selecting PIWIS in the left pane and then click start. It will now start Windows XP. This will take a few minutes for the virtual machine to fully load.

8. Right click on the ‘shortcut to praegeng.xml’ file and open in notepad. Go to the line that has ‘validationstring’ and change the ‘x’ to ‘9999’. This will now give the software a license validation time of 9999 days. Save then close.

Image


9. Click on the PIWIS shortcut on the desktop (the car icon). When PIWIS starts, select diagnosis and then select the car you have. If you don’t have a cable connected it will tell you this and give you the option of using simulation mode to continue.

10. PIWIS is setup to operate in ‘V’ mode (after sales mode), which is what is used in the dealership. You can change to either of the other modes, E = developer, or P = production. When you initially open the program and you get the first page with the picture of the Cayman, click settings, then diagnostic configuration and then choose the model line. Click the mode tab at the top, and now you can go down to ‘operating mode’ and change the mode of the software. Save. Close. Now open the diagnostics for your car type and you should be in the new mode.

Image


The vast majority of stuff you will want to change will be available in V (after sales) mode.
NOTE 1: The developer mode is in German only.
NOTE 2: Production mode doesn’t seem to work and locks you out of the program. I would suggest not using this. If you accidentally do select this, delete the VM (from the VirtualBox software window) and then create a new VM from the ova file you downloaded.


Connecting the cable

There are a few things that need to be understood prior to connecting the cable.
  • When you plug into the car, ensure you push hard so it clicks in. The cable should have a wire screwed on one side. This is what clicks over a clip at the back of the fuse panel that keeps it in place so you can drive and have it bump around and not dislodge.
  • The cable gets two power sources from the car. Terminal 30 (on all the time), and terminal 15 (on when the ignition is turned on)
  • The interface uses terminal 30 to make it run, and I'm assuming uses terminal 15 power to indicate the car ignition is on. This means the interface will work fine with the ignition off and key removed, but to do diagnostics the ignition needs to be on so the car's control units and CAN bus are active.
  • The cable interface is like a computer by itself, and will only work and be recognized by your computer when the plug is connected to the car.
  • When you start the VM, the cable needs to be powered, and the VM needs to be setup to immediately recognize the cable and mount it as the VM starts. If it doesn’t do it when it starts, you won’t be able to connect it afterwards once the VM is running.
  • You can go through the entire connection process all the way to opening the diagnostic program with the ignition turned off, but the plug must remain connected to keep the terminal 30 power to the interface. If you unplug the cable from the car at any stage you will power it down, and so to get it connected again you will need to start the connection process from the beginning.
  • Some control units you can interrogate with the ignition off, some will need the ignition on.
To ensure this happens, do the following.

1. Open VirtualBox but don’t start the VM.

2. Have both cables connected to the interface, then plug into OBD port. Wait a few bananas.

3. Plug cable into computer.

4. Go to VirtualBox, Settings, USB. Click the small USB button on the right with the +, and then select the cable. Picture below shows what it should look like once done.

Image


5. Now start VM, preferably by using the batch file (link above). When the VM starts it should see the new hardware and try and automatically install the driver. Be patient. It will take a few minutes for the VM to completely boot and detect the new hardware. One the wizard opens, ask it to search for the driver and let it install. This will take a few minutes. If this doesn't happen, go to Control panel/System/Hardware/Device manager then click on the + next to LibUSB Win32 devices. If you see "HSX interface" then all is good. If you see 'unknown device' right click and select 'update driver'. The wizard should now run to do this.

6. Now start the PIWIS program by clicking on the icon. It should update the firmware on the cable hardware when opening. I've had a problem sometimes on first connection where the interface firmware is updated. Immediately afterwards the interface won't connect to PIWIS and it wants to start in simulation mode. If this happens, close down the VM and start the process again. The interface driver and firmware won't need to be updated and the interface should now connect correctly and start in full diagnostic mode.

7. Once PIWIS is open and you have the window with the picture of the Cayman on it, you can use any part of the program. However to do diagnostics (select 'diagnostics' then your car type) you will now need the ignition on. If you don't have the ignition on the program will open OK but you won't be able to do anything as the CAN bus and control units aren't fired up. With the key out I've found it just hangs when you try and interrogate a control unit. If the key is in only but not turned on it tells you to turn the ignition on.

8. Next time you use the software all the drivers will be loaded, but ensure you connect everything in the same order as described above (except the bits that are clearly for installing stuff).

NOTE: Every time I use PIWIS, prior to starting the VM, I conduct step 5 to check the cable has been recognized by VirtualBox. I simply click on the + and see what USB devices VirtualBox can see at that moment. The Samtec interface should be in the list that immediately appears. If you haven't done everything in the correct order, you will see 'unknown device'. If this is the case, start the process again. I find that if I do this, I don't go through the whole process of starting the VM and then PIWIS to find out it hasn't connected correctly.

Once the VM is open you can hover over the USB symbol at the bottom of the VM window and you should see 'HSX interface'.

I also go through the last bit of step 5 above in control panel to see that I see 'HSX interface' in device manager. Then I know the interface is working fine and the VM has recognised it correctly.

Interface hardware options

When you purchase the interface you don’t need a hard drive with the software loaded, which they will most likely try and sell you as well. I bought the obd2.market cable and it has failed three times. The first time it was replaced under warranty, the second I had to pay a substantial amount to have it fixed. Third time, less than 12 months after the previous failure the seller wants to fleece me again for another fix. These units from obd2.market are clearly pretty fragile, so I wouldn't recommend this interface due to the quality of the product and the attitude of the business. I'm not sure if all of these aftermarket devices are made in the same factory, so I don't know if the other vendors sell a device of different quality.

Update: I just purchased another interface, this time from obd2store.com. Purchase experience was a good one and it works perfectly.

Interestingly I sent them photos of my old interface's circuit board and asked if they could fix it. They replied that it looked nothing like what they sold and so they didn't have the confidence to attempt a fix. This tells me there are interfaces of differing architecture on the market, and they don't all come from the same manufacturer. Hopefully this one will last a little longer

For different options internet search 'PIWIS 2 samtec interface'.

Thread dedicated to feedback of experience with different interfaces here:
PIWIS 2 interface failures

Additional VM information

Other details of the VM for those interested.

Guest additions doesn’t need to be installed as it is already in the ova file.

Two cores have been selected for processing. I initially used one and via Task Manager could see it was running at 100% for a lot of the time. Changing to two had it below 100% nearly all the time so I stuck with that. It was also noticeably faster when using two cores.

The most RAM I saw being used was about 950 MB. I’ve selected 1.5 GB to ensure it covers this easily. If you are short on RAM, you may want to tweak this.

Videos

Video of the setup process here:


Video of PIWIS use here



Having had two failures of the interface I fitted a USB fan to keep it cool and hopefully stop the failures. Video here.

 
#3 · (Edited)
My car was built Apr 2012, but by the VIN it's considered a 2013 car. I don't really understand why they do this.

Unless you setup an internet connection specifically in the VM it won't be able to talk to Porsche. I have no idea how to do this if you wanted to. I have all the functionality I want for normal DIY stuff without needing to do this.
 
#4 ·
My car was built Apr 2012, but by the VIN it's considered a 2013 car. I don't really understand why they do this.
You can thank the EPA for that. As long as one car is built in the MY year, it can be that year. So as long as they build a "2013" 981 in the Calendar year 2013, then all the cars of that production run can be a 2013. Its in the EPA statutes.
 
#5 ·
Awesome post, thanks!

Can you share the XP files, I have a XP laptop I would like to try this on.

I was a little disappointed that the cable package did not support 981/991?
 
#7 ·
That's why I asked about the model year of his car - at first I didn't see any indication that the hardware sold on obd2.market supported the 981. I also don't see how the same hardware that claims to support a 944 can work on a 981. OBD2 wasn't used before 1998.

However, the description of the unit sold on xcar360.com does at least mention the 981/991, although it's anyone's guess how to interpret it. ("981 \ 991 G value chart shows, sports performance chart shows a shift diagram shows," whatever that means.)
 
#6 · (Edited by Moderator)
might be worth teaching folks that if you already have google drive, don't download it right away - you can just click top right "Add to drive" and you will get a reference for later.

Back in the BMW land when I had my 2 series, I could use similar software to code features in/out. Euro/US features...

Is there a good listing of what can be altered with piwis "safely" ? Around features that really are just software toggles? like oh I don't know... OPEN AND CLOSE BOXSTER ROOF WITH KEYFOB? :)
 
#8 · (Edited by Moderator)
might be worth teaching folks that if you already have google drive, don't download it right away - you can just click top right "Add to drive" and you will get a reference for later.

Back in the BMW land when I had my 2 series, I could use similar software to code features in/out. Euro/US features...
Is there a good listing of what can be altered with piwis "safely" ? Around features that really are just software toggles? like oh I don't know... OPEN AND CLOSE BOXSTER ROOF WITH KEYFOB? :)
Sorry, not for you in the US! Obviously Americans cannot be trusted with this level of technology! My dealer tried to code it for me but since it knew this was US car, it would not allow the code. (the option was grayed out) but for $400, smarttop will fix this for you.

Thanks Porsche... for not trusting us.....
 
#10 ·
The link is the one above. There is the option there of purchasing the hard drive as well which you won't need.

Interestingly, I've had the interface box I purchased from obd2.market fail in the last few days. I'm in the process of getting it replaced. Whilst it is disappointing to have it fail, the after sales response from the company has been very good.
 
#13 ·
The PIWIS software lists cars all the way up to the 982. It works perfectly on my 981BS. I know others with a 981 that use it. The interfaces in the links above from both obd2.market and xcar360 work correctly with this software. I own the one from obd2.market, and I know someone else that uses the one from xcar360.
 
#17 ·
In case this helps, if you have an Android phone you can use Google Translate to take photos of the German text and translate it to English. It doesn't seem to work perfectly on multiple words that are combined to form a single word (which is common in German but not in English), but it's better than nothing.
 
#19 ·
I was able to download and install everything fine on my Windows machine. The instructions were complete and accurate. The software works without errors, at least in simulation mode. When I installed VirtualBox, I purposely chose not to install the network driver module. I'll eventually get one of those Samtec boxes so I can play around with things for real.
 
#22 · (Edited by Moderator)
#23 ·
Thanks for the offer as I didn't know that they could be extracted from the files provided? How would we know if the registry entries are correct?

I was trying to download them from here: https://mhhauto.com/Thread-Porsche-PIWIS-II-18-100-Universal-Image-Step-by-step-guide
I'm not sure of this, but I get the impression that the OP made his VM image from the mhhauto guide. There are a lot of similarities between the OP's VM and the details mentioned on mhhauto.

I have the VM fully functional on my PC, and I'm able to mount a shared folder between my PC and the VM. I can try copying all the files from the C: drive in the VM to the shared folder. That way I can access the files outside of the VM. Or I could try cloning the VM's C: drive to an ISO image, which you could then try to clone onto an external hard drive that you use to boot your laptop.
 
#25 · (Edited by Moderator)
My car is also build in spring 2012, and it's called 2013. Caused massive confusion when buying part and wheels. Until I learned to just put year 2013.
 
#28 · (Edited by Moderator)
Wow cool a PIWIS II thread! I read in MHH that the xcar360 folks are a more reputable hw source. I am in progress of ordering a set from them via PM in MHH.

I built a PIWIS One for my 987 with native XP boot and such, it rocks.(PM me for questions/interest)

Now I need a PIWIS II. I plan to try and create a TIB that will universal restore to an IBM X40 since I have a spare. (other one is PIWIS One) I have the X40 converted to mSATA.
 
#30 · (Edited)
From the MHH feedback and even in this thread, other HW sources (must at minimum get Samtec style) seem to burn out in one or two months. Some mentioned adding a fan to their units. I'm real close to ordering the xcar360 since pricing via PM is less than their posted price.

Trying to figure out what the benefit of the WiFi module (or not) is. I think you can program car keys with a connection but I think you have to pay a 3rd party for a "Porsche connection". Not sure how that works but seems an additional fee. Has anyone done this?

BTW already noted above almost all actual code changes to modules needs to be run in the "Engineering/Development Mode" which is all in German. Pretty much like "offline mode" but allowing changes as if you had a "Porsche connection" mentioned above. Don't think that mode allows Key programming.
 
#31 · (Edited by Moderator)
Does anyone else have sudenly a problem with this PIWIS 2?

I Installed this PIWIS 2 virtual box file a year ago and it was working perfect. However since today when I load PIWIS 2 the car selection screen is black... Deleted the PIWIS 2 file from virtual box and installed again and working at first startup but when I restart PIWIS 2 the menu is black again. I also installed on another laptop and same issue!! Hope anyone can help me with this.

Image
 
#34 ·
Solved my issue of black diagnostics menu in PIWIS 2. Somehow after first run the PIWIS 2 was not imprinted anymore and that's why black menu even with the new downloaded PIWIS VB file from this thread. Followed the imprint procedure on MMH auto from Turbofan and now all ok again. Hope that this will help anyone having same issue.
 
#35 ·
If you get the black menu bar as described by Rob997 above, here is the way to fix it:

When testing on another machine I had loaded this on last year, this is what I discovered.

When you start the PIWIS, if you have entered 'x' as the validationstring then the 'validity of imprint' will be blank. However, if you have entered a number, eg 9999, this number will count down as time progresses. Look at the screenshot from OnetimeCS above where the validity is 9575 days.

I noted on my machine that when I opened PIWIS (I had put in 9999 days last year) and the imprint was invalid, the validity of imprint was blank. There was also a message saying the imprint was invalid. Instead of reloading the entire VM, I imprinted it again as per the instructions below without having to import the PIWIS.ova file again into Virtualbox. If I exited out of PIWIS without doing the imprint again I ended up with the problem that Rob997 describes above that only seems to be solved by deleting the PIWIS VM from Virtualbox and then importing again.

My advice is to look at the validity of imprint when you open PIWIS each time to check it's still valid. If not, immediately go and imprint again. If you don't it seems that you will get the black menu bar when you open PIWIS again. I have made a text file of the imprint instructions and shared it with the PIWIS VM so I can immediately refer to it when required.

Imprint Instructions:

1. Open PIWIS 2

2. Go to -- SETTINGS--> Tester Imprint

3. Go to "Licence" tab - if you are unable to enter a key (boxes greyed out), go to "KEY" tab and click 'Create Key' (will generate a requirement code), and then go back to "Licence" tab

4. Enter any key and press save, keep repeating it until it says "too many faulty attempts"

5. go to "KEY" tab and click 'Create Key' (will generate a requirement code)

6. Exit PIWIS II with task manager. To exit PIWIS without shutting down the VM, right click on taskbar (at bottom), open task manager, then go to 'desktop' and end task.

7. Go to the folder "c:\user data" and locate the file "praegung.xml" (this is the 'praegung.xml' on the desktop) edit it with notepad and locate the part "demand key", delete the existing number and enter 4032546358 to replace the one in the file - save the file and close.

8. Start the piwis again, Go to -- SETTINGS--> Tester Imprint in the "KEY" tab you should see the key you have entered before.

9. go to "license" tab and enter the key below and click SAVE. This is the same key that is in the licence.txt file on the desktop that can be copy/pasted into the key.

s3nT IfSX sytP rDFo 1TRM Gw==

10. Now it should say "Tester was succesfully imprinted" and validity should show 30 days. Close PIWIS with task manager.

11. Go to the folder (use the shortcut on the desktop) "c:\user data" and locate the file "praegung.xml" edit it with notepad and locate the part "validationstring" replace the 30 by unlimited OR enter "X" number of days (eg-9999)
 
#51 ·
If you get the black menu bar as described by Rob997 above, here is the way to fix it:

When testing on another machine I had loaded this on last year, this is what I discovered.

When you start the PIWIS, if you have entered 'x' as the validationstring then the 'validity of imprint' will be blank. However, if you have entered a number, eg 9999, this number will count down as time progresses. Look at the screenshot from OnetimeCS above where the validity is 9575 days.

I noted on my machine that when I opened PIWIS (I had put in 9999 days last year) and the imprint was invalid, the validity of imprint was blank. There was also a message saying the imprint was invalid. Instead of reloading the entire VM, I imprinted it again as per the instructions below without having to import the PIWIS.ova file again into Virtualbox. If I exited out of PIWIS without doing the imprint again I ended up with the problem that Rob997 describes above that only seems to be solved by deleting the PIWIS VM from Virtualbox and then importing again.

My advice is to look at the validity of imprint when you open PIWIS each time to check it's still valid. If not, immediately go and imprint again. If you don't it seems that you will get the black menu bar when you open PIWIS again. I have made a text file of the imprint instructions and shared it with the PIWIS VM so I can immediately refer to it when required.

Imprint Instructions:

1. Open PIWIS 2

2. Go to -- SETTINGS--> Tester Imprint

3. Go to "Licence" tab - if you are unable to enter a key (boxes greyed out), go to "KEY" tab and click 'Create Key' (will generate a requirement code), and then go back to "Licence" tab

4. Enter any key and press save, keep repeating it until it says "too many faulty attempts"

5. go to "KEY" tab and click 'Create Key' (will generate a requirement code)

6. Exit PIWIS II with task manager. To exit PIWIS without shutting down the VM, right click on taskbar (at bottom), open task manager, then go to 'desktop' and end task.

7. Go to the folder "c:\user data" and locate the file "praegung.xml" (this is the 'praegung.xml' on the desktop) edit it with notepad and locate the part "demand key", delete the existing number and enter 4032546358 to replace the one in the file - save the file and close.

8. Start the piwis again, Go to -- SETTINGS--> Tester Imprint in the "KEY" tab you should see the key you have entered before.

9. go to "license" tab and enter the key below and click SAVE. This is the same key that is in the licence.txt file on the desktop that can be copy/pasted into the key.

s3nT IfSX sytP rDFo 1TRM Gw==

10. Now it should say "Tester was succesfully imprinted" and validity should show 30 days. Close PIWIS with task manager.

11. Go to the folder (use the shortcut on the desktop) "c:\user data" and locate the file "praegung.xml" edit it with notepad and locate the part "validationstring" replace the 30 by unlimited OR enter "X" number of days (eg-9999)
I follow what you are saying, but I don’t see a save button.
 
#78 ·
Hi,

I also wanted to retrofit Sport Chrono including Sport+ button.

Unfortunately I cannot get it to work - even when I place it on another button, I cannot activate it. Need to mention that I got a working unlock code for Sports Chrono for my VIN which is working in PCM and also in the climate control unit - unforunately I cannot make the button work.

Do you know how to solve this problem? I got a PIWIS II with developer mode activated - maybe you know a solution I haven't seen yet.

Thanks in advance :)