Top Banner

of 168

VBB User Manual.pdf

Jun 04, 2018

Download

Documents

bing
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
  • 8/14/2019 VBB User Manual.pdf

    1/168

    Virtual Breadboard

    Prototype Virtually, Make for Real

    www.virtualbreadboard.com

    Date Description VBB Version

    16 Oct 2012 First Draft Created V 4.19

  • 8/14/2019 VBB User Manual.pdf

    2/168

    Virtual Breadboard.................................................................................................................... 1

    Introduction........................................................................ ......................................................... 8

    FAB ervice .................................................................................................................................. 8!ircuit "mulation ....................................................................................................................... 8

    #$tem %e&uirement$ .............................................................................................................. 9

    In$tallation ................................................................................................................................... 9

    De'endencie$......................................................................................................................... 9

    (icro$o)t .*"+ 2.0... ......................................................................................................... 9

    VBB Download .....................................................................................................................10

    ,ow doe$ 'oon andbo- it wor/ ........................................................................10

    I$$ue$ ..................................................................................................................................10

    ermi$$ion$.......................................................................................................................11

    AntiViru$ ............................................................................................................................11

    Internet Activation ..................................................................................................................11

    Internet Acce$$................................................................................................................12

    (icrocontroller "mulation u''ort..................................................................................1

    Fra''uccino ..........................................................................................................................1

    Arduino !om'atibilit# Arduino +oolit 3..............................................................1

    ava A''.................................................................................................................................14

    ! V(....................................................................................................................................14

    (uvium V(.........................................................................................................................14

    O'enVBB................................................................................................................................14V18 (icro ..............................................................................................................................14

    "mulated !ircuit..................................................................................................................14

    %eal !ircuit ............................................................................................................................14

    u''ort )or Ot5er (icrocontroller$ .............................................................................1

    VBB A''lication .......................................................................................................................16

    VBB olution Orientation .....................................................................................................17

    1. VBB A''lication indow........................................................................................18

    2. VBB A''lication (enu$...........................................................................................18

    "dit ...........................................................................................................................................2+ool$ (enu ...........................................................................................................................24

    +erminal Dialo........................................................................................................................24

    ,el' (enu.............................................................................................................................2

    About..................................................................................................................................26

    De$in5eet +oolbar.....................................................................................................27

    !urrent De$in5eet.....................................................................................................27

    +5e la#out toolbar..........................................................................................................27

    +5e olution "-'lorer....................................................................................................28

    +5e 'ro'ertie$ 'anel..........................................................................................................0+5e 'ro'ert# de$cri'tion 'anel.................................................................................0

  • 8/14/2019 VBB User Manual.pdf

    3/168

    "m't# 'anel .....................................................................................................................0

    tatu$ +oolbar .................................................................................................................0

    De$in5eet +oolbo-....................................................................................................1

    *ew ro:ect Dialo.................................................................................................................2

    er$'ective +ab ...................................................................................................................2*ew +ab .................................................................................................................................

    "-i$tin +ab...........................................................................................................................

    %ecent .....................................................................................................................................6

    5at$ *ew............................................................................................................................7

    (aret lace.........................................................................................................................8

    Activatin a VBB Feature..................................................................................................8

    Activatin a )eature .......................................................................................................9

    Activatin multi'le )eature$ .......................................................................................40

    5i''in.................................................................................................................................41

    Order roce$$in.................................................................................................................41

    De$in 5eet$ ...........................................................................................................................42

    tandard "dition De$in5eet$ .....................................................................................42

    Feature "-ten$ion De$in5eet$ ...................................................................................42

    ava ource !ode ro:ect De$in 5eet..........................................................................4

    olution +ree (anaer.....................................................................................................4

    Activatin ava ource ro:ect.......................................................................................4

    !onte-t en$itive Function$ .......................................................................................4

    Add *ew ava ource File ...........................................................................................44

    Delete .................................................................................................................................4%ename..............................................................................................................................4

    ro'ertie$...............................................................................................................................46

    orin wit5 !la$$at5....................................................................................................47

    orin wit5 acae$ wit5in t5e ava ource ro:ect .......................................49

    De$in +ime ource "ditor..............................................................................................2

    ;e#word ,i5li5tin...................................................................................................2

    #nta- "rror ,i5li5tin............................................................................................2

    +ab ue$tion$ .............................................................................................................

    arameter ue$tion$................................................................................................+ole Brea'oint$........................................................................................................4

    "dit (enu< !ut< !o'# and a$te =ndo...................................................................4

    De$in +ime +ab$ ...............................................................................................................

    "rror$ +ab..........................................................................................................................

    Out'ut +ab .......................................................................................................................

    !la$$e$................................................................................................................................6

    Allocation ..........................................................................................................................6

    %untime +ab$........................................................................................................................7

    Out'ut................................................................................................................................7

    Debu>mlDoc .................................................................................................................7

  • 8/14/2019 VBB User Manual.pdf

    4/168

    Inter'retin t5e >(? na'5ot View .....................................................................60

    ?ocal Variable +ab..........................................................................................................6

    +oolbar @ ava ource !ode ro:ect..............................................................................6

    "mulation (ode .............................................................................................................6

    +oolbo-@ ava ource !ode ro:ect..............................................................................68Breadboard De$in5eet......................................................................................................69

    +oolbar @ Breadboard.........................................................................................................69

    De$in5eet @ Breadboard.............................................................................................. 72

    !om'onent "ditin .......................................................................................................72

    irin "$$ential$.............................................................................................................77

    !om'onent ?a#erin ....................................................................................................81

    +oolbo- @ Breadboard ............................................................................................................82

    V!ontrol ...............................................................................................................................8

    V18O.......................................................................................................................................8

    ro'ertie$..........................................................................................................................8

    =$ae..................................................................................................................................8

    V18O Cettin tarted +utorial...........................................................................................84

    rorammin a %eal V18O........................................................................................92

    Fra''uccino rorammin (anual.........................................................................9

    VBB"-'re$$............................................................................................................................94

    VBB 0 - 1..............................................................................................................................94

    ro'ertie$..........................................................................................................................9

    I!"5ield ................................................................................................................................96

    I!"5ield............................................................................................................................96Avatar$................................................................................................................................97

    I!"5ield Aware Driver$........................................................................................................98

    I!"5ield Aware D;$...........................................................................................................98

    Fra''uccino ..........................................................................................................................99

    ArduinoD;...........................................................................................................................99

    =no2 D; ............................................................................................................................99

    ,#brid "mulation !ircuit$................................................................................................99

    ='datin t5e I!"5ield Firmware.................................................................................99

    Breadboard !om'onent$.....................................................................................................99?a#out !om'onent$ ....................................................................................................... 100

    Ceneric ?a#out Onl#................................................................................................... 100

    Ceneric DI ........................................................................................................................ 100

    arametric........................................................................................................................... 102

    =$in t5e ?ibrar# !om'onent ................................................................................ 10

    %adial !om'onent ................................................................................................. 10

    arametric (odel........................................................................................................ 10

    ro'ertie$....................................................................................................................... 10

    A-ial !om'onent .................................................................................................... 106

  • 8/14/2019 VBB User Manual.pdf

    5/168

    arametric (odel........................................................................................................ 106

    ro'ertie$....................................................................................................................... 106

    !om'onent (odel$ ........................................................................................................ 107

    !ircuit "mulation.............................................................................................................. 107

    !om'onent (odel$ ................................................................................................... 107?i&uid !r#$tal ................................................................................................................ 109

    "mulation ....................................................................................................................... 109

    %e$i$tor$.......................................................................................................................... 111

    arametric (odel........................................................................................................ 11

    ro'ertie$....................................................................................................................... 11

    Diode$ ............................................................................................................................. 11

    !eramic !a'acitor..................................................................................................... 118

    +antalum !a'acitor .................................................................................................. 118

    "lectrol#tic !a'acitor ............................................................................................... 118

    ro'ertie$....................................................................................................................... 118

    arametric (odel........................................................................................................ 119

    ro'ertie$....................................................................................................................... 119

    arametric (odel........................................................................................................ 120

    ro'ertie$....................................................................................................................... 120

    even ement Di$'la# ....................................................................................... 121

    arametric (odel........................................................................................................ 121

    ro'ertie$....................................................................................................................... 121

    Ot5er !om'onent$ ..................................................................................................... 122

    ......................................................................................................................................... 122

    +ole .................................................................................................................................. 122

    ........................................................................................................................................ 122

    **....................................................................................................................................... 122

    ........................................................................................................................................ 122

    * ....................................................................................................................................... 122........................................................................................................................................... 122

    V%"C..................................................................................................................................... 122

    +rimmer............................................................................................................................... 122

    %ela# ..................................................................................................................................... 122

    olonoid .............................................................................................................................. 122

    olonoid .............................................................................................................................. 122

    ?oic Anal#$er........................................................................................................................ 12

    +race ?o .V?C 3 ........................................................................................................... 12

    Addin a ?oic Anal#$er ........................................................................................... 12Dra t5e De$in 5eet into a View....................................................................... 12

  • 8/14/2019 VBB User Manual.pdf

    6/168

    . am'lin !ontrol anel........................................................................................ 126

    +race ?o De$in 5eet ..................................................................................................... 129

    Addin a +race ?o ......................................................................................................... 129

    Dra t5e De$in 5eet into a View ........................................................................... 129

    ored e-am'le wit5 t5e +race ?o........................................................................ 1=$erIO................................................................................ ....................................................... 140

    DI1< DI4< DI8............. ....................................................................................................... 141

    inout................................................................................................................................... 141

    ro'ertie$............................................................................................................................ 142

    =$ae ................................................................................................................................... 142

    ?"D1< ?"D4< ?"D8.................................................................................................................. 14

    inout................................................................................................................................... 144

    ro'ertie$............................................................................................................................ 144

    =$ae ................................................................................................................................... 144

    ?edArra#................................................................................................................................... 14

    inout................................................................................................................................... 14

    ro'ertie$............................................................................................................................ 14

    =$ae ................................................................................................................................... 14

    Dot(atri-?"D8-8.................................................................................................................. 147

    inout................................................................................................................................... 147

    ro'ertie$............................................................................................................................ 148

    =$ae ................................................................................................................................... 148

    =(1< =(4< =(8 ...................................................................................................... 149

    inout................................................................................................................................... 10ro'ertie$............................................................................................................................ 10

    =$ae ................................................................................................................................... 10

    *umeric;e#ad..................................................................................................................... 11

    inout................................................................................................................................... 11

    ro'ertie$............................................................................................................................ 11

    =$ae ................................................................................................................................... 12

    e7........................................................................................................................................... 1

    inout................................................................................................................................... 1

    ro'ertie$............................................................................................................................ 14=$ae ................................................................................................................................... 14

    Diitalort ............................................................................................................................... 16

    inout................................................................................................................................... 16

    ro'ertie$............................................................................................................................ 16

    =$ae ................................................................................................................................... 16

    u$5Button ............................................................................................................................. 17

    inout................................................................................................................................... 18

    ro'ertie$............................................................................................................................ 18

    =$ae ................................................................................................................................... 18

    witc5 ....................................................................................................................................... 19

  • 8/14/2019 VBB User Manual.pdf

    7/168

    inout................................................................................................................................... 19

    ro'ertie$............................................................................................................................ 19

    =$ae ................................................................................................................................... 19

    anel(eter.............................................................................................................................. 160

    inout................................................................................................................................... 160ro'ertie$............................................................................................................................ 160

    =$ae ................................................................................................................................... 160

    lideot .................................................................................................................................... 161

    inout................................................................................................................................... 161

    ro'ertie$............................................................................................................................ 161

    =$ae ................................................................................................................................... 161

    %otar#ot................................................................................................................................. 162

    inout................................................................................................................................... 162

    ro'ertie$............................................................................................................................ 162

    =$ae ................................................................................................................................... 162

    o#tic..................................................................................................................................... 16

    inout .............................................................................................................................. 16

    ro'ertie$....................................................................................................................... 16

    =$ae............................................................................................................................... 16

    %ela#.................................................................................. ........................................................ 164

    inout .............................................................................................................................. 164

    ro'ertie$....................................................................................................................... 164

    =$ae............................................................................................................................... 164

    (ini+erminal .......................................................................................................................... 16inout................................................................................................................................... 16

    ro'ertie$............................................................................................................................ 16

    =$ae ................................................................................................................................... 16

    !(O 4000............................................................................................................................. 166

  • 8/14/2019 VBB User Manual.pdf

    8/168

    Introduction

    Virtual Breadboard i$ a $o)tware 'lat)orm de$inin EBreadboard )orm)actor

    electronic circuit$ and develo'in t5e microcontroller )irmware t5at drive

    t5em. ou can u$e Virtual Breadboard to@ Develo' and debu microcontroller ba$ed a''lication$

    roram microcontroller$ directl#

    Develo' !ontrol anel$ )or "mbedded A''lication$

    Act a$ a uide )or a$$emblin $olderle$$ Breadboard circuit$

    For documentation o) circuit$ to $5are

    +o u$e wit5 I!"5ield )or te$tin microcontroller $o)tware

    +o $end de$in$ to our &uicturn low co$t FAB $ervice to create a !B

    FAB Service

    VirtualBreadboard can al$o be u$ed wit5 t5e VBB"-'re$$ FAB $ervice $ee t5e

    ou+ube video e-'lainin more about t5e ervice.

    5tt'@GGwww.#outube.comGwatc5/vH46$o-FCoJ)eatureHu'l

    +o order a !B #ou can u'load a .VBB )ile to t5e www.virtualbreadboard.com

    web$ite

    Circuit Emulation

    Virtual Breadboard can be u$ed a$ a !ircuit "mulator )or $ome t#'e$ o)

    !ircuit$. In 'articular VBB i$ not a I!" $imulation and doe$ not re$olve circuit

    current $o #ou cannot u$e it )or circuitanal#$i$. ,owever )or a wide variet# o)

    E'5#$ical com'utin circuit$ VBB emulation$ wor :u$t )ine.

    Whats the difference between a Simulation and an Emulation?

    "mulation model$ be5aviour w5erea$ $imulation emere$ be5aviour. A

    be5aviour mi5t be to turn on a ?"D connected via a re$i$tor to a

    microcontroller 'in. A $imulation mi5t com'ute t5e circuit re$i$tance ande&uivalent re$i$tance o) t5e 'ower driver o) t5e 'in alon wit5 t5e voltae

  • 8/14/2019 VBB User Manual.pdf

    9/168

    curve and )orward voltae o) t5e diode to re$olve t5e in$tantaneou$ current

    and t5en loou' t5e lumino$it# curve o) t5e diode to render a )ait5)ul

    re're$entation o) t5e color and inten$it# o) t5e ?"D t5e u$er mi5t e-'ect to

    $ee. An emulation on t5e ot5er 5and :u$t draw$ a ?"D a$ on w5en t5e I* i$

    ,IC, and o)) w5en t5e I* i$ ?O. +5e re$ultin be5aviour )rom t5e u$er andmicrocontroller are t5e $ame. A ?"D i$ onw5en t5e 'in i$ HIGHand t5e ?"D i$

    offw5en t5e 'in i$ LO. *aturall# emulation$ are )a$ter to calculate and ea$ier

    to im'lement. VBB i$ a circuit e!ulatorand I!" i$ a circuit si!ulator.

    It$ im'ortant to under$tand t5i$ di))erence w5en u$in VBB becau$e #ou

    cannot 'lace ca'acitor$ and re$i$tor$ and e-'ect )or e-am'le be5aviour$ $uc5

    a$ )ilter$ to emere. +5ere are 5owever common wor around$ to ac5ieve

    common be5aviour$ u$in 'ro'ertie$ o) t5e di$crete com'onent$.

    System Requirements

    Virtual Breadboard i$ onl# com'atible wit5 t5e indow$ O'eratin #$tem.

    ?inu- and (ac u$er$ can ac5ieve man# o) t5e $ame re$ult$ u$in VBB"-'re$$

    w5ic5 i$ (ono com'atible and cro$$ 'lat)orm.

    Installation

    Virtual Breadboard $5i'$ a$ a $inle 'oon 5tt'@GGwww.$'oon.net3

    Virtuali$ed a''lication.

    Dependencies

    VBB i$ a .*"+ a''lication and 5a$ t5e )ollowin de'endenc#

    (icro$o)t .*"+ 2.0

    Microsoft .NET 2.0

    (icro$o)t .*"+ 2.0 or reater $5i''ed $tandard on ever# ver$ion o) indow$

    $ince Vi$ta. I) #ou are u$in indow$ > #ou will al$o mo$t liel# alread# 5ave

    .*"+ in$talled. I) not #ou can download t5e redi$tributable )rom (icro$o)t

    5ere @ 5tt'@GGwww.micro$o)t.comGdownloadGenGdetail$.a$'-/idH19

    Or )rom VirtualBreadboard.com 5ere

  • 8/14/2019 VBB User Manual.pdf

    10/168

    VBB Download

    +5ere are 2 download ver$ion$< VBB and VBBa)e.

    Installed in Spoon VBB VBBSafeVBB A''lication "#$ "

    VBB "-am'le$ "#$ "

    .*"+ 2.0 %untime %O "

    File iKe &'M( 4(b

    +5e di))erence i$ VBBa)e 5a$ t5e (icro$o)t .*"+ 2.0 de'endenc# alread#

    in$talled in t5e virtuali$ed VBBa)e.e-e. ,owever t5i$ mae$ t5e )ile

    con$iderabl# larer< tain loner to download and manae.

    (o$t mac5ine$ will 5ave .*"+ 2.0 alread# in$talled on t5em. Onl# > doe$ not

    5ave .*"+ 2.0 'rein$talled. For mo$t u$er$ t5e reular VBB.e-e i$

    recommended. ,owever< i) #ou are unable to in$tall runtime$ )or e-am'le i)

    #ou are $c5ool or i) #ou are e-'eriencin .*"+ ver$ion con)lict$< )or e-am'le

    $ome 64bit u$er$ 5ave re'orted ver$ion con)lict$. +5en VBBa)e.e-e i$

    recommended

    Download ,ere

    5tt'@GGwww.virtualbreadboard.comGdownload$GVBB.e-e 0(b 3

    5tt'@GGwww.virtualbreadboard.comGdownload$GVBBa)e.e-e 4(b 3

    How does Spoon Sandbox it work?

    'oon un'ac$ tem'orar# )ile$ into t5e de)ault u$er director# )or e-am'le onVi$ta t5i$ i$ 5ere

    !@L=$er$LM="%*A("NLA''DataL?ocalL>enocodeLandbo-LVirtualBreadboardLMVer$ionN

    Issues

    I) 'oon cannot 'er)orm t5i$ un'ac it wont be able to )unction and t5i$ 5a$

    cau$ed i$$ue$ in t5e 'a$t.

  • 8/14/2019 VBB User Manual.pdf

    11/168

    Permissions

    I) #ou are com'letel# loced out )rom a mac5ine wit5 no 'ermi$$ion$ to even

    write to t5e de)ault A''Data directl# t5en #ou wont be able to run VBB

    AntiVirus

    In t5e 'a$t $ome antiviru$ 5ave detected t5e un'acin mec5ani$m and

    determined 'oon to be a viru$. +5i$ i$ a )al$e 'o$itive and we 5ave re'orted

    t5i$ to antiviru$ vendor$ w5om all $eem to now 5ave >enocode in t5eir

    databa$e$ $o #ou ma# need to u'date #our antiviru$ $inature$ i) #ou 5ave a

    'roblem.

    Internet Activation

    VBB u$e$ internet activation to manae t5e 'a#)or)eature e-ten$ion$.

    Autou'date

    5en VBB $tart$ u' it c5ec$ t5e ver$ion online and o))er$ to automaticall#

    u'date.

    5en #ou aree to Auto='date VBB

  • 8/14/2019 VBB User Manual.pdf

    12/168

    Internet Access

    Internet Acce$$ i$ made via $tandard ,tt' ebervice$ on ort 80. +5i$ loo$

    :u$t lie Brow$er Acce$$ and $5ould 5ave no 'roblem$ wit5 )irewall$.

    ,owever< t5e 1 'roblem 'eo'le 5ave wit5 VBB i$ wit5 t5eir Antiviru$ or

    Internet ecurit#

    Antiviru$

    Antiviru$ a''lication$ reularl# 5ave a 'roblem wit5 t5e 'oon andbo-

    detectin it a$ $u$'iciou$ and blocin it in $ome wa#. +5i$ 5a''en$ w5en an

    Antiviru$ com'an# mae$ a new relea$e and t5en u$uall# oe$ awa# a$ t5e#'atc5 t5e )al$e 'o$itive. +5i$ i$ 5a''enin le$$ and le$$ but #ou mi5t 5ave to

    add VBB.e-e to t5e e-ce'tion li$t o) t5e #our AntiViru$ a''lication

    Internet ecurit# G Firewall

    A''lication$ $uc5 a$ *orton Internet $ecurit# bloc internet acce$$ 'reventin

    aut5entication and 'a#)or)eature u$eae. ou mi5t 5ave to add VBB.e-e to

    t5e e-ce'tion li$t o) #our Internet monitor andGor Firewall in order )or

    Activation to )unction correctl#.

  • 8/14/2019 VBB User Manual.pdf

    13/168

    Microcontroller Emulation Support

    VBB 5a$ emulation $u''ort )or our V!ontrol microcontroller )amil#.

    +5e emulation level i$ at t5e Fra''uccinno )ramewor level.

    Frappuccino

    Fra''uccino i$ an o'en$ource :ava 'ort o) t5e Arduino )ramewor and

    runtime librarie$ $'on$ored b# virtualbreadboard.com and muvium.com

    5tt'[email protected]'G:avac5i')ra''uccinoG

    Arduino Compatibility (Arduino Toolkit )

    ince Fra''uccino i$ a :ava 'ort o) t5e Arduino )ramewor naturall# it o))er$

    Arduino com'atibilit# w5ere t5e Arduino code can be im'orted and e-'orteda$ a ava A''. ince Arduino i$ ava ba$ed t5i$ i$ 'o$$ible in man# but not all

    3 ca$e$. +5i$ ta$ i$ 'er)ormed b# t5e Arduino +oolit.

    Fra''uccino Fra''uccino

    ! V(

    O'enVBB

    (uvium V(

    V18 (icro

    "mulated !ircuit %eal !ircuit

    #!ulation

    Arduino A'' ava A''

    I!port

    ava A'' ava A''

    Fra''uccino

    #)port

    #!ulation

    Virtual Real

  • 8/14/2019 VBB User Manual.pdf

    14/168

    Java App

    +5e ava A'' i$ t5e VBB de)ault microcontroller a''lication con$truct )or

    VirtualBreadboard. +5e ava A'' wor$ wit5in t5e Fra''uccino )ramewor

    u$in t5e )amiliar roce$$in $etu'3Gloo'3 entr# 'oint$.

    PC JVM

    On t5e ! VBB 3 t5e :ava a'' and Fra''uccino )ramewor are e-ecuted u$in

    t5e ! ava Virtual (ac5ine. In t5i$ wa# it$ not nece$$ar# to $imulate t5e inner

    worin$ o) t5e microcontroller to e-ecute t5e code at )ull ! $'eed.

    Muvium JVM

    On t5e V!ontrol microcontroller$ t5e :ava a'' and Fra''uccino )ramewor

    are e-ecuted u$in t5e (uvium ! ava Virtual (ac5ine. +5e ava i$

    converted into binarie$ t5at can e-ecute on t5e taret V18 microcontroller$.

    OpenVBB

    O'enVBB i$ t5e VBB circuit emulation in)ra$tructure w5ic5 connect$ virtual

    'eri'5eral$ toet5er to create *irtualreal time emulation$ o) circuit$

    V18 Micro

    In t5e real circuit t5e V18 microcontroller 'er)orm t5e ta$ o) interconnectin

    real circuit device$ to create real real time circuit$

    Emulated Circuit+5e VBB "mulated circuit con$i$t$ o) a collection o) com'onent$ im'lementint5e O'enVBB inter)ace$ to toet5er im'lement a circuit emulation

    Real Circuit

    +5e real circuit con$i$t$ o) a collection o) real com'onent$ wit5 electronical

    connection$ w5ic5 toet5er im'lement a real circuit )unction.

  • 8/14/2019 VBB User Manual.pdf

    15/168

    Support for Other Microcontrollers

    it5out t5e advantae o) bein able to emulate at a 5i5 level )ramewor

    level it$ i$ not 'ractical to $u''ort ot5er microcontroller$ in a virtual )orm.

    In$tead VBB inter)ace$ wit5 t5e I!"5ield to allow an# microcontroller wit5 t5e

    Arduino E5ield )orm)actor to Edrive t5e virtual circuit. In t5i$ wa# t5e

    I!"5ield become$ a =niver$al (icrocontroller "mulator.

    I!"5ield connect$ u$in =B ,uman Inter)ace Device ,ID3 'ro)ile )or

    EDriverle$$ o'eration

    ,ence t5ere are two e$$ential mode$ o) worin wit5 VBB

    *ative "mulation (ode P wor wit5 t5e V!ontrol )amil# wit5 t5e

    Fra''uccino )ramewor and o'tionall# Arduino com'atibilit# wit5 t5e

    Arduino +oolit

    I!"5ield "mulation (ode P wor wit5 an# microcontroller inter)acin

    wit5 t5e virtual circuit t5rou5 t5e I!"5ield com'onent.

  • 8/14/2019 VBB User Manual.pdf

    16/168

    VBB Application

    VBB i$ an Interated Develo'ment "nvironment )or t5e 'ur'o$e o) de$ininmlDoc< ?ocal Variable< !alltac

    Design Time Source Editor

    +5e "ditor at De$in +ime 5a$ u$e)ul )eature$ t#'ical o) modern $ource editor

    Keyword Highlighting

    +5e editor under$tand$ t5e code i$ a :ava and 5i5li5t$ t5e :ava e#word$

    $uc5 a$ im'ort< 'ublic< cla$$ < e-tend$ etc. +5i$ mae t5e code more readable

    Syntax Error Highlighting

    4

    "

  • 8/14/2019 VBB User Manual.pdf

    53/168

    +5e editor can al$o detect w5en a $#nta- error 5a$ occurred wit5 t5e :ava

    lanuae $tructure and will 5i5li5t t5e $#nta- error wit5 a red $&uile

    under$core to a$$i$t in locatin and correctin t5e $#nta- error.

    Tab Suggestions

    A$ #ou t#'e can et com'letion $ue$tion$ b# t#'in W!+%?XQW+ABX

    +5i$ will 'o'u' a conte-t $en$itive conte-t bo- ba$ed on #oure t5e te-t

    entered $o )ar.

    ou can naviate t5e $ue$tion$ bo- u$in t5e mou$e or t5e W=X and

    WDO*X arrow e#$

    re$$in W+ABX or W"*+"%X will c5oo$e t5e $elected $ue$tion and enter t5e

    te-t. +5i$ i$ u$e)ul )or ettin t5e e-act $#nta- o) a )unction ba$ed on it$ 'artial

    name

    Parameter Suggestions

    5en #ou 5ave entered a reconi$ed )unction name w5en #ou t#'e t5e EE #ou

    will receive 'arameter $ue$tion$ to 5el' com'lete t5e )unction

  • 8/14/2019 VBB User Manual.pdf

    54/168

    Toggle Breakpoints

    !licin in t5e le)t 5and marin tole$ brea'oint$ on and o)) )or a 'articular

    line o) code. Brea'oint$ are u$ed to $to' e-ecution w5en in

    "mulationQDebu mode

    Edit Menu, Cut, Copy and Paste Undo

    ou can cut< co'# and 'a$te code $ection$ in t5e ource "ditor.

    +I@ I) t5e ava ource "ditor ro:ect i$ not t5e currentl# $elected de$in $5eet

    t5e !utG!o'#Ga$te )unction$ wont wor wit5 t5e ource "ditor.

    ee Activate ava ource ro:ect

  • 8/14/2019 VBB User Manual.pdf

    55/168

    Design Time Tabs

    Errors Tab

    +5e error$ tab contain$ a li$t o) an# $#nta- error$ enerated at build time.

    5en #ou build t5e 'ro:ect t5e $ource code i$ com'iled into :ava b#tecode

    )ir$t b# :ava code 'rovider a$ a &uic c5ec and t5en $econdl# b# t5e :ava

    :ie$ com'iler. I) error$ )or eit5er o) t5e$e two :ava com'iler$ are enerated

    t5en t5e# are li$ted in t5e "rror$ tab.

    For e-am'le i) #ou mi$t#'ed util a$ uti l$ t5en t5e com'iler would locate t5e

    error.

    I) #ou !lic on t5e error in t5e "rror$ tab t5en t5e error line will be located and

    5i5li5ted in #ellow

    Output Tab

    At de$in time t5e Out'ut+ab re'ort$ de$in time in)ormation $uc5 a$

    muvium com'iler out'ut

  • 8/14/2019 VBB User Manual.pdf

    56/168

    Classes

    *ot #et im'lemented@ +5e !la$$e$ +ab will $5ow all t5e cla$$e$ included in t5e

    current build. =$e)ul )or o'timi$ation and de'endenc# anal#$i$

    Allocation

    *ot #et im'lemented@ +5e Allocation will $5ow vi$uall# and in table )orm t5e

    allocation in b#te$ o) t5e met5od$ in t5e a''lication. =$e)ul )or o'timi$ation.

  • 8/14/2019 VBB User Manual.pdf

    57/168

    Runtime Tabs

    Output

    Durin runtime t5e Out'ut tab $5ow$ t5e out'ut o) t5e $tandard out'ut )rom

    t5e emulated code

    .

    DebugXmlDoc

  • 8/14/2019 VBB User Manual.pdf

    58/168

    In "mulateQDebu mode w5en a brea'oint i$ 5it or a $inle $te' e-ecuted a

    $na'$5ot o) t5e V( memor# i$ made and 'ubli$5ed a$ a >ml document.

    +o inter'ret t5e document #ou need to now a )ew t5in$ about a V(

    :eap

    ,ea' H W %e)erence$ X

    +5e ,ea' i$ a collection re)erence$ w5ere a re)erence i$ Ob:ect or an Arra#.

    "ac5 ob:ect 5a$ an ob:ect Id w5ic5 i$ u$ed to re)erence ot5er Ob:ect$. +5e

    ,ea' i$ Carbae !ollectable $o w5en an ob:ect i$ not loner re)erenced itbecome$ available )or collection t5e ne-t time t5e Carbae collector run$. +5e

    C! run$ w5en t5ere i$ not enou5 memor# to create a new in$tance o) an

    ob:ect or w5en a u$er invoe$ #$tem.c

    eference

    %e)erence H Ob:ect Y Arra#

    ,b5ect

    Ob:ect H W Field$X

    An ob:ect i$ a collection o) Field$.

    rra

    An arra# i$ a collection %e)erence o) Data+#'e

    Arra# H W %e)erence Y Data+#'e X

    (ata3pe

    (ata3pe Short'ut -in Value -a. Value

    boolean +rue Y Fal$e

    b#te ined 8bit b#tec5ar =n$ined bit

  • 8/14/2019 VBB User Manual.pdf

    59/168

    $5ort ined 16bit

    int ined 16bit

    ?on ined 2bit

    Float 2bit modi)ied I"""

    Double 2bit modi)ied I"""

    %ield

    A Field i$ a $tore )or data t#'e or a re)erence

    Field H Data +#'e Y %e)erence

    3hread

    +5read H W F%A(" X

    A +5read i$ an inde'endent e-ecution conte-t con$i$tin o) a collection o)

    e-ecution )rame$. +5read$ $witc5 e-ecution u$in t5e +5read.#ield3 or

    +5read.$lee'3 met5od.

    3hreads

    +5read$ H W +5read X

    +5read$ i$ a collection o) +5read

    %-E

    A )rame i$ a e-ecution conte-t o) a (et5od con$i$tin o) ?ocal Variable$ and a

    O'erand tac.

    -ethod

    A met5od i$ a collection o) :ava b#tecode t5at i$ t5e out'ut o) t5e :ava

    com'ilation 'roce$$e$. A met5od e-ecute$ t5e :ava b#tecode u$in t5e )rame

    location variable$ and o'erand $tac to 5old t5e 'artial re$ult$ o) t5e

    e-ecution.

  • 8/14/2019 VBB User Manual.pdf

    60/168

    ;ocal Variables

    ?ocal Variable H Data+#'e Y %e)erence

    Are )a$t acce$$ rei$ter$ in t5e )rame e-ecution conte-t< includin t5e met5od

    'arameter$< t5at contain eit5er a datat#'e or a re)erence.

    %rame ,perand Stac

    Frame O'erand tac H W Data+#'e Y %e)erence X

    +5e )rame o'erand $tac i$ a $tac o) Data+#'e or re)erence t5at 5old t5e

    'artial re$ult$ o) t5e $tac ba$ed o'eration$ o) t5e ava Virtual (ac5ine.

    Interpreting the XML SnapShot View

    5en t5e V( 5it$ a brea'oint a $na'$5ot o) t5i$ memor# model i$ made.

    +5i$ >ml view allow$ a com'lete $na'$5ot o) t5e memor# model o) t5e V(. It

    i$ 5uman readable view but it i$ a raw view w5ic5 ot5er view$ $uc5 a$ t5e local

    variable or call$tac view con$truct t5eir view$.

    In t5e e-am'le $5own

    4

    #1

    72

    105

    3

    #0

    3

    #0

    Lets Look at this snapshot one section at a time. XML is collapsible and

  • 8/14/2019 VBB User Manual.pdf

    61/168

    DEBUG = { HEAP, THREADS }

    o D"B=C Doc3 contain$ 2 main bloc< t5e ,"A and t5e +,%"AD

    re're$entin t5e memor# model o) t5e V(

    :E)

    HEAP = { Blink, byte[] }

    +5e ,"A i$ a collection o) re)erence$< t5ere are 2 re)erence$ an in$tance o)

    OB"!+ Blin and Arra# o) t#'e b#te wit5 lent5 o) 2.

    Blink = { count, byte[] }

    +5e )ir$t %e)erence in t5e ,"A i$ an Ob:ect wit5 idH0. I$ an in$tance o) u$er

    de)ined t#'e Blin and contain$ a collection o) 2 )ield$< an inteer named

    count wit5 value o) 4 and re)erence to t5e b#te arra# $tored on t5e 5ea' wit5

    re)erence id 1.

    +5e $econd %e)erence i$ an A%%A wit5 %e)erence id H1 $o t5i$ i$ t5e

    re)erence t5at t5e Blin.b#te$ )iled i$ re)erencein. It i$ a b#te arra# o) lent5 2

    wit5 2 value$< W 72< 10 X H W E,

  • 8/14/2019 VBB User Manual.pdf

    62/168

  • 8/14/2019 VBB User Manual.pdf

    63/168

    Local Variable Tab

    +5e local variable tab i$ a view o) t5e current )rame o) t5e DebuDoc>ml.

    =$in t5e $ame data )rom t5e 'reviou$ e-am'le t5e ?ocal Variable +ab will

    con$truct a naviateable tree view wit5 $ome additional maru' to 5el' )ocu$on t5e $'eci)ic in)ormation #ou are intere$ted in.

    ,ere we can $ee t5e $ame variable$< localA< 'aram and t5i$ alon wit5 t5eir

    +#'e and value$ in a more direct view.

    +5e ob:ect Et5i$ i$ a collection o) )ield$ and we in$'ect t5e )ield$ b# clicin EQ

    to o'en t5e )ield collection in t5e view. *ow we can $ee t5e in$tance Et5i$

    contain$ t5e )ield count wit5 value 4 and t5e re)erence$ b#te$. A $ummar# o)

    t5e content$ o) t5e b#te arra# i$ $5own in t5e Value )ield but #ou can in$'ect

    t5e $'eci)ic member$ b# clicin t5e EQ

    o in t5i$ wa# #ou can naviate t5e data model o) t5e memor# $na'$5ot

  • 8/14/2019 VBB User Manual.pdf

    64/168

    'all Stac

    +5e !all tac i$ al$o a view o) a $'eci)ic 'art o) 'art o) t5e Debu>mlDoc

    and a-i$ and button wit5 a 'ullu' re$i$tor. (ove t5e mou$e over t5e e#'ad to move t5e

    o#tic in >< and clic t5e mou$e to 're$$ t5e button 'ullin t5e button out'ut to round.

    Pinout

    Properties

    *one

    Usage

    VBB raphic E@ui*alent 'ircuit

    )in &ame (escription

    1 > >A-i$ out'ut Vcc le)t3 t5rou5 Vdd ri5t3

    2 B ulled u' button. ,ou$e mou$e down to 'ull down

    " A-i$ out'ut Vcc to'3 t5rou5 Vdd bottom3

  • 8/14/2019 VBB User Manual.pdf

    164/168

    Relay

    +5e rela# com'onent i$ a model o) a D+ P $inle 'ole double t5row rela#. +5e drive circuit

    i$ included in t5i$ ideal model

    Pinout

    Properties

    *one

    Usage

    VBB raphic E@ui*alent 'ircuit

    )in &ame (escription

    1 O% %ela# olonoid driver circuit

    2 < +o' contact i$ connected to ! w5en O* H ,IC,

    C 5ared contact 'oint

    4 B Bottom contact i$ connected to ! w5en O* H ?O

  • 8/14/2019 VBB User Manual.pdf

    165/168

    MiniTerminal

    +5e mini terminal i$ a %22 terminal w5ic5 can $end a receive a$#nc5ronou$ =A%+

    communication$ at ++? level$ ie Vdd to Vcc at BA=D. !lic on t5e Creen $creen $ement and

    t#'e to $end me$$ae$. 5en 're$$in "*+"% t5e c5aracter$ $et in t5e "nter 'ro'ert# are$ent. !ommunication$ i$ $tandard 85Out6 +5e out'ut )rom w5ic5 communication$ i$ $ent

    &ame (efault ,ptions (escriptionBA=D 9600 2400 Y 9600 Y 19200 Y

    7600 Y 11200

    +5e baud rate o) t5e communication$

    "nter ?F13 !%103Y?F13Y!%103Q?

    F13

    +5e c5aracter$ $ent w5en 're$$in t5e enter

    e#

    Bit0 Bit1 Bit2 Bit Bit4 Bit Bit6 Bit7tartBit to'Bit

  • 8/14/2019 VBB User Manual.pdf

    166/168

    CMOS 4000

    Description

    4000 Dual 3-input NOR gates and inverter.

    4001 Quad 2-input NOR gates.

    4002 Dual 4-input NOR gates.

    4006 Dual 4-bit and dual 5-bit serial-in serial-out shit registers !ith

    400" Dual #o$ple$entar% &pair and unbuered inverter

    400'" 3-state he( non-inverting buer

    400') 3-state he( inverting buer

    4011 Quad 2-input N*ND gates.

    4012 Dual 4-input N*ND gates.

    4013 Dual 4-input N*ND gates.

    4014 )-bit parallel-in serial-out shit register !ith three parallel outputs.

    4015 Dual 4-bit serial-in parallel-out shit register !ith as%n#hronous reset.

    4016 Quad analog s!it#hes

    401" 4-bit as%n#hronous de#ade #ounter !ith ull% de#oded outputs+ reset and both

    401"4 6-bit D lip-lop !ith reset.

    401"5 Quad D-,%pe lip-lop

    401) 5-stage divide b% 2+4+6+) or 10/ ohnson #ounter !ith preset inputs

    401' )-to-4 line noninverting data sele#tor$ultiple(er !ith OR un#tion

    401'4 4-bit bidire#tional universal shit register !ith as%n#hronous reset

    401'5 4-bit universal shit register.

    4020 14-bit as%n#hronous binar% #ounter !ith reset.

    4021 )-bit parallel-in serial-out shit register !ith as%n#hronous load input.

    4022 3-bit as%n#hronous binar% #ounter !ith ull% de#oded outputs+ reset and both.

    4023 ,riple 3-input N*ND gates.

    4024 "-bit as%n#hronous binar% #ounter !ith reset.

    40240 O#tal inverting buers !ith 3-state outputs.

    40244 O#tal buers !ith 3-state outputs.

    4025 ,riple 3-input NOR gates.

    402" Dual - lip-lops !ith set and reset.

    402) 1-o-10 noninverting de#oderde$ultiple(er.

  • 8/14/2019 VBB User Manual.pdf

    167/168

    Description

    402'4-bit s%n#hronous binar%de#ade updo!n #ounter !ith preset and ripple#arr%.

    4030 Quad 2-input OR gates.

    4031 64-bit serial-in serial-out shit register !ith $ultiple(ed inputs.

    4035 4-bit invertingnoninverting universal shit register !ith - inputs.

    403"4 O#tal D-t%pe lip-lop !ith 3-state outputs.

    4040 12-bit as%n#hronous binar% #ounter !ith reset.

    4041 Quad buers !ith #o$ple$entar% outputs.

    404' e( inverters !ith high-to-lo! level shiter inputs.

    4050 e( buers !ith high-to-lo! level shiter inputs.

    4051 )-to-1 line analog $ultiple(erde$ultiple(er !ith dual po!er suppl%.

    4052 )-to-2 line analog $ultiple(erde$ultiple(er !ith dual po!er suppl%.

    4053 ,riple 2-to-1 line analog $ultiple(erde$ultiple(er !ith dual po!er suppl%.

    4066 Quad analog s!it#hes.

    406" 16-to-1 line analog $ultiple(erde$ultiple(er.

    406) )-input *NDN*ND gate !ith #o$ple$entar% outputs.

    406' e( inverters.

    40"0 Quad 2-input OR gates.

    40"1 Quad 2-input OR gates.

    40"2 Dual 4-input OR gates.

    40"3 ,riple 3-input *ND gates.

    40"5 ,riple 3-input OR gates.

    40"6 4-bit 3-state D lip-lop !ith reset+ dual #lo# enables and dual.

    40"" Quad 2-input NOR gates.

    40") )-input ORNOR gate !ith #o$ple$entar% outputs

    40)1 Quad 2-input *ND gates

    40)2 Dual 4-input *ND gates

    40)5 Dual 3-!ide 21-input *ND-NOR gates

    40)6 6-!ide 21-input *ND-NOR gate.

    40'4 )-bit 3-state serial-in parallel-out shit register !ith output lat#hes.

    4502 )-bit 3-state serial-in parallel-out shit register !ith output lat#hes.

    4510 7D updo!n #ounter.

  • 8/14/2019 VBB User Manual.pdf

    168/168

    Description

    4511 7D to "-seg$ent lat#hde#oderdriver.

    4512 )-input $ultiple(er !ith 3-state output.

    4514 1-o-16 de#oderde$ultiple(er !ith input lat#hes.

    4515 1-o-16 de#oderde$ultiple(er !ith input lat#hes.

    451' Quadruple 2-input $ultiple(er.

    453' Dual 4-input $ultiple(er.

    4543 7D to "-seg$ent lat#hde#oderdriver.

    4555 Dual 1-o-4 de#oderde$ultiple(er.

    4556 Dual 1-o-4 de#oderde$ultiple(er.

    4"31 Quadruple 64-bit stati# shit register.