Author Topic: Beams of Light, new scope demo, like Youscope  (Read 16767 times)

0 Members and 2 Guests are viewing this topic.

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Beams of Light, new scope demo, like Youscope
« on: June 15, 2014, 10:18:11 pm »
That's a really nice new scope demo:



The download link on the pouet website contains the WAV file, if you want to try it, and a nice x/y mode scope emulator (runs in Windows). The readme file has some details how they did it.

If you want to display it on your scope, you should use an analog scope, or a very high waveform update per seconds digital scope, as Dave demonstrated with Youscope:



And even then it doesn't look as good as on an analog scope.
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline grumpydoc

  • Super Contributor
  • ***
  • Posts: 2905
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #1 on: June 15, 2014, 11:02:16 pm »
Nice but not as impressive as oscillofun since it "cheats" by having a 4-channel stream with the audio in the rear L+R channels and the X-Y data in the front L+R channels.

It's fairly obvious as you watch it that you're not hearing what you're seeing.
 

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Re: Beams of Light, new scope demo, like Youscope
« Reply #2 on: June 15, 2014, 11:34:59 pm »
Right, but I guess you can't do this clean constant dots per hertz display as mentioned in the readme, when it is audio as well.
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8275
Re: Beams of Light, new scope demo, like Youscope
« Reply #3 on: June 16, 2014, 11:01:00 am »
There are demosceners on EEVblog? Good to see. :D

(For those who don't know what I'm talking about: http://en.wikipedia.org/wiki/Demoscene )

That was enjoyable, although I'd be even more impressed if it was generated in realtime by a 4K program...
 

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Re: Beams of Light, new scope demo, like Youscope
« Reply #4 on: June 16, 2014, 12:28:48 pm »
They are planning an Arduino version :) Meanwhile you can watch this demo, implemented in a small AVR with 8.5k ROM and 1k RAM:



Not electronics related, but this is one of my favorite demos of all time, and yes, only 4k :-+



Of course, in both demos music synthesis is done by the demo code.
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #5 on: June 17, 2014, 03:00:50 pm »
Nice but not as impressive as oscillofun since it "cheats" by having a 4-channel stream with the audio in the rear L+R channels and the X-Y data in the front L+R channels.

It's fairly obvious as you watch it that you're not hearing what you're seeing.
I am getting bad results. I think that my PC sound card is of low quality and cannot work properly with four channel WAV file...
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #6 on: June 17, 2014, 03:51:54 pm »
So I made a two channel WAV version with Audacity. Download here. http://mysharegadget.com/874505129
http://ulozto.net/xggsxqUV/beams-of-light-2ch-for-eevblog-wav
Video coming soon.
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline marshallh

  • Supporter
  • ****
  • Posts: 1462
  • Country: us
    • retroactive
Re: Beams of Light, new scope demo, like Youscope
« Reply #7 on: June 17, 2014, 04:29:41 pm »
Your DAC has a huge effect on the output quality. My laptop gave a crap picture, so I used my Sansa Fuze (which has a nice Wolfson DAC) and it was perfect.
Verilog tips
BGA soldering intro

11:37 <@ktemkin> c4757p: marshall has transcended communications media
11:37 <@ktemkin> He speaks protocols directly.
 

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #8 on: June 17, 2014, 08:54:48 pm »
Yes, there is an integrated sound card in my PC's motherboard. Good for music, not so good for experiments above 20kHz.
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #9 on: June 18, 2014, 12:06:23 am »
here's mine, i struggled too with the quality of the signal, it's not as clear as the original.

Maybe i will look at improving and reposting.


Offline Kevman

  • Regular Contributor
  • *
  • Posts: 146
Re: Beams of Light, new scope demo, like Youscope
« Reply #10 on: June 18, 2014, 02:06:30 am »
I was at the party this was released at (actually did the live video stream).

The show orgas rolled out a Tektronix 551 (that I helped repair there) to try and show it in person but it didn't quite work out. The 551 has a crappy X-Y mode and since its dual beam neither beam can cover the whole screen :P

http://atparty-demoscene.net/ for a few pics of the 551. I'm the one working it- it took me a long time to find the auto trigger position to get it to trace.
I've never seen such a large scope in my life and probably never will again! 850 watt power consumption  :-DD

