Papilio user Matthew Hagerty put together a very nice implementation of a simple SDRAM controller for the Papilio Pro FPGA. Written in VHDL, it sacrifices some speed for ease of use and simplicity. After all, not every project needs to use the full capacity of the SDRAM chip.
You can read about his epic adventure learning the ins and outs of SDRAM, simulating his code, and finally running on hardware in this forum thread.
Or, just skip right to the SDRAM code.
It can be a lonely task working on something like this, so we wanted to congratulate Mathew and give a big virtual high five for his awesome work!
Forum member Offroad recently hit us up with an example project, which is based on the Papilio Pro and the RetroCade Synth. He’s calling it the Really Dumb MIDI Monitor. This deserves a bit of explanation:
For starters, Offroad explains what he means by the term, “really dumb meaning: All the fun stuff like printf(“%02c”, byte) happens in RTL state machines…”
The project includes a simple MIDI parser for note on-/off messages. It remembers the state of all keys (all channels are combined, “omni mode”). Maybe this could be useful for some MIDI music experiments with minimal fuss: Excluding UARTs and FIFO (reused modules), the actual RTL code that does all the work is only about two screen lengths.
Here are a couple of links to the actual examples that he created, so make sure to click through and check them out for yourself.
- Papilio Pro MIDI Monitor – (zip file)
- meepMeep – (zip file) – This one is a MIDI monitor that actually makes an audible impression with an 18-bit saw waveform. Offroad says it sounds like a Farfisa! (See image above) Yikes indeed!
Do any of you guys have anything interesting that you’re working on for the RetroCade? We’d love to hear about it! Feel free to post to the forums, or comment on this post! Right on.
(via the forums, and thanks to Offroad)
Papilio Pro user James Glanville recently posted a great project that he’s been working on, over at the Gadget Factory forums. He was nice enough to share his code and some photos for the project, in which he has got his Papilio Pro hooked up to an old laptop LCD display that he had sitting around the workshop.
Here’s an excerpt from James’ project, as posted on the forums:
Hi, I’ve been playing with my ppro, and have got it talking to an old laptop lcd I had. I was amazed at how easy this was, so I thought I’d post a few pictures and some code. So far it draws a picture of yoshi (stored in rom), and animates a square that grows as it moves. Not very impressive, but I feel like I’ve laid the groundwork for my next experiments.
The yellow cable is just the original cable that would plug into the motherboard, wrapped in heatshrink for strength, with the 4 differential pairs plugging into C8-C15 (You can’t plug this into any port, not all of them have a full set of differential pins for LVDS). The black circuit board is a 3.3v step down converter to power the lcd electronics. The brown one is an inverter for the cold cathode backlight (I broke the original by shorting the HV to something). The fan is there because I’m overvolting the inverter (18v instead of 12v), and it gets a little warm without.
James points out that this really is a great way to get a display going for your Papilio for next to nothing – discarded laptop LCDs are pretty easy to come by! If you don’t have one, maybe think about swinging by your local hackerspace or thrift store.
We’ve got you covered in the details department:
Thanks for sharing your project with us James! It’s great to see you guys repurposing components that would otherwise be taking up space in the landfill. And keep sending in those projects, folks!
(via the forums)
Papilio user James wrote in on the the forums about his LCD display project that he has been working on. James is using his Papilio, a junked old Epson EG2401 monochrome LCD display, and a buffer board that he built from scratch. It’s similar to another junked display project that we posted a while ago, yet totally unique because he’s using a different display, which brings its own challenges that had to be worked out. Here’s what James had to say about the project:
[I’m working on] an old Epson EG2401 display. It doesn’t really have enough pixels for Lena, and a single dual-port block RAM suffices as the frame buffer. I made a buffer board to produce 5V logic for the LCD (using 74AHC541s) and used a MAX232 to generate the needed negative voltage.
I’d already done this with an AVR, and was able to get reasonably good grayscale by only setting lighter pixels for some fraction of updates. I might try that as my next step here. Avoiding flicker does require “overclocking” the display a good bit past what it was rated for, mine seems very tolerant of such abuse (I only started getting glitches when I gave it a 32 MHz pixel clock with the FPGA controller).
James has posted his code for the project on his GitHub here if you’d like to take a look under the hood!
We always love featuring your projects here on the blog, for the world to see what flavors of coolness you guys are dreaming up. So please! Keep sending them our way. A big thanks to James for sharing his work with us!
(via the forums)
Forum user Matt Ownby has put together some code to be able to write data at full speed (50 MHz) to an SD card, and was kind enough to share it with us! This is VHDL code for the Papillio One FPGA board that shows how to write to an SD card in a high-speed mode.
Here’s the lowdown on Matt’s work, per his description from the forums:
VHDL SD card writer v1.0 Features:
– Uses 4-bit SD mode, not 1-bit SPI mode (faster)
– Uses 50 MHz “high speed” mode, not 25 MHz “normal speed” mode (also faster)
– Logs to Papillio USB serial port (230400 bps) so you can see what is going on
– An SDHC card (older probably won’t work) that supports high-speed aka 50 MHz mode.
How to use:
– Get the pins of an SD card (or adapter) somehow connected to Papillio pins. Not discussed here as you are expected to have enough expertise to figure this out on your own
You can find the code (with readme) here.
Many thanks to Matt for sharing this with the community! Go ahead and give it a whirl, and let us know what you think in the comments section as always!
(via the forums)
Forum user and regular contributor Alex recently dropped us a line on the forums. He was saying something about getting new arcade games running on the Papilio Pro with the Arcade MegaWing. Turns out he’s got three arcade games going (Ladybug, Dorodon, and Cosmic Avenger) and is using a PS/2 keyboard for controls. Alex says,
[The games] will fit entirely into a Papilio Pro or any Spartan 6 FPGA without needing any external RAM or ROM. Getting this ported to the Papilio was just a matter of writing a top level module to connect the ladybug machine to the various ROMs and input controls.
To make it all work, download the source then download and place the game ROMs into the appropriate ROMs folder. See the readme file in each folder for a list of the files and checksums you should be looking for, If you’re on Windows, run the make_roms batch file in the relevant game rom folder. Game ROMs will be converted to vhdl files in the build directory. If you’re on linux, there appears to be a makefile based system for creating ROMs and other files in the hex folder, seemed to work for me in MinGW, but I use Windows primarily. Once the ROM files are converted to VHDL, run the ladybug_papilio.xise project in the top directory and synthesize then upload to your board. You need a Papilio Pro with a Arcade Megawing and a PS2 keyboard in port “PS/2 B”, VGA and audio connected.
Why not try these games out for yourself? Here are some links to get you started:
Many thanks to Alex for his contribution! Feel free to add your own $0.02 in the comments. And as always, if you have anything you’re working on that you’d like to share with the community please send it our way!
(via the forums)