Remote-Url: https://github.com/captain-amygdala/pistorm Retrieved-at: 2021-08-04 10:47:06.633508+00:00 There's a Discord server dedicated to PiStorm discussion and development, which you can join through this handy invite link:https://discord.com/invite/j6rPtzxaNWThere are also IRC channels on the Libera IRC network (irc.libera.chat):#PiStorm, bridged with the#generalchannel on Discord,#PiStorm-hardwarewhich is bridged with#hardware,#PiStorm-firmware, bridged with#firmware,#PiStorm-Amigabridged with#software-amiga,#PiStorm-pi, brigded with#software-piand#PiStorm-chat, bridged with#ot-and-chitchat.IMPORTANT NOTE: Selling blank or complete PCBs or derivatives on eBay or elsewhere for excessive profit is frowned upon and may lead to forthcoming related projects being closed source.Even with the current global chip shortage (May 2021), components are notsoexpensive that you should pay up to a hundred dollars or Euros for a board.The PiStorm is not a project for making money, it is meant to be an affordable way to replace and extend the functionality of EOL Motorola 68000 processors and have fun in the process.This is not meant to discourage you from making PiStorm boards for others to enjoy, but for instance selling the product as a commercial item and then pawning off support to the community if something doesn't work is absolutely not good™.The PiStorm itself is an adapter board intended to be paired with a Raspberry Pi Model 3A+. It goes in the DIP socket on and acts in place of the CPU, but functionality can be extended beyond simple CPU emulation.Hardware files are available inPiStorm_RevB_EPM240_74LVC16373.zip, but they may be out of date. Joining the Discord and checking for the latest revision/BoM for the PiStorm adapter board is recommended. Please note that just because it says "RevB_EPM240" doesNOTmean that all Rev B boards are EPM240s.Please note that theEMP240andEPM570used on the PiStorm board must be an AlteraMAX IICPLD. There are currently some speed grade issues with the newerMAX Vcounterparts that prevent them from functioning as a replacement.There is now an experimental bitstream available for theMAX VEPM240 part that can be flashed using theflash.shscript, but please note that this is not yet thoroughly tested and since not all silicon is created equal and this firmware requires overclocking the CPLD itself, it may not or may not work properly. Testing is currently underway.While the PiStorm should work with any DIP socket 16-bit 68000-powered system, the FC lines are currently not properly handled and no guarantees can be made for it working on anything except an Amiga 500, 500+ and 2000.General Performance with the current use of Musashi as the 68k CPU emulator is somewhere around a 70-80 MHz 68030.The intended Raspberry Pi model to use with the PiStorm is Model 3A+. 3B+ works, but due to component clearance issues it will not fit unless the Pi itself is modified (USB ports replaced) or a GPIO spacer/relocator is installed.The Raspberry Pi Zero and Model 2/4 cannot currently be used with the PiStorm, and support for these is not officially planned yet.While the BOM lists anEPM570T100C5Nas the CPLD that should be used, you can substitute it with for instance anEPM240T100C5Nor equivalent, but there are some things worth knowing.TheT100part of the component name is important, as this signifies the number of pins, make sure this is in the part name of the model you substitute the original one with.The number 5 in C5N is the speed grade of the CPLD. 5 is slower than 4 or 3, and while 4 works with the current bit stream (June 2, 2021), it cannot be guaranteed to work with upcoming CPLD bit streams, so please stick to speed grade 5 for the time being.The letter C inC5N denotes "Consumer" grade CPLD. They are available in "I" and "A" variants as well, denoting "Industrial" and "Automotive". The only difference here is the operating temperature range for the component.The letter N in C5Nsignifies that the device is RoHS compliant. If you do not require an RoHS compliant device for your board, the one with no N can also be used.While theGTvariant of the EPM240 (for instanceEPM240GT100I5N) does work, this requires some changes to the components you populate the board with, please inquire on Discord or IRC for detailed information.Since much of the initial work and testing for the PiStorm was done on Amiga computers, a number of extended features are available when the PiStorm is paired with for instance an Amiga 500:Kickstart ROM mapping: 1.3, 2.0, 3.1, anything you might own and have dumped in a byteswapped format. Extended ROM mapping as well for instance with the CDTV extended BIOS.An A1200 3.1+ Kickstart ROM is currently recommended, as this one has the most dynamic automatic configuration on boot.Fast RAM: Z2, Z3 and CPU local Fast can be mapped for high performance memory available to the CPU only on the PiStorm side of things.Virtual SCSI: PiSCSI, a high performance virtual SCSI interface for mapping raw RDB disk images or physical storage devices connected to the Pi for use on the Amiga.RTG: PiGFX, a virtual RTG board with almost all P96-supported functionality supported and accelerated.Some other things: Most likely I forgot something while writing this, but someone will probably tell me about it.Download Raspberry Pi OS fromhttps://www.raspberrypi.org/software/operating-systems/, the Lite version is recommended as the windowing system of the Full version adds a lot of extra system load which may impact performance.Write the Image to a SD Card. 8GB is plenty for the PiStorm binaries and required libraries, but if you wish to use large hard drive images or sometthing with it, go with a bigger card.Install the PiStorm adapter in place of the orignal CPU in the system, for instance an Amiga 500. Make sure the PiStorm sits flush and correct in the socket. When installed in an Amiga 500, The correct orientation on the PiStorm is with the USB port facing toward you and the HDMI port facing to the right. If the PiStorm does not stay in place properly (popping out of the CPU socket) then bend the pins of the PiStorm very very very slightly outwards. Double check that all is properly in place and no pins are bent.Connect an HDMI Display and a USB keyboard to the PiStorm. Using a USB Hub is possible, an externally powered hub is recommended. Connect the Amiga to the PSU and PAL MonitorInsert the SD into the Raspberry Pi, Power on the Amiga now. You should see a Rainbow colored screen on the HDMI Monitor and the PiStorm booting.When the boot process is finished (on the first run it reboots automatically after resizing the filesystems to your SD) you should be greeted with the login prompt.Log in as the default user, typically user:piand password:raspberry. (The keyboard is set to US Layout on first boot!)Runsudo raspi-configSet up your preferences like keyboard layout, language, etc. It is recommended to set the screen resolution to 1280x720.Set up your Wi-Fi credentialsEnable SSH at boot timeExit raspi-configYou can now reach the PiStorm over SSH, check your router web/settings page to find the IP of the PiStorm, or runifconfiglocally on the PiStorm from the console.Now the final steps to get things up and running, all of this is done from a command prompt (terminal) either locally on the PiStorm or over ssh:sudo apt-get updatesudo apt-get install git libsdl2-devgit clone https://github.com/captain-amygdala/pistorm.gitcd pistormmakeNext up, follow the steps for installing the FPGA bitstream update below. (Scroll down.) You can now start the PiStorm emulator with a basic config by typingsudo ./emulatorand hitting enter.To exit the emulator you can pressCtrl+C(on the keyboard or over SSH) or pressQon the keyboard connected to the Raspberry Pi.For Amiga, there is currently no Gayle or IDE controller emulation available, but PiSCSI can now autoboot RDB/RDSK hard drive images (and physical drives), with Kickstart 2.0 and up. Check out the readme inplatforms/amiga/piscsifor more detailed information.Install OpenOCD:sudo apt-get install openocdRun the FPGA update with./flash.sh, this will automatically detect your CPLD version and flash appropriately.If successful "Flashing successful!" will appear, if not it will fail with "Flashing failed" andnprog_log.txtwill be created with more details.