Anyway, I just tried the video on my Tek 2245A, and its... not so good. Retrace is very visible. I think my scope is too fast for this stuff. But the other is real bad ringing on the straight lines. Any suggestions about that? It might be my sound card... It also really wants to be DC coupled.

I'm still trying to convert an old monitor into an XY display for stuff like this but its pretty  |O
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #11 on: June 18, 2014, 05:37:56 am »
This is something audiophiles might get into. An oscilloscope based benchmark sound file that will push the limits of their hardware to see if it displays correctly.

Actually I'm only half kidding it will sell not only the benchmark file but the scope you deem appropriate for the test :)
« Last Edit: June 18, 2014, 06:29:38 am by miguelvp »
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8517
  • Country: us
    • SiliconValleyGarage
Re: Beams of Light, new scope demo, like Youscope
« Reply #12 on: June 18, 2014, 06:31:11 am »
This is something audiophiles might get into. A oscilloscope based benchmark sound file that will push the limits of their hardware to see if it displays correctly.

Actually I'm only half kidding it will sell not only the benchmark file but the scope you deem appropriate for the test :)
DO NOT give em any idea's...

Soon we'll have webpages showing how to replace the capacitors in oscilloscopes with cryogenically treated superflux oxygen free copper versions on hazelwood standoffs to improve image sharpness and depth on the lcd display.

Let it be... We really don't need that.
Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #13 on: June 18, 2014, 06:37:29 am »

Anyway, I just tried the video on my Tek 2245A, and its... not so good. Retrace is very visible. I think my scope is too fast for this stuff. But the other is real bad ringing on the straight lines. Any suggestions about that?

thats my problem too and i'm going to be looking into it.

Luis (who posted the video linked at the start) replied to my video last night and mentioned it might be an upsampling issue.


Offline AndyC_772

  • Super Contributor
  • ***
  • Posts: 4228
  • Country: gb
  • Professional design engineer
    • Cawte Engineering | Reliable Electronics
Re: Beams of Light, new scope demo, like Youscope
« Reply #14 on: June 18, 2014, 07:51:02 am »
I can confirm that the Youscope demo does indeed look a great deal better when played through a dc-coupled audiophile DAC than it does when played through my laptop's headphone output. I couldn't resist it. Sorry!

It is, however, easy to see on the screen effects which may not in fact be audible. The laptop output, for example, has a 'fuzz' around the spot from the ultrasonic noise that's present, whereas the DAC projects a clear, bright point of light.

Also, my DAC has a couple of output filter settings which can be selected by the user, and though I can't actually hear any difference between then, the effect on the image is quite pronounced. The output clearly IS different, even though I can't hear it.

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #15 on: June 18, 2014, 08:10:36 am »
mine was output through Reaper into my new Roland TR-8 drum machine through USB, i wanted to try and isolate the dac as far from the pc as possible.

It did improve but there is still 'ringing' on what should be straight lines.

if it comes to it i might lug the pc with it's digital audio out and plug it into my av amp

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8275
Re: Beams of Light, new scope demo, like Youscope
« Reply #16 on: June 18, 2014, 10:05:09 am »
To me, the ringing suggests insufficient bandwidth (stray inductance from a very long cable? some other low-pass filter somewhere?)
 

Offline AndyC_772

  • Super Contributor
  • ***
  • Posts: 4228
  • Country: gb
  • Professional design engineer
    • Cawte Engineering | Reliable Electronics
Re: Beams of Light, new scope demo, like Youscope
« Reply #17 on: June 18, 2014, 10:18:11 am »
Visible ringing can also be a completely normal artefact, when a sharp step is fed through a low pass filter with a very steep cut-off.

Consider, for example, the familiar Fourier series expansion for a square wave. Suppose you were to feed the square wave through a perfect low pass filter set at 8x the fundamental frequency of the wave; you'd get out the 1st, 3rd, 5th and 7th harmonics, and nothing else. The signal would have a lot of visible ringing, which would never completely settle.

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #18 on: June 18, 2014, 01:18:41 pm »
For the ringing you probably need the audiophille grade $1000 power cord  :-DD
 

