VMLAB User Components

Here are some of the VMLAB user components that I have created. All components come with the C++/RC sources and the binary DLL files (compiled with VMLAB's usercomp.exe and the Borland BCC55 command line tool kit).

The components currently available are:
  • AVR Peripherals - Components to emulate the AVR peripherals found in the ATmega168 microcontroller.

Future Component Ideas

I have a number of ideas for new components that I could implement in the future. Unfortunately, I can only work on this in my spare time so many of these components will probably never get written. Of course, if anyone else reading this page wants to help, then please get in touch with me (see Contact section below); you would be more than welcome. At least two of these components, the MMC/SD card emulator and the NTSC/PAL video display emulator, would be much easier to implement if the VMLAB source code was released under the GPL, allowing me to re-use code from existing GPLed projects. Here is my list of ideas for new components and improvements to existing ones (in no particular order):
  1. bounce - Simulate digital glitches caused by a physical switch bounce; for testing de-bounce code or RC filters
  2. spicelog - Log analog signal as SPICE PWL voltage source to text file
  3. vcdlog8/16/32 - 8/16/32-bit VCD logger
    • Use named shared memory segment with 1-bit vcdlog component
  4. a2d8 - Ideal (zero conversion time) analog to digital converter
  5. lptxch - Interface to real LPT port with the winring0 and/or inpout32 drivers
    • Could also use the winparport library for more limited unidirectional access but without requiring a kernel mode driver
    • 8 bidirectional data pins
    • 5 status inputs pins
    • 4 open collector control output/input pins
    • 1 data direction pin
    • 1 control direction pin
  6. sdcard/mmcard - Emulate a SD/MMC card in SPI mode
  7. freqdisp - Frequency/PWM/RMS display
    • Include button to remove DC bias from RMS
    • Show RMS and RMS^2 (for power estimation into resistive load)
  8. stepmtr - Stepper motor position/velocity/distance travelled display
    • Two input pins: direction and step
    • Maybe additional components for direct drive of unipolar/bipolar motor?
    • Maybe analog output encoding the position? It could control output of a rotary encoder for example.
  9. servomtr - PWM controlled servo motor with position/velocity display
    • Similar to the stepmtr component above
  10. vlptxch - Interface to backend of virtual LPT port
    • Modify the usb2lpt driver for this to work
    • Maybe communicate over a named pipe or named shared memory segment?
    • Could buffer/timestamp transactions for accurate delays
    • To get accurate timing, would we have to block client app?
  11. galXXXX - Simulate Generic Array Logic ICs at fuse level
  12. spitty - Display SPI traffic in a similar fashion to the built-in tty and tty2 components
  13. USBN9604 - Simulate this USB to FIFO chip
    • Could communicate with the USB/IP Windows client using a loopback network socket
    • Could use a custom modified LibUsb-Win32 library that client applications re-compile with for simulation
    • Could use a kernel mode virtual USB host controller driver; one possible starting point is the ReactOS USB Stack
    • Could use the Win32 Device Simulation Framework; not sure if users would need to install the DDK
    • Could modify the OHCI/UHCI code in the Bochs x86 emulator to support virtual USB devices from user space
    • Could modify the UHCI code in the QEMU x86 emulator/virtualizer to support virtual USB devices from user space
    • Would allow complete simulation of USBprog in VMLAB
  14. usbxch - Generic encoder/decoder for a raw USB serial stream
    • Use same techniques as USBN9604 component to communicate with host Windows system
    • Would allow simulation of software USB stacks like V-USB and USBtiny
    • Would allow simulation of AVRs with USB hardware using the new peripheral component interface
  15. mcp23s08/s17 - SPI 8/16-bit I/O port expander
    • There are several other port expanders that can be simulated
  16. ntscdisp/paldisp - Baseband video signal (black and white) display emulator
  17. rotenc - Rotary gray code encoder
  18. stepcnc - Simulate stepper motor controlled 1 to 6 axis CNC machine
    • Changes in stepper motor position are logged to file in G-Code format
    • One stepcnc component per axis; instance name specifies axis
    • The tool path can be visualized by opening the G-Code file with CNC Simulation software.
  19. systemc - Provide the tools and libraries to convert SystemC modules into VMLAB user components
    • The Pinapa SystemC front end may be usefull in generating the VMLAB specific wrapper code
    • The Verilator Verilog to SystemC/C++ compiler can help convert Verilog modules to VMLAB components

Contact

You can contact me either by posting in the VMLAB user forum or by emailing me directly. I have a Gmail account with the user name "thvortex".

Copyright

Creative Commons License The contents (HTML and images) of this website are licensed under the Creative Commons Attribution-Share Alike 3.0 United States License.

Public Domain License Unless otherwise noted, all of the downloadable VMLAB components (binaries, sources, and project files) found on this website are released as Public Domain so they can be bundled (or statically linked to) and distributed with VMLAB if AMTools so wishes.

Disclaimers

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.