Coprolite.com
Google
 
Web Coprolite.com
SignalQ Sites:
L1G3R Information Systems - NetAdminTools - SpotBridge
RoboCoop - AreWeDown - SysAdminTools - NAW
Xfig - Gold Loaf - GeekPapa - FixGMC - FixRambler
Categories:
GNU/Linux | Homebrew designs | Perl | Microcontrollers | Graphics | Z-80 | FreeDOS | Electronics | Odyssey 2 | 8048 | Other/Msc.

Last 30 Days | Last 60 Days | Last 90 Days | All Articles/Links


Categories:
·GNU/Linux
·Homebrew Designs
·Perl
·Microcontrollers
·Graphics
·Z-80
·FreeDOS
·Other/Msc.
·Electronics
·8048
·All Categories
·Other SignalQ Websites




Creating a ROM Image with bvi
Topic:Electronics   Date: 2004-04-29
Printer Friendly: Print   Mobile View: mobile

spacerspacer
<<  <   >  >>


You can use bvi to create and edit image files. We are using this to create a poor man's PAL using old 2716 EPROMS, but there are certainly other uses. Start by setting the mode memmove. This will let you expand the file on the fly, something that is a bit rare with binary editors:

usr-1@wrk-1 o2 $ bvi ruk
00000000  01                                              .
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
:set memmove

I inserted 01. I want to fill up the ROM with that for now. The decimal repeat commands don't seem to work right with the version of bvi I'm using, but just hold down the . key, and you can fill up 2048 bytes pretty quickly:

000007B0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
000007C0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
000007D0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
000007E0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
000007F0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
00000800  
:wq

Let's check out the size:

usr-1@wrk-1 o2 $ ls -l ruk
-rw-r--r--    1 usr-1   users        2048 Apr 29 04:08 ruk
usr-1@wrk-1 o2 $ 

Cool. Let's edit FF:

000000E0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
000000F0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 02 ................
00000100  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
:wq

Bvi also comes with bmore, which we can use to verify our file:

usr-1@wrk-1 o2 $ cat ruk | bmore
00000000  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
*
000000F0  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 02 ................
00000100  01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 ................
*
usr-1@wrk-1 o2 $ 

Very nice. We can burn this image directly on to a 2716 EPROM.


People:
Places:
Things:
Times:





Please read our Terms of Use and our Privacy Policy
Microsoft, Windows, Windows XP, Windows 2000, and NT are either trademarks or registered trademarks of Microsoft Corporation. Coprolite.com is not affiliated with Microsoft Corporation. Linux is a registered trademark of Linus Torvalds. All logos and trademarks in this site are property of their respective owner. Copyright 1997-2011 Coprolite.com