Offline Kevman

  • Regular Contributor
  • *
  • Posts: 146
Re: Beams of Light, new scope demo, like Youscope
« Reply #19 on: June 18, 2014, 05:32:48 pm »
Luis told me that cheaper, crappier sound cards like those $3 USB cards typically work better because they lack filtering. And supposedly its fairly easy to take the DC blockers out. I'm pretty sure Luis told me he used a phone...? I can't remember. I know he used a phone camera to take the video. That scope is seriously TINY, too.

My cable is pretty long because I had to use a headphone jack extension cable to get it to reach. I'll try some different things tonight.
 

Offline Stonent

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #20 on: June 18, 2014, 05:39:53 pm »
When I first tried Oscillofun, I got a bunch of trash on the screen of my scope. I had to get a FLAC version of it for it to work.
The larger the government, the smaller the citizen.
 

Offline mamalala

  • Supporter
  • ****
  • Posts: 777
  • Country: de
Re: Beams of Light, new scope demo, like Youscope
« Reply #21 on: June 18, 2014, 05:56:32 pm »
Not electronics related, but this is one of my favorite demos of all time, and yes, only 4k :-+

<...snip...>
se, in both demos music synthesis is done by the demo code.

Dunno... I'm of the opinion that using sophisticated graphic cards that have a lot of 3D stuff built in is a bit of a cheat here. Sure, the code of the executable may only be 4k in size, but the heavy lifting for the graphics is done in the GPU, using the code supplied by the host OS, gfx card drivers, etc. Add that to the overall size and you end up with _far_ more than just 4k...

But still impressive, of course.

Greetings,

Chris
 

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #22 on: June 18, 2014, 07:21:02 pm »
Here is my DSOX2002A version.
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline SirNick

  • Frequent Contributor
  • **
  • Posts: 589
Re: Beams of Light, new scope demo, like Youscope
« Reply #23 on: June 18, 2014, 08:53:21 pm »
Not electronics related, but this is one of my favorite demos of all time, and yes, only 4k :-+
Of course, in both demos music synthesis is done by the demo code.

How the f...   :wtf:
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8275
Re: Beams of Light, new scope demo, like Youscope
« Reply #24 on: June 19, 2014, 01:39:19 pm »
Not electronics related, but this is one of my favorite demos of all time, and yes, only 4k :-+
Of course, in both demos music synthesis is done by the demo code.

How the f...   :wtf:
It's not that these demos are impossibly efficient, it's just that all the other software we're used to is far from it. :)

Also, there's plenty more where that came from...
 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #25 on: June 19, 2014, 02:14:06 pm »
i dabbled a little back in the days of Atari STs with assembler and tweaking HW registers, it's surprising what can be done with a few lines of code

i spent a little time yesterday and found this one which i thought was pretty good for a 1k demo (1k!!!  :wtf:), might have to download and try it for real as the pixelated youtube video is just awful.



Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #26 on: June 19, 2014, 04:22:14 pm »
Here is some more XY fun.


Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline SirNick

  • Frequent Contributor
  • **
  • Posts: 589
Re: Beams of Light, new scope demo, like Youscope
« Reply #27 on: June 19, 2014, 06:36:11 pm »
It's not that these demos are impossibly efficient, it's just that all the other software we're used to is far from it. :)

Oh, I know.  I'm familiar with the demoscene (still jam out to MODs every now and again), and even 4K demos.  But sheesh.  Can you even write a (granted, C) program to initialize DirectX in 4KB?  Much less generate landscape, and play music, which unless it's also based on equations, is going to take a not insignificant part of that 4KB just for the sequenced data.

