EmbeddedRelated.com
Forums
The 2026 Embedded Online Conference

waveform display in browser

Started by John Larkin July 23, 2015
On 2015-07-24, Clifford Heath <no.spam@please.net> wrote:
> On 25/07/15 19:28, Jasen Betts wrote: >> On 2015-07-24, Clifford Heath <no.spam@please.net> wrote: >>> On 25/07/15 08:44, Jasen Betts wrote: >>>> On 2015-07-24, Grant Edwards <invalid@invalid.invalid> wrote: >>>>> On 2015-07-24, Tim Wescott <seemywebsite@myfooter.really> wrote: >>>>> >>>>>> If I recall correctly, GIF encoding is on the lines of >>>>>> >>>>>> 100 black, 1 white, 25 black, etc., for each line. >>>>> >>>>> That's call run-length encoding, and it's what TIFF uses. >>>>> >>>>> GIF files are encoded as 8-bits-per-pixel (with a 256-byte color >>>>> lookup table), and then compressed using the Lempel-Ziv-Welch >>>>> algorithm. >>>> >>>> no, N bits per colour with a 3*2^N table ( 1 <= N <= 8 ) >>> >>> That's incorrect. GIF uses an 8-bit (256 element colour map) that has >>> 3x8-bit RGB elements. The actual image data is 8-bit indices into that >>> colour map, LZW compressed - exactly what Grant said. >> >> You're making shit up. >> >> I just made a gif file here that's 73 bytes. explain that. > > The color map doesn't have to be full.
> How so you survive in a technical career without being able to use Google?
finding the information is only part of the problem, YOU also need to understand it.
><https://en.wikipedia.org/wiki/GIF> ><http://www.w3.org/Graphics/GIF/spec-gif89a.txt>
That pretty-much as I remember it from the early 90s. hmm, seaction 19 and section 21. say something very similar to 3*2^N 22. Table Based Image Data. "LZW Minimum Code Size" see appendix F for it's significgance starting at "ESTABLISH CODE SIZE" what it means is that the actual data is N-bit indices into the color table, because indices 2^N and above cannot be coded. if that's too complicated, see this part ot the wikipedia page: https://en.wikipedia.org/wiki/GIF#LZW_code_lengths -- umop apisdn
On Thu, 23 Jul 2015 11:18:09 -0700, John Larkin
<jlarkin@highlandtechnology.com> wrote:

> > >I'm designing a tachometer box and it will have a web page interface >as one way to talk to it. I thought it would be cool to include an ADC >so we could display waveforms, too. My software guys here are mostly >embedded types so we don't know a lot about Javascript and such. I did >a little searching and mostly found things for displaying audio >envelope cartoons; I want a real oscilloscope-looking thing, so users >can see what happens as they change gains and filtering and trigger >level settings. Dual trace would be nice, the analog waveform and >corresponding comparator outputs. > >Has anybody done this? We'd consider getting outside help, either >advice or actual coding. > >I assume our box will, through some port, deliver HTML, Javascript, >and maybe some zipped JS libraries to the browser. And the company >logo of course. The browser will send us text strings to parse if the >user wants to change parameters or such. We would also deliver blocks >of waveform data on request. That's my PHB perspective on things; I'm >just the hardware designer.
One of my guys threw this together pretty fast: https://dl.dropboxusercontent.com/u/53724080/Software/svgtest.html It uses javascript to generate a sine wave and pushes SVG into the browser to plot it. Seems fine under Firefox. It's only 250 points and looks pretty good. It doesn't look hard to have my tachometer box digitize waveforms (AD7276 maybe) and display in the browser, without loading any apps or anything. -- John Larkin Highland Technology, Inc picosecond timing precision measurement jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
>I'm designing a tachometer box and it will have a web page interface >as one way to talk to it. I thought it would be cool to include an ADC >so we could display waveforms, too. My software guys here are mostly >embedded types so we don't know a lot about Javascript and such. I did >a little searching and mostly found things for displaying audio >envelope cartoons; I want a real oscilloscope-looking thing, so users >can see what happens as they change gains and filtering and trigger >level settings. Dual trace would be nice, the analog waveform and >corresponding comparator outputs. > >Has anybody done this? We'd consider getting outside help, either >advice or actual coding. > >I assume our box will, through some port, deliver HTML, Javascript, >and maybe some zipped JS libraries to the browser. And the company >logo of course. The browser will send us text strings to parse if the >user wants to change parameters or such. We would also deliver blocks >of waveform data on request. That's my PHB perspective on things; I'm >just the hardware designer. > > >-- > >John Larkin Highland Technology, Inc >picosecond timing precision measurement > >jlarkin att highlandtechnology dott com >http://www.highlandtechnology.com
Hi, if I am not too late with the answer. Red Pitaya (www.redpitaya.com) is... I will skip all marketing shit... providing the scope application. It is running on GNU/Linux (on Xilinx Zynq) and nginx web-server (patched to support some nice things). Web page is written mostly with HTML5 and Javascript. You can check the web page for scope: https://github.com/RedPitaya/RedPitaya/blob/master/Applications/scope/index.html You will see that in fact most of the backend is running from modules in nginx - but generally it should be good starting point to make a webpage with oscilloscope graphs (resizing, panning, ...). I think also all the libraries should be 'free to use' (I am not sure about licenses directly). Hope it helps. Jure Menart --------------------------------------- Posted through http://www.EmbeddedRelated.com
On 7/27/2015 8:52 PM, John Larkin wrote:
> On Thu, 23 Jul 2015 11:18:09 -0700, John Larkin > <jlarkin@highlandtechnology.com> wrote: > >> >> >> I'm designing a tachometer box and it will have a web page interface >> as one way to talk to it. I thought it would be cool to include an ADC >> so we could display waveforms, too. My software guys here are mostly >> embedded types so we don't know a lot about Javascript and such. I did >> a little searching and mostly found things for displaying audio >> envelope cartoons; I want a real oscilloscope-looking thing, so users >> can see what happens as they change gains and filtering and trigger >> level settings. Dual trace would be nice, the analog waveform and >> corresponding comparator outputs. >> >> Has anybody done this? We'd consider getting outside help, either >> advice or actual coding. >> >> I assume our box will, through some port, deliver HTML, Javascript, >> and maybe some zipped JS libraries to the browser. And the company >> logo of course. The browser will send us text strings to parse if the >> user wants to change parameters or such. We would also deliver blocks >> of waveform data on request. That's my PHB perspective on things; I'm >> just the hardware designer. > > One of my guys threw this together pretty fast: > > https://dl.dropboxusercontent.com/u/53724080/Software/svgtest.html > > It uses javascript to generate a sine wave and pushes SVG into the > browser to plot it. Seems fine under Firefox. It's only 250 points and > looks pretty good. > > It doesn't look hard to have my tachometer box digitize waveforms > (AD7276 maybe) and display in the browser, without loading any apps or > anything.
Nice. I'll have to toss that into my EM simulator at some point. Cheers Phil Hobbs -- Dr Philip C D Hobbs Principal Consultant ElectroOptical Innovations LLC Optics, Electro-optics, Photonics, Analog Electronics 160 North State Road #203 Briarcliff Manor NY 10510 hobbs at electrooptical dot net http://electrooptical.net
The 2026 Embedded Online Conference