-
Video Demostration of Graphics on Edison!
07/30/2015 at 08:55 • 0 comments(The last) Link to VGATonic video card!
-
Load Edison with Fun!
07/30/2015 at 08:03 • 0 commentsYou're all set now, go get things that use the framebuffer! I didn't go for X.org, but here's what I tried:
- SDL Quake (remove -mpentium from configure before build)
- Get SDL 1.2: https://www.libsdl.org/download-1.2.php first; the prereqs can be annoying - Google when/if you hit libPNG errors, you just need to rename the NULLs.
- Nano-X (this one took some work to compile, you should use Alex-T's Repos)
- Dosbox (It uses SDL)
- Quake (Yeah, I have two ways to run Quake - weird)
- Warcraft
- Simcity 2000
- Not sure, only tried those three... probably most anything, though.
- DirectFB (I had issues, but lots of demos will run)
The great AlexT's Edison repos: http://alextgalileo.altervista.org/edison-package-repo-configuration-instructions.html
- SDL Quake (remove -mpentium from configure before build)
-
Loading the Framebuffer and Getting Mouse Support
07/30/2015 at 07:52 • 0 commentsLoading the framebuffer is simple. Assuming your .ko files and pinmuxing file are in the same directory, 'cd' to it and run this line:
./oldpinmux.sh; insmod vgatonic.ko; insmod edison_vgatonic_spi.ko;
You should very quickly see a patchwork appear on the monitor (if you're using VGATonic, that is!), then fbcon will steal the framebuffer almost immediately, and you'll see this:
You've got a monitor working! (But why quit there?)
Next, switch the user switch next to the full USB port on the Edison's Arduino breakout towards the larger USB port, and plug in your keyboard and mouse. If you're like me, now you'll see new event devices in /dev/input - so go get GPM.
DON'T GET THE 1.2 VERSION! I know it's the popular one, but do what it takes to compile the newest version from Github: https://github.com/telmich/gpm ( Commit e55e60cc492b51ced88b5637eded7130d5afef9f if you want to copy me exactly)
Here is how I set up my mouse, yours will likely be similar:
gpm -m /dev/input/event5 -t evdev -R
You can test it's working by: cat /dev/gpmda*
(Move the mouse, click, etc - you'll quickly know you got it!).
To Kill The Console!
Depending on what you do next, you may want to kill fbcon - it has a tendency to steal the framebuffer back from some things (like Nano-X). Here's how you kill it:
echo 0 > /sys/class/vtconsole/vtcon1/bind
echo 0 > /sys/class/vtconsole/vtcon0/bindI assume you can do that in reverse to bring it back, but I tend to just use my Macbook to run commands before switching to the keyboard/mouse on the Edison.
-
Getting a Working Framebuffer Driver
07/30/2015 at 07:33 • 0 commentsI encourage you, of course, to build the SPI VGA Video Card I'm working on for the 2015 Hackaday Prize, VGATonic - you can find everything you need between the Hackaday Project Page for VGATonic and the Github Repo.
Realistically, though, most of you don't want to wait for PCBs, so FBTFT will almost definitely work as well - please let me know if you get it running!
So, flash your kernel to Edison first, then come back here.
Here's how I cross compile the VGATonic framebuffer for Edison (you're on your own for FBTFT):
- git clone https://github.com/dqydj/VGAtonic.git # Put this somewhere
- bitbake -c devshell linux-yocto # (In the bitbake window you compiled the kernel in)
- #Now, in the popup window, copy the VGATonic/VGATonic_Linux_Drivers directory directly into the current directory, /linux
- Rename Makefile_Edison_Rename_and_Cross_Compile to Makefile
- make
- scp it to your board (all .ko files)
You also need to copy my pinmuxing script; I haven't yet added everything for initialization to the board specific file (after the HaD prize, perhaps?). Here is a copy. It works great as long as you run it before loading the kernel module.
-
Compiling the Kernel With Framebuffer Support and DMA to SPI
07/30/2015 at 07:22 • 0 commentsYou should, of course, start with a cross compilation setup. I'm using Ubuntu 14.04 in Virtual Box just fine. I'm starting with the 2.0 version of the Image/Board Support Package . I can't guarantee it will work with the newer version; if you get it working let me know!
A few changes have to be made to the kernel on the Edison before the framebuffer will work. Namely, the following things have to be enabled:
CONFIG_FB=y
CONFIG_FB_SYS_FILLRECT=y
CONFIG_FB_SYS_COPYAREA=y
CONFIG_FB_SYS_IMAGEBLIT=y
CONFIG_FB_SYS_FOPS=y
CONFIG_FB_DEFERRED_IO=yHere is the config file I used. Copy it to /meta-intel-edison/meta-intel-edison-bsp/recipes-kernel/linux/files/defconfig in your BSP/cross compilation setup.
There are issues with SPI on the Edison with the 2.0 image - DMA won't work, and you'll be capped at 6.25 MHz SPI speed. Luckily smaguire and jkramarz have saved everyone a ton of work and got working DMA SPI writes at 25 MHz.Install that patch, then build. Just do it overnight - it'll take a while. This page is an excellent reference for building the kernel.
-
Getting the Hardware Ready (Prerequisites)
07/30/2015 at 07:13 • 0 commentsI did this with the Intel Edison Arduino Breakout Board. I assume it is possible using other methods, but I can't comment from experience.
As for a display, I'd love if you tried my VGATonic VGA SPI video card, my entry to the 2015 Hackaday Prize. The feature I'm taking advantage of is the minimal (like, 2/307202 %) overhead SPI framebuffer.
Everything you need to build VGATonic can be found on that page or in the Github repo.
There is no reason why you can't do it with notro's excellent FBTFT as well.
25 MHz SPI at 5v on the Arduino breakout with this setup is rough: my jumpers are 8 inches or so long, and you're looking at about 3 connectors and another 3-4 inches between silicon. So, twist your SPI wires up with +5v and Gnd (I use Gnd with Chip Select - that is the most sensitive) to protect your signals as best you can (or use shorter/better wire!):
That's the standard pins for MOSI and SCK (11 and 13), and a custom chip select - pin 8.