I would say I want to see the source code just to try and wrap my mind around this, but I don't think I would understand a byte of it.  I suspect it's not trivial, sequentially executed, boilerplate stuff.
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #28 on: June 19, 2014, 11:15:22 pm »
Is 4K the whole code or does it require a Direct3D and DirectSound dll? or OpenGL and OpenAL for the Microsoft haters .
 

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Re: Beams of Light, new scope demo, like Youscope
« Reply #29 on: June 20, 2014, 12:06:42 am »
Is 4K the whole code or does it require a Direct3D and DirectSound dll? or OpenGL and OpenAL for the Microsoft haters .
Usually they use OpenGL or DirectX. These demos are presented at demo parties, which have rules for the programs, like it has to run on a stock Windows machine with a NVIDIA graphics card or similar, so no OpenAL.
Oh, I know.  I'm familiar with the demoscene (still jam out to MODs every now and again), and even 4K demos.  But sheesh.  Can you even write a (granted, C) program to initialize DirectX in 4KB?  Much less generate landscape, and play music, which unless it's also based on equations, is going to take a not insignificant part of that 4KB just for the sequenced data.
The elevated demo is described in this paper:
http://iquilezles.org/www/material/function2009/function2009.pdf
Lots of math. You start writing it in C, but most of it is implemented in the 3D shader language anyway, which is similar to C. If it gets to big, rewrite it in assembler. Then use tricks like not linking by name to the DLLs functions, but by ID, use a runtime-compressor etc. And of course the music is generated algorithmically, 4k would be 0.1 s sampled music :)
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #30 on: June 20, 2014, 12:46:19 am »
OpenAL is the OpenGL audio engine, like DirectSound is the DirectX audio part.

I would have been more impressed if the full program (drawcalls and everything) fit on the 4K.
 

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Re: Beams of Light, new scope demo, like Youscope
« Reply #31 on: June 20, 2014, 01:03:34 am »
OpenAL is the OpenGL audio engine, like DirectSound is the DirectX audio part.
Right, but AFAIK it is not part of a standard Windows installation, unlike OpenGL.
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline SirNick

  • Frequent Contributor
  • **
  • Posts: 589
Re: Beams of Light, new scope demo, like Youscope
« Reply #32 on: June 20, 2014, 01:27:20 am »
Sure, with the abstraction layers, you get the benefit of hardware initialization and maybe a few generic filters for free.  But stuff like creating a canvas and opening the audio device is all rather insignificant compared to the meat of the demo code.  Even back in the day, when it was all assembly in DOS mode, you were still allowed to lean on the BIOS code and audio drivers...

Speaking of which, I would like to see the demo coders get hired as driver programmers.  When you think about downloading a several hundred MB compressed executable to install ATI Catalyst or whatever... it's just obscene how wasteful that is.  "Eh who cares, we all have TB hard drives.."  Doesn't mean a basic DLL shouldn't still be able to fit on a floppy disk.

Get off my lawn!
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Beams of Light, new scope demo, like Youscope
« Reply #33 on: June 20, 2014, 01:47:38 am »
There is more to it than just generating some dynamic tri-strips and tri-fans draw calls, a few dynamic generated textures and shaders for the materials and a couple of lights. I bet most of the code goes into generating the sound :)

 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #34 on: June 21, 2014, 03:33:18 pm »
ok guys, getting back on subject...

i have been playing around trying to find out why i'm getting the distorted image with the ringing. Which can also be seen on Hydrawerk's videos of it too

I have tried 4 different output devices now but they are all identical, my pc, nexus tab, digitally through my roland tr-8 drum machine and through digital from my PS3 to my good AV amp using the pre-outs. Also changing between phono cables and scope probes, they are all the same.

has anyone managed to get their output as clear as the original? if so, how?

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #35 on: June 21, 2014, 06:22:29 pm »
Did you solve the ground loop problem? http://en.wikipedia.org/wiki/Ground_loop_(electricity)
I use a 230V isolation transformer for my scope.
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #36 on: June 22, 2014, 09:53:11 am »
i dont have an isolation transformer i'm afraid, also surely using a battery powered device like my phone or tab would have eliminated that problem?

been playing around a bit more, here are some screens from the scope showing the ringing and it's original in the wav file. It's evident on the higher frequency parts. The screens show one of the channels with a triangle wave

have tried removing the ground lead from the scope probe and grounding right onto the probe, 10X... etc

any ideas? this must be a scope/probe issue surely?

Offline AndyC_772

  • Super Contributor
  • ***
  • Posts: 4228
  • Country: gb
  • Professional design engineer
    • Cawte Engineering | Reliable Electronics
