Page 1 of 3 123 LastLast
Results 1 to 10 of 21

Thread: Where to start?

  1. #1
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Where to start?

    Well I am eager to try out all the new stuff here in Machine Code.

    I am lost as where to start?

    CO2, ok I understand will allow us run C code in thinBasic, that is really cool!

    But ASMosphere and Oxygen, which do I start with?

    My experience with Machine Code to date, very little.
    I read and worked with this book on my HP100LX.
    The book is available now online in pdf
    I read the 16bit version for dos which this links to.
    http://webster.cs.ucr.edu/AoA/DOS/pdf/0_AoAPDF.html

    All the versions for different os's are available here:
    http://webster.cs.ucr.edu/AoA/index.html
    Attached Images Attached Images
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  2. #2

    Re: Where to start?

    Hi Kent,

    I see machine code as being very close to electronics - think registers, memory cells, addressing modes, stacks and queues. Programming languages are pure artifice - but they are useful for handling large quantities of the stuff.

    But where to start? I would try assembler. and play with some of the examples. If you morph the examples one instruction at a time. You can't go far wrong. Trying to write a whole program from scratch is too difficult because there are too many possibilities for error. But once you have some stable pieces of code, you can really pick up speed.

    Apart from data structures for Asmosphere, there will be macros with parameters and a small set of runtimes for allocating static memory and making it easier to bind to DLLs. Once this is done, I hope to develop some more substantial examples - and a manual with Petr's CHM kit.

  3. #3
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Where to start?

    Charles, I think I came up with a very good use already to use your module. I will need your help on this one.
    I know in powebasic you did something similar, but I would like to do it with your module if possible in thinbasic as trying to do stricly thinbasic project.

    I need to generate sounds or music dynamically from code only. I will have an example app if a few days and you can see where I want to use it then.
    Thought I would give you a heads up so you can think about it and come up with ideas
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  4. #4

    Re: Where to start?

    Yes, I did some real-time audio synth in PB, feeding data directly into a wav audio buffer. This is a project that starts out in a simple enough way, then the realization dawns that audio is almost as complex and rich as video. I could not see an end point to such a project that could be reached in a matter of months so I held off taking it any further, well certainly in PB.

    But this stuff is well worth revisiting - it demands both very low level coding and layers of high level coding to which thinBasic is well suited. Let's see how far we can take it

  5. #5
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Where to start?

    Charles, as you might know... thinBasic can use the FMOD dll. I have not read up on it, but perhaps it provides things we could tap into. I will read up on stuff, fmod and others, while taking a break from coding. Should be interesting!
    My memory, just realized it wasn't fmod, but bass.dll. Sorry about any cofusion it might have caused.
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  6. #6

    Re: Where to start?

    I used low-level MCI and set up a looping buffer which was kept topped up with chunks of sound generated by a series of oscillator, filter and envelope functions. When a sound was triggered the parameters were set and it would drop a chunk of sound into the buffer ahead of the reading position, every time a frame was rendered.

    With this technique long sounds and reverberations can be produced with very little latency, using small buffers.

    The code got very dense as I added more and more stuff - and it (& I) started to buckle under the complexity. The pieces need to be rescued and reconstructed with a much stronger framework.

    I am sure we could make a sound effects module out of this. - and make the tanks thunder!

  7. #7
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Where to start?

    Charles, I did some research in bass.dll. It appears we can use it to do what we need.

    When you download bass from here, they give many examples in various languages.
    There is a synth demo in c and in visual basic.
    http://www.un4seen.com/
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  8. #8

    Re: Where to start?

    Thanks Kent, downloaded BASS. I dont have VB but had a brief look at the C synth example source. Bass provides all the infrastructure but nothing to support creation of the original sound - uses a sine wave in the example. Building sounds will be the main task before us.

  9. #9
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Where to start?

    I don't know if I ever sent you this, unfortunately the source is not in it, but steve gibson really came up with something that really offers that wonderful rich sound.
    http://www.grc.com/smgassembly.htm

    It is the section The new ASPI_ME Title Page App:

    I have been doing searches to see how you create sound sources, nothing so far, but run into fun things along the way so a fun item to search for

    I am glad we have the infrastructure with bass, so that is very good !
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  10. #10

    Re: Where to start?

    Just to give a flavour, here are two specimin sounds generated in real time using my software. They sound polyphonic but its done mostly with harmonics, frequency modulation and envelopes.
    Attached Files Attached Files

Page 1 of 3 123 LastLast

Similar Threads

  1. thinSVN (02): what do you need to start
    By ErosOlmi in forum thinSVN
    Replies: 0
    Last Post: 15-04-2009, 17:21

Members who have read this thread: 1

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •