I think this is a fantastic idea. Good luck with it!
Be sure to update us all here with your progress!!! Some posters have a habit of talking about ideas but never following through with implementation. I know I've done that myself, but work and real life tends to use up the time I'd rather spend doing fun things.
So... don't be like me! Make some real progress and let us know how you get on. That will silence the non-believers for good!
VHDL on 6502?
Re: VHDL on 6502?
I worked with some VHDL and mostly Verilog in my professional career targeting FPGA and complained of slow workstation, hour-long simulation, and buggy synthesis. Love to see real work done with VHDL on 6502. That’ll shut me up.
Bill
Bill
Re: VHDL on 6502?
sark02 wrote:
I think this is a fantastic idea. Good luck with it!
Be sure to update us all here with your progress!!! Some posters have a habit of talking about ideas but never following through with implementation. I know I've done that myself, but work and real life tends to use up the time I'd rather spend doing fun things.
So... don't be like me! Make some real progress and let us know how you get on. That will silence the non-believers for good!
Be sure to update us all here with your progress!!! Some posters have a habit of talking about ideas but never following through with implementation. I know I've done that myself, but work and real life tends to use up the time I'd rather spend doing fun things.
So... don't be like me! Make some real progress and let us know how you get on. That will silence the non-believers for good!
plasmo wrote:
I worked with some VHDL and mostly Verilog in my professional career targeting FPGA and complained of slow workstation, hour-long simulation, and buggy synthesis. Love to see real work done with VHDL on 6502. That’ll shut me up.
Bill
Bill
https://handmade.network/p/625/6502-the-spreadsheet
is a good start I reckon.
our first goals are to build software, simulation is a goal, mostly for audio or simple logic circuits
im using the general purpose features of vhdl here first
synthesis to a cpld or fpga is possible, I am unlikely to write the subprogram for that myself, however, vhdl;65 should be compliant enough at some point its output should be portable
writing schematics or soomething, the 'netlist', turned into a svg file is good, or a png
our simulator, might be more like circuitverse or logisim
from earlier discussion:
Tricky, ToVine, Piasa, sigstoat and others on the Digital Design server were asking a lot of questions here, similar concerns and questions as you all had here. Ive edited the order and taken out links to memes and irrelevant chatter.
Quote:
Then, I'll go into each one, and make a column next to it, with the 6502 Assembly that is, or performs that command.
im not sure 2019, maybe original. 93 or 2002 to start
not 2008/2019 yet, too much to add there for now
to make it easier to implement vhdl is a self hosting environment on that platform
sigstoat — Yesterday at 5:25 PM
there's not even a 1 to 1 mapping between constructs in C and assembly language. thinking that you can put together a mapping from VHDL to 6502 assembly is surreal.
they don't even do the same thing.
it'd make more sense to talk about a mapping from sheet music to 6502 assembly
Wayfarer — Yesterday at 5:26 PM
well several things are assembly itself, like rotate, shift, add with carry, etc. things like that are 'easy'. because the 6502 doesnt have hardware multiply, ill have to add an assembly routine to do that; how would you then compile vhdl, to 6502
every vhdl operation, can be performed on a 6502. its a general purpose language on a turing complete computer
now a compiler, (usually) takes a text file, turns it into 'tokens' and parses those to turn them into assembly (well, machine code) for that hardware; at the moment. my concerns are getting a minimal environment set up to to Edit vhdl, including textio and file operations. an editor, an analyzer, including a parser, and then a way to elaborate that file, then a simmulator and waveform viewer. all of these have to be developed.; i plan to use the vhdl editor/parser, and the analyzer, to create a file, that could then be elaborated into a runtime program. I have to make that in ASM, then use asm and my software editor, to make the rest of vhdl, from this,
to be an implementation, i have to have files and text, this environment, is the 'OS' here
so knowing exactly how to turn my vhdl code into 6502 operations is one of the best things i could do
to use vhdl as a general purpose language and write software for this obscure hardware
Tricky — Yesterday at 5:45 PM
to what benefit?
other than an odity
Wayfarer — Yesterday at 5:46 PM
i like 6502s and use them for computing
Piasa — Yesterday at 5:47 PM
that might be the misunderstanding. vhdl isn't really intended to be used as a general purpose language. and it's not intended to "write software" for obscure hardware. it's nifty that it can describe HW constructs, but at its heart, VHDL is for simulation of digital systems.
Wayfarer — Yesterday at 5:47 PM
vhdl is a general purpose language.
Piasa — Yesterday at 5:47 PM
barely.
Wayfarer — Yesterday at 5:48 PM
its not implemented to be used that way and is not supported for this purpose on most major platforms
Tricky — Yesterday at 5:48 PM
any platform
Wayfarer — Yesterday at 5:48 PM
however, "in 6502 land", you do everything yourself, so I can use, basic, forth, a poorly functioning C, or I can 'roll my own'
im choosing to use vhdl over C, its less strict to implement
Piasa — Yesterday at 5:49 PM
you're not wrong that it's possible to do. it's basically how a lot of simulators work. by using vhdl/verilog to generate some executable that can run on the host computer.
Tricky — Yesterday at 5:50 PM
surely all of them...
Wayfarer — Yesterday at 5:50 PM
ok, so ghdl shows you can make a simple text program in vhdl, and you have the phi now, etc
so, I could 'write basic again', try to make C better, or get used to RPN and use forth, or, I can learn more about both vhdl and 6502s, and get a cool custom OS/IDE out of it for audio circuits and discrete logic, (or write programs that map as close to the hardware as possible because I made it that way)
so, "VHDL:65" might be an implementation with a different focus
Tricky — Yesterday at 5:54 PM
I look forward to seeing it listed here one day: https://en.wikipedia.org/wiki/Esoteric_ ... g_language
Wayfarer — Yesterday at 5:54 PM
maybe it turns into 'Aardvark', a dialect of vhdl more for programs, that 'describe how the hardware is used', rather than 'describe how the hardware is laid out'; and "Anthill" is our IDE/AS (integrated development environment analysis system)
ok, well for one to learn more about both; and two, i need a 6502 text language environment
it doesnt get one, its not like PeeCee land, you have to program the micro-computer to do everything,
ToVine — Yesterday at 5:58 PM
And you chose one of the least practical ones for the job? :SufferingInside:
Wayfarer — Yesterday at 5:58 PM
except when I read the LRM, I see 6502 asm everywhere
Piasa — Yesterday at 5:58 PM
that's what I was saying. a lot of the constructs are simulation-related. so you're eventually writing a simulator more than anything else. unless you restrict the vhdl to just a programming subset of features.
Wayfarer — Yesterday at 5:59 PM
a simulation is a program, and can have subprograms.
Piasa — Yesterday at 6:00 PM
I was thinking more of the delay modeling stuff. and common cases like having more than one vhdl process in a design. to get that to work in a sane fashion, you're starting to need the scheduler and other sim stuff.
Wayfarer — Yesterday at 6:01 PM
like 'systems programming with vhdl' might require different techniques than 'simulation programming with vhdl'
Piasa — Yesterday at 6:01 PM
which is fine. it just means a significant amount of the development is going to be related to re-creating simulator mechanics. to the point that you're not really compiling anywhere close to 1:1 code->asm.
Wayfarer — Yesterday at 6:02 PM
depends on what we do with it
like, I see vhdl almost like Flash, its got a timeline built in, support for multiple timelines
vhdl, 'isnt really all that different'
i have to create an OS and software for the 6502, I have limited choices. I love vhdl,, and it has ascii built into it, so thats a plus here, ok so I need a text editor, even a command line, I need a way to program, thats easier to see, to work with, than ASM. i have to pick, basic, forth, or a few other odd languages I didnt just spend 5 months learning. or, I can do this work and use vhdl instead.
Piasa — Yesterday at 6:15 PM
6502 isn't that big. so it might make sense to define a subset of vhdl that is supported as well as intended ways to write code. along with practical optimizations like replacing "+" with normal addition. ("+" is normally a function). likewise, handling 'x', 'u', '-', etc... vs just '0' and '1' could be a needless complication. same with tristates/inouts in general. either way, it seems like forcing a square peg into a round hole.
Wayfarer — Yesterday at 6:17 PM
not at all, its just a matter of doing things one step at a time, the 'should' is actually a good thing here
i will learn a lot and advance knowledge, without really hurting anyone, unless you are afraid this is how skynet gets built?
Piasa — Yesterday at 6:19 PM
this is not how skynet gets built.
Wayfarer — Yesterday at 6:19 PM
terminator runs on 6502
Piasa — Yesterday at 6:22 PM
it's fine for education. basically learning how to make a simulator. but there's various "design for ..." aspects of VHDL that won't get exercised. as long as you don't have any time constraints it seems fine. just more difficult than existing options like using a C compiler or modifying a C compiler.
Wayfarer — Yesterday at 6:22 PM
i dont expect to simulate more than was done on 8bit and 16bit computers in the 80s and 90s, synthesizing an fpga, or cpld, to use in those 8 bit computers, sure; address decoder on a cpld, or fifo buffer usb thingamajig, sure. a video card with vulcan, no. audio circuits
thats a big one, audio stuff, video games, interfaces to old things, controllers.; then again, I can get a 6502 core and run it at 100s of Mhz if i want
Piasa — Yesterday at 6:35 PM
if you drop back to something that looks like pascal/delphi/ada -- all designed to be compiled and run as software -- it's probably not that bad.
Wayfarer — Yesterday at 6:38 PM
be specific, a language is just a language, software for that language is going to vary
concurrency, might need to be avoid and programming techniques, like not overloading the system, should be utilized, if I want to say, add some floating point numbers, and maybe, do some statistics, ok, I can use windows or unix; or a custom system (which is our choice)
Piasa — Yesterday at 6:40 PM
i was already assuming precompiled packages for common packages like math_real, std_logic_1164, textio, numeric_std, etc...
Wayfarer — Yesterday at 6:41 PM
maybe at some point, standard, texio and file, give us an os
here:
Wayfarer — Yesterday at 6:48 PM
multitasking is inherently built in. concurrent processing is the |norm|.
Piasa — Yesterday at 7:06 PM
correct. and that's one concern.
Wayfarer — Yesterday at 7:10 PM
The second part of a minimal VHDL design description is the architecture declaration. Before simulation or synthesis can
proceed, every referenced entity in a VHDL design description must be bound with a corresponding architecture.
so, lets say for a second simulation, I need to map all those entities to how they are simulated on the hardware. its a multiple entendre'
they mean your entity declaration, except how would I represent that on hardware at all, or a hardware to vhdl simulation, without that mapping, so, spreadsheet city
Wayfarer — Yesterday at 8:15 PM
alright, most of the datatypes are just 'data' and are just simple routines in assembly to read, write, and represent. ieee floating (or fixed!) point math needs to be implemented, though starting with: Bit, Char, enum, boolean, integer, and Ill basically need most of array and record to do anything else, those are 'memory arrangement structures' that have a table, index and rountines in assembly to use them, so these give us the floating points and vectors and such, line for textio, etc
then, we build file, and thats 'almost' an OS. the part that is difficult, is time, and it requires a clock or reference clock of some kind.
then its operators, and many are 1:1 vhdl to 6502 asm, some are a few instructions, a couple a bit longer, type conversion and operators on 'bigger datas' will be harder to implement, like = an array
a few of the functions are going to be tricky, while the signals, delayed, transaction, quiet, may give us a built in event system and messaging; then, its concurrency
Piasa — Yesterday at 8:29 PM
it seems that way as long as you make reasonable restrictions. something like x + 1 could have gotcha's. what if x = "1100xxxx"? what if x is 7 bits vs 8. this also assumes special logic for things like numeric_std, otherwise x + 1 (and most operators) are implemented with for loops. that seems more annoying than copying values from a larger object.
Wayfarer — Yesterday at 8:35 PM
yeah for sure. something I see, is like, if you want to write a program, then maybe only having one process, is a good idea, this also means that to implement vhdl, one has to implement multithreading/multitasking
Wayfarer — Yesterday at 8:47 PM
programs. simulation instructions to be run on the native hardware, might make use of variables more, as they behave in a more expected manner. some loops, generates, and branch structures, might be tricky, as they are nuanced and unique.
blocks are interesting, we do have the FOREIGN keyword, so we can have our vhdl program be the OS or kernel, and still use other languages on our operating system, A design library is defined in the VHDL 1076 standard as "an implementation-dependent storage facility for previously analyzed
design units"... thats a dll
Piasa — Yesterday at 8:57 PM
it's closer to namespace
Wayfarer — Yesterday at 8:58 PM
assert and report give error handling stubs, 97 keywords, though most are not common, or are boolean operations
the Event process handler, has to be well written, and it needs a self balancing queue thats not prioritized, and doesnt skip or ignore processes; otherwise, its not really that much different, than adobe flash. no really, there is a logic sorting system that has to be recursive, ok, thats like a prolog/lispy thing. all the concurrency, processes, events, signals etc; flash had nested timelines.
i mean, albinoblacksheep kongregating on the newgrounds.
im not sure 2019, maybe original. 93 or 2002 to start
not 2008/2019 yet, too much to add there for now
to make it easier to implement vhdl is a self hosting environment on that platform
sigstoat — Yesterday at 5:25 PM
there's not even a 1 to 1 mapping between constructs in C and assembly language. thinking that you can put together a mapping from VHDL to 6502 assembly is surreal.
they don't even do the same thing.
it'd make more sense to talk about a mapping from sheet music to 6502 assembly
Wayfarer — Yesterday at 5:26 PM
well several things are assembly itself, like rotate, shift, add with carry, etc. things like that are 'easy'. because the 6502 doesnt have hardware multiply, ill have to add an assembly routine to do that; how would you then compile vhdl, to 6502
every vhdl operation, can be performed on a 6502. its a general purpose language on a turing complete computer
now a compiler, (usually) takes a text file, turns it into 'tokens' and parses those to turn them into assembly (well, machine code) for that hardware; at the moment. my concerns are getting a minimal environment set up to to Edit vhdl, including textio and file operations. an editor, an analyzer, including a parser, and then a way to elaborate that file, then a simmulator and waveform viewer. all of these have to be developed.; i plan to use the vhdl editor/parser, and the analyzer, to create a file, that could then be elaborated into a runtime program. I have to make that in ASM, then use asm and my software editor, to make the rest of vhdl, from this,
to be an implementation, i have to have files and text, this environment, is the 'OS' here
so knowing exactly how to turn my vhdl code into 6502 operations is one of the best things i could do
to use vhdl as a general purpose language and write software for this obscure hardware
Tricky — Yesterday at 5:45 PM
to what benefit?
other than an odity
Wayfarer — Yesterday at 5:46 PM
i like 6502s and use them for computing
Piasa — Yesterday at 5:47 PM
that might be the misunderstanding. vhdl isn't really intended to be used as a general purpose language. and it's not intended to "write software" for obscure hardware. it's nifty that it can describe HW constructs, but at its heart, VHDL is for simulation of digital systems.
Wayfarer — Yesterday at 5:47 PM
vhdl is a general purpose language.
Piasa — Yesterday at 5:47 PM
barely.
Wayfarer — Yesterday at 5:48 PM
its not implemented to be used that way and is not supported for this purpose on most major platforms
Tricky — Yesterday at 5:48 PM
any platform
Wayfarer — Yesterday at 5:48 PM
however, "in 6502 land", you do everything yourself, so I can use, basic, forth, a poorly functioning C, or I can 'roll my own'
im choosing to use vhdl over C, its less strict to implement
Piasa — Yesterday at 5:49 PM
you're not wrong that it's possible to do. it's basically how a lot of simulators work. by using vhdl/verilog to generate some executable that can run on the host computer.
Tricky — Yesterday at 5:50 PM
surely all of them...
Wayfarer — Yesterday at 5:50 PM
ok, so ghdl shows you can make a simple text program in vhdl, and you have the phi now, etc
so, I could 'write basic again', try to make C better, or get used to RPN and use forth, or, I can learn more about both vhdl and 6502s, and get a cool custom OS/IDE out of it for audio circuits and discrete logic, (or write programs that map as close to the hardware as possible because I made it that way)
so, "VHDL:65" might be an implementation with a different focus
Tricky — Yesterday at 5:54 PM
I look forward to seeing it listed here one day: https://en.wikipedia.org/wiki/Esoteric_ ... g_language
Wayfarer — Yesterday at 5:54 PM
maybe it turns into 'Aardvark', a dialect of vhdl more for programs, that 'describe how the hardware is used', rather than 'describe how the hardware is laid out'; and "Anthill" is our IDE/AS (integrated development environment analysis system)
ok, well for one to learn more about both; and two, i need a 6502 text language environment
it doesnt get one, its not like PeeCee land, you have to program the micro-computer to do everything,
ToVine — Yesterday at 5:58 PM
And you chose one of the least practical ones for the job? :SufferingInside:
Wayfarer — Yesterday at 5:58 PM
except when I read the LRM, I see 6502 asm everywhere
Piasa — Yesterday at 5:58 PM
that's what I was saying. a lot of the constructs are simulation-related. so you're eventually writing a simulator more than anything else. unless you restrict the vhdl to just a programming subset of features.
Wayfarer — Yesterday at 5:59 PM
a simulation is a program, and can have subprograms.
Piasa — Yesterday at 6:00 PM
I was thinking more of the delay modeling stuff. and common cases like having more than one vhdl process in a design. to get that to work in a sane fashion, you're starting to need the scheduler and other sim stuff.
Wayfarer — Yesterday at 6:01 PM
like 'systems programming with vhdl' might require different techniques than 'simulation programming with vhdl'
Piasa — Yesterday at 6:01 PM
which is fine. it just means a significant amount of the development is going to be related to re-creating simulator mechanics. to the point that you're not really compiling anywhere close to 1:1 code->asm.
Wayfarer — Yesterday at 6:02 PM
depends on what we do with it
like, I see vhdl almost like Flash, its got a timeline built in, support for multiple timelines
vhdl, 'isnt really all that different'
i have to create an OS and software for the 6502, I have limited choices. I love vhdl,, and it has ascii built into it, so thats a plus here, ok so I need a text editor, even a command line, I need a way to program, thats easier to see, to work with, than ASM. i have to pick, basic, forth, or a few other odd languages I didnt just spend 5 months learning. or, I can do this work and use vhdl instead.
Piasa — Yesterday at 6:15 PM
6502 isn't that big. so it might make sense to define a subset of vhdl that is supported as well as intended ways to write code. along with practical optimizations like replacing "+" with normal addition. ("+" is normally a function). likewise, handling 'x', 'u', '-', etc... vs just '0' and '1' could be a needless complication. same with tristates/inouts in general. either way, it seems like forcing a square peg into a round hole.
Wayfarer — Yesterday at 6:17 PM
not at all, its just a matter of doing things one step at a time, the 'should' is actually a good thing here
i will learn a lot and advance knowledge, without really hurting anyone, unless you are afraid this is how skynet gets built?
Piasa — Yesterday at 6:19 PM
this is not how skynet gets built.
Wayfarer — Yesterday at 6:19 PM
terminator runs on 6502
Piasa — Yesterday at 6:22 PM
it's fine for education. basically learning how to make a simulator. but there's various "design for ..." aspects of VHDL that won't get exercised. as long as you don't have any time constraints it seems fine. just more difficult than existing options like using a C compiler or modifying a C compiler.
Wayfarer — Yesterday at 6:22 PM
i dont expect to simulate more than was done on 8bit and 16bit computers in the 80s and 90s, synthesizing an fpga, or cpld, to use in those 8 bit computers, sure; address decoder on a cpld, or fifo buffer usb thingamajig, sure. a video card with vulcan, no. audio circuits
thats a big one, audio stuff, video games, interfaces to old things, controllers.; then again, I can get a 6502 core and run it at 100s of Mhz if i want
Piasa — Yesterday at 6:35 PM
if you drop back to something that looks like pascal/delphi/ada -- all designed to be compiled and run as software -- it's probably not that bad.
Wayfarer — Yesterday at 6:38 PM
be specific, a language is just a language, software for that language is going to vary
concurrency, might need to be avoid and programming techniques, like not overloading the system, should be utilized, if I want to say, add some floating point numbers, and maybe, do some statistics, ok, I can use windows or unix; or a custom system (which is our choice)
Piasa — Yesterday at 6:40 PM
i was already assuming precompiled packages for common packages like math_real, std_logic_1164, textio, numeric_std, etc...
Wayfarer — Yesterday at 6:41 PM
maybe at some point, standard, texio and file, give us an os
here:
Wayfarer — Yesterday at 6:48 PM
multitasking is inherently built in. concurrent processing is the |norm|.
Piasa — Yesterday at 7:06 PM
correct. and that's one concern.
Wayfarer — Yesterday at 7:10 PM
The second part of a minimal VHDL design description is the architecture declaration. Before simulation or synthesis can
proceed, every referenced entity in a VHDL design description must be bound with a corresponding architecture.
so, lets say for a second simulation, I need to map all those entities to how they are simulated on the hardware. its a multiple entendre'
they mean your entity declaration, except how would I represent that on hardware at all, or a hardware to vhdl simulation, without that mapping, so, spreadsheet city
Wayfarer — Yesterday at 8:15 PM
alright, most of the datatypes are just 'data' and are just simple routines in assembly to read, write, and represent. ieee floating (or fixed!) point math needs to be implemented, though starting with: Bit, Char, enum, boolean, integer, and Ill basically need most of array and record to do anything else, those are 'memory arrangement structures' that have a table, index and rountines in assembly to use them, so these give us the floating points and vectors and such, line for textio, etc
then, we build file, and thats 'almost' an OS. the part that is difficult, is time, and it requires a clock or reference clock of some kind.
then its operators, and many are 1:1 vhdl to 6502 asm, some are a few instructions, a couple a bit longer, type conversion and operators on 'bigger datas' will be harder to implement, like = an array
a few of the functions are going to be tricky, while the signals, delayed, transaction, quiet, may give us a built in event system and messaging; then, its concurrency
Piasa — Yesterday at 8:29 PM
it seems that way as long as you make reasonable restrictions. something like x + 1 could have gotcha's. what if x = "1100xxxx"? what if x is 7 bits vs 8. this also assumes special logic for things like numeric_std, otherwise x + 1 (and most operators) are implemented with for loops. that seems more annoying than copying values from a larger object.
Wayfarer — Yesterday at 8:35 PM
yeah for sure. something I see, is like, if you want to write a program, then maybe only having one process, is a good idea, this also means that to implement vhdl, one has to implement multithreading/multitasking
Wayfarer — Yesterday at 8:47 PM
programs. simulation instructions to be run on the native hardware, might make use of variables more, as they behave in a more expected manner. some loops, generates, and branch structures, might be tricky, as they are nuanced and unique.
blocks are interesting, we do have the FOREIGN keyword, so we can have our vhdl program be the OS or kernel, and still use other languages on our operating system, A design library is defined in the VHDL 1076 standard as "an implementation-dependent storage facility for previously analyzed
design units"... thats a dll
Piasa — Yesterday at 8:57 PM
it's closer to namespace
Wayfarer — Yesterday at 8:58 PM
assert and report give error handling stubs, 97 keywords, though most are not common, or are boolean operations
the Event process handler, has to be well written, and it needs a self balancing queue thats not prioritized, and doesnt skip or ignore processes; otherwise, its not really that much different, than adobe flash. no really, there is a logic sorting system that has to be recursive, ok, thats like a prolog/lispy thing. all the concurrency, processes, events, signals etc; flash had nested timelines.
i mean, albinoblacksheep kongregating on the newgrounds.
VHDL:65 -- this is an implementation of VHDL on 65xx hardware
Aardvark -- a dialect of vhdl or package/extension for using vhdl as a general purpose language
Anthill -- an operating environment for vhdl
IDEAS -- integrated development environment analysis system, our ide. "A" might be, 'action', 'analysis', etc, 'E' might be elaboration. this is our IDE and Analysis System, the editor, analyzer and elaborator, for vhdl
I'll turn all of this into a compiled SRS document shortly.
https://en.wikisource.org/wiki/Stoneman_requirements
https://www.allaboutcircuits.com/textbo ... -netlists/
Re: VHDL on 6502?
wayfarer wrote:
... synthesis to a cpld or fpga is possible, I am unlikely to write the subprogram for that myself, however, vhdl;65 should be compliant enough at some point its output should be portable
writing schematics or soomething, the 'netlist', turned into a svg file is good, or a png
our simulator, might be more like circuitverse or logisim ...
writing schematics or soomething, the 'netlist', turned into a svg file is good, or a png
our simulator, might be more like circuitverse or logisim ...
Re: VHDL on 6502?
BruceRMcF wrote:
wayfarer wrote:
... synthesis to a cpld or fpga is possible,... writing schematics or soomething, the 'netlist', turned into a svg file is good, or a png our simulator, might be more like circuitverse or logisim ...
I will keep these ICs in mind when I get to that point
https://iment.com/maida/computer/redref/manualindex.htm
https://web.eecs.umich.edu/~imarkov/pub ... 1-tuto.pdf