Re: Beams of Light, new scope demo, like Youscope
« Reply #37 on: June 22, 2014, 10:00:32 am »
Nope, it's way too low in frequency for that. There's also a major clue in that the ringing starts *before* the step in the sawtooth wave, which means it can't possibly be your scope. The effect of the step cannot precede the step itself... causality and all that.

The ringing must, therefore, be the result of a low pass filter somewhere in your system. Maybe all your output devices have low pass filters in them? It's a completely normal part of a digital audio output stage, so not at all unlikely.

Offline jahonen

  • Super Contributor
  • ***
  • Posts: 1054
  • Country: fi
Re: Beams of Light, new scope demo, like Youscope
« Reply #38 on: June 22, 2014, 10:44:16 am »
That is a typical sin x/x oversampling DAC response to step-ish signals. That pre-ringing is just part of the impulse response that the oversampling filter has.

These kind of demos would probably work best with non-oversampling DAC, or oversampling DAC with non-ringing (i.e. shallower frequency response near cutoff) impulse response.

Regards,
Janne
 

Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #39 on: June 22, 2014, 11:57:29 am »
yea i did wonder why the 'ringing' effect also preceded the transition

maybe i will look at an external usb dac for the pc, if i get one thats just a bare pcb (seems to be loads on ebay) it could be hacked to remove any filtering, might do a video on it if i get round to it!

Offline AndyC_772

  • Super Contributor
  • ***
  • Posts: 4228
  • Country: gb
  • Professional design engineer
    • Cawte Engineering | Reliable Electronics
Re: Beams of Light, new scope demo, like Youscope
« Reply #40 on: June 22, 2014, 11:57:48 am »
Here's the demo as shown on my Agilent 3000X in hi-res mode, driven by a dc-coupled DAC of my own design.



Offline dexters_lab

  • Supporter
  • ****
  • Posts: 1890
  • Country: gb
Re: Beams of Light, new scope demo, like Youscope
« Reply #41 on: June 22, 2014, 12:42:41 pm »
yea, looks much better!

Offline Hydrawerk

  • Super Contributor
  • ***
  • Posts: 2600
  • Country: 00
Re: Beams of Light, new scope demo, like Youscope
« Reply #42 on: June 22, 2014, 07:58:44 pm »
Well, my 2008's Canon still camera has quite limited movie capabilities. Yours is much better.
Amazing machines. https://www.youtube.com/user/denha (It is not me...)
 

Offline Fagear

  • Regular Contributor
  • *
  • Posts: 83
  • Country: ru
Re: Beams of Light, new scope demo, like Youscope
« Reply #43 on: June 24, 2014, 05:12:51 pm »
Pretty good demo!
That how it is displayed on my Rigol DS2072A:
???? Beams of light ?? Rigol DS2072A (DS2000A)

Soundcard in my PC (integrated Realtek ALC887) is not very good, there are some artifacts in calibration waveform. And it has AC coupled output. :( But installed Audigy2 ZS didn't perform any better: yes, much less oscillations on calibration waveform, but also AC coupled and MUCH more fuzzy trace.
 

Offline luis2048

  • Newbie
  • Posts: 1
Re: Beams of Light, new scope demo, like Youscope
« Reply #44 on: July 03, 2014, 09:53:32 am »
Some sound cards have a native sampling rate : the rate of the clock driving the DAC.  I think sample rate conversion artifacts via DSP or microprocessor maybe involved if you are not seeing a perfect image.  Hardware filtering that "improves" or softens the audio output can mess things up even further.

recommendations:
  • Disable any hardware/software equalizer/enhancements via speaker/soundcard properties
  • mute or disable any line-in or microphone inputs.
  • change the OS sample format to match your hardware native sampling rate or get a 90's era soundcard with native sampling rate of 44100 Hz
  • burn the first two channels of the WAV to redbook CD. some PC CD drives have a line out on the front panel or two pins in the back.
  • get a cheap USB external soundcard (you may have to short out any filtering circuits)
  • gold plated monster cables
  • roll your own 16-bit DAC R-2R resistor ladder via PIC/Micro reading the 16-bit values from the WAV file

Bit Perfect Playback

Effects of Sample Rate Conversion

It is possible to get a cleaner, sharper and brighter image than this:



If you like demoscene projects like this you may also enjoy Demosplash in a few months.   Word on the street says they might have a laser projector and/or demo featuring similar scope techniques.  I may even re-author a 192 kHz 5 channel version with Z channel on the center line.
 

Offline Electro Fan

  • Super Contributor
  • ***
  • Posts: 3199
Re: Beams of Light, new scope demo, like Youscope
« Reply #45 on: August 30, 2014, 04:45:24 pm »
Very, very late to this thread.  Just trying to get this particular demo to work on an analog scope:

https://plus.google.com/118345912417403012643/posts/gqqJPKm8SQK

The file doesn't render quite right - seems like one channel is off (line from lower left to upper right in attached image).

I've re-plugged, swapped channels, cables, connectors but can't quite figure it out.  Not sure if it's hardware, the file, the PC media player DAC, or something else.

Any suggestions?

Thanks
« Last Edit: August 30, 2014, 04:57:44 pm by Electro Fan »
 

Offline FrankBussTopic starter

  • Supporter
  • ****
  • Posts: 2365
  • Country: de
    • Frank Buss
Re: Beams of Light, new scope demo, like Youscope
« Reply #46 on: August 30, 2014, 07:17:35 pm »
I would test it with simpler signals. With this Python script you can create some test signals, stereo with 16 bits per sample:
Code: [Select]
import math
import wave
import struct

def createStereoWav(leftFun, rightFun, fileName):
# create samples
time = 10
samplerate = 44100
freq = 440
ampl = 16000
sampleCount = time * samplerate
samples = bytearray(4 * sampleCount)
for i in range(time * samplerate):
angle = 2 * math.pi / samplerate * i * freq
left = struct.pack('h', int(leftFun(angle) * ampl))
right = struct.pack('h', int(rightFun(angle) * ampl))
samples[4 * i] = left[0]
samples[4 * i + 1] = left[1]
samples[4 * i + 2] = right[0]
samples[4 * i + 3] = right[1]

# write wav file
w = wave.open(fileName, 'wb')
w.setnchannels(2)
w.setsampwidth(2)
w.setframerate(samplerate)
w.setnframes(int(samplerate / time))
w.writeframes(samples)
w.close()

createStereoWav(math.sin, math.sin, 'line.wav')
createStereoWav(math.sin, math.cos, 'circle.wav')
createStereoWav(math.sin, lambda angle: math.sin(1.3*angle), 'cushion.wav')

Started with Python 3 this program creates three wave files, which the simulator in the Beams of Light program can show:

line.wav


circle.wav


cushion.wav


Note that the Beams of Light demo uses a WAV file with 4 channels. If your sound system doesn't like it, then delete the two extra channels with Audacity, and disable any post-processing, like filters, 3D effect etc. You might still have the AC/DC problem, but it shouldn't display this big diagonal line.
So Long, and Thanks for All the Fish
Electronics, hiking, retro-computing, electronic music etc.: https://www.youtube.com/c/FrankBussProgrammer
 

Offline w2aew

  • Super Contributor
  • ***
  • Posts: 1780
  • Country: us
  • I usTa cuDnt speL enjinere, noW I aR wuN
    • My YouTube Channel
Re: Beams of Light, new scope demo, like Youscope
« Reply #47 on: August 31, 2014, 12:45:34 am »
Very, very late to this thread.  Just trying to get this particular demo to work on an analog scope:

https://plus.google.com/118345912417403012643/posts/gqqJPKm8SQK

The file doesn't render quite right - seems like one channel is off (line from lower left to upper right in attached image).

I've re-plugged, swapped channels, cables, connectors but can't quite figure it out.  Not sure if it's hardware, the file, the PC media player DAC, or something else.

Any suggestions?

Thanks

Some scopes don't want you to have the X channel turned on. Try leaving both X an Y connected, but turn off the channel used for X.  The diagonal line is the same signal being applied to x and y...
YouTube channel: https://www.youtube.com/w2aew
FAE for Tektronix
Technical Coordinator for the ARRL Northern NJ Section
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf