On 7/23/2015 6:30 PM, John Larkin wrote:> On Fri, 24 Jul 2015 01:19:09 +0300, Dimiter_Popoff <dp@tgi-sci.com> > wrote: > >> On 24.7.2015 ?. 00:50, John Larkin wrote: >>> On Fri, 24 Jul 2015 00:13:19 +0300, Dimiter_Popoff <dp@tgi-sci.com> >>> wrote: >>> >>>> On 23.7.2015 ?. 23:49, rickman wrote: >>>>> On 7/23/2015 4:34 PM, Phil Hobbs wrote: >>>>>> On 7/23/2015 2:18 PM, John Larkin 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 approach is a CGI script that runs gnuplot under the covers. IIRC >>>>>> quite a few folks do that. (I'm a static HTML guy myself.) >>>>> >>>>> Isn't there an actual oscilloscope display package under Linux? It >>>>> should be fairly straightforward to drive that from an internet >>>>> connection. I guess requiring the customer to installing such a package >>>>> is not preferred. >>>>> >>>> >>>> He is after a browser plugin - something like VNC, the way I do it >>>> on our spectrometers (I do not use a plugin but I could if I wanted to). >>> >>> Actually, I don't want a plugin, just a way for the browser to display >>> a waveform, using some javascript. We can store any reasonable zipped >>> javascript libraries in our gadget and deliver them to the browser. >> >> I am not sure I have seen that done for live graphics - then scaling, >> perhaps autoranging etc., even if doable it would be a massive pain >> to support with all browsers as they keep on evolving. >> Your best bet might be to produce locally a .gif (or .png or >> whatever) bitmap, maintain it live and persuade the browser to refresh >> it regularly. Don't know how the latter is to be done though. > > We could do that in the FPGA! If nobody murders me for suggesting it.If a simple GIF image is good enough, I'm pretty sure you can imbed that in an HTML page that will auto refresh periodically. How often does it need to update? -- Rick
waveform display in browser
Started by ●July 23, 2015
Reply by ●July 23, 20152015-07-23
Reply by ●July 23, 20152015-07-23
On Thu, 23 Jul 2015 15:30:11 -0700, John Larkin wrote:> On Fri, 24 Jul 2015 01:19:09 +0300, Dimiter_Popoff <dp@tgi-sci.com> > wrote: > >>On 24.7.2015 ?. 00:50, John Larkin wrote: >>> On Fri, 24 Jul 2015 00:13:19 +0300, Dimiter_Popoff <dp@tgi-sci.com> >>> wrote: >>> >>>> On 23.7.2015 ?. 23:49, rickman wrote: >>>>> On 7/23/2015 4:34 PM, Phil Hobbs wrote: >>>>>> On 7/23/2015 2:18 PM, John Larkin 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 approach is a CGI script that runs gnuplot under the covers. >>>>>> IIRC quite a few folks do that. (I'm a static HTML guy myself.) >>>>> >>>>> Isn't there an actual oscilloscope display package under Linux? It >>>>> should be fairly straightforward to drive that from an internet >>>>> connection. I guess requiring the customer to installing such a >>>>> package is not preferred. >>>>> >>>>> >>>> He is after a browser plugin - something like VNC, the way I do it on >>>> our spectrometers (I do not use a plugin but I could if I wanted to). >>> >>> Actually, I don't want a plugin, just a way for the browser to display >>> a waveform, using some javascript. We can store any reasonable zipped >>> javascript libraries in our gadget and deliver them to the browser. >> >>I am not sure I have seen that done for live graphics - then scaling, >>perhaps autoranging etc., even if doable it would be a massive pain to >>support with all browsers as they keep on evolving. >>Your best bet might be to produce locally a .gif (or .png or whatever) >>bitmap, maintain it live and persuade the browser to refresh it >>regularly. Don't know how the latter is to be done though. > > We could do that in the FPGA! If nobody murders me for suggesting it.I don't know how to persuade a browser to auto-refresh, but GIF format uses run-length limiting for compression. That means that line drawings of few colors tend to be very small -- you'll use up way more bits on text than on the pictures. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com
Reply by ●July 23, 20152015-07-23
On Thu, 23 Jul 2015 17:54:47 -0500, Tim Wescott <seemywebsite@myfooter.really> wrote:>On Thu, 23 Jul 2015 15:30:11 -0700, John Larkin wrote: > >> On Fri, 24 Jul 2015 01:19:09 +0300, Dimiter_Popoff <dp@tgi-sci.com> >> wrote: >> >>>On 24.7.2015 ?. 00:50, John Larkin wrote: >>>> On Fri, 24 Jul 2015 00:13:19 +0300, Dimiter_Popoff <dp@tgi-sci.com> >>>> wrote: >>>> >>>>> On 23.7.2015 ?. 23:49, rickman wrote: >>>>>> On 7/23/2015 4:34 PM, Phil Hobbs wrote: >>>>>>> On 7/23/2015 2:18 PM, John Larkin 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 approach is a CGI script that runs gnuplot under the covers. >>>>>>> IIRC quite a few folks do that. (I'm a static HTML guy myself.) >>>>>> >>>>>> Isn't there an actual oscilloscope display package under Linux? It >>>>>> should be fairly straightforward to drive that from an internet >>>>>> connection. I guess requiring the customer to installing such a >>>>>> package is not preferred. >>>>>> >>>>>> >>>>> He is after a browser plugin - something like VNC, the way I do it on >>>>> our spectrometers (I do not use a plugin but I could if I wanted to). >>>> >>>> Actually, I don't want a plugin, just a way for the browser to display >>>> a waveform, using some javascript. We can store any reasonable zipped >>>> javascript libraries in our gadget and deliver them to the browser. >>> >>>I am not sure I have seen that done for live graphics - then scaling, >>>perhaps autoranging etc., even if doable it would be a massive pain to >>>support with all browsers as they keep on evolving. >>>Your best bet might be to produce locally a .gif (or .png or whatever) >>>bitmap, maintain it live and persuade the browser to refresh it >>>regularly. Don't know how the latter is to be done though. >> >> We could do that in the FPGA! If nobody murders me for suggesting it. > >I don't know how to persuade a browser to auto-refresh, but GIF format >uses run-length limiting for compression. That means that line drawings >of few colors tend to be very small -- you'll use up way more bits on >text than on the pictures.There is some simple HTML thing that makes a page reload periodically. That's apparently easy to do. A BMP would be easy to make inside the FPGA, but that would be slow to load. Maybe the ARM could make a GIF or PNG. That would avoid all the javascript nonsense. We'd just have to find the code somewhere. This bmp is 556K bytes. https://dl.dropboxusercontent.com/u/53724080/Circuits/Current_Limiters/LM317L_ilim.bmp That wouldn't be really terrible to send once a second or so over 100 MBPS Ethernet. But my FPGA doesn't have enough RAM. -- John Larkin Highland Technology, Inc picosecond timing precision measurement jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
Reply by ●July 23, 20152015-07-23
On 7/23/2015 7:22 PM, John Larkin wrote:> On Thu, 23 Jul 2015 17:54:47 -0500, Tim Wescott > <seemywebsite@myfooter.really> wrote: > >> On Thu, 23 Jul 2015 15:30:11 -0700, John Larkin wrote: >> >>> On Fri, 24 Jul 2015 01:19:09 +0300, Dimiter_Popoff <dp@tgi-sci.com> >>> wrote: >>> >>>> On 24.7.2015 ?. 00:50, John Larkin wrote: >>>>> On Fri, 24 Jul 2015 00:13:19 +0300, Dimiter_Popoff <dp@tgi-sci.com> >>>>> wrote: >>>>> >>>>>> On 23.7.2015 ?. 23:49, rickman wrote: >>>>>>> On 7/23/2015 4:34 PM, Phil Hobbs wrote: >>>>>>>> On 7/23/2015 2:18 PM, John Larkin 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 approach is a CGI script that runs gnuplot under the covers. >>>>>>>> IIRC quite a few folks do that. (I'm a static HTML guy myself.) >>>>>>> >>>>>>> Isn't there an actual oscilloscope display package under Linux? It >>>>>>> should be fairly straightforward to drive that from an internet >>>>>>> connection. I guess requiring the customer to installing such a >>>>>>> package is not preferred. >>>>>>> >>>>>>> >>>>>> He is after a browser plugin - something like VNC, the way I do it on >>>>>> our spectrometers (I do not use a plugin but I could if I wanted to). >>>>> >>>>> Actually, I don't want a plugin, just a way for the browser to display >>>>> a waveform, using some javascript. We can store any reasonable zipped >>>>> javascript libraries in our gadget and deliver them to the browser. >>>> >>>> I am not sure I have seen that done for live graphics - then scaling, >>>> perhaps autoranging etc., even if doable it would be a massive pain to >>>> support with all browsers as they keep on evolving. >>>> Your best bet might be to produce locally a .gif (or .png or whatever) >>>> bitmap, maintain it live and persuade the browser to refresh it >>>> regularly. Don't know how the latter is to be done though. >>> >>> We could do that in the FPGA! If nobody murders me for suggesting it. >> >> I don't know how to persuade a browser to auto-refresh, but GIF format >> uses run-length limiting for compression. That means that line drawings >> of few colors tend to be very small -- you'll use up way more bits on >> text than on the pictures. > > There is some simple HTML thing that makes a page reload periodically. > That's apparently easy to do. > > A BMP would be easy to make inside the FPGA, but that would be slow to > load. Maybe the ARM could make a GIF or PNG. That would avoid all the > javascript nonsense. We'd just have to find the code somewhere. > > This bmp is 556K bytes. > > https://dl.dropboxusercontent.com/u/53724080/Circuits/Current_Limiters/LM317L_ilim.bmp > > That wouldn't be really terrible to send once a second or so over 100 > MBPS Ethernet. But my FPGA doesn't have enough RAM. > >Bumpfiles are simple, so that's a win. I usually generate those in my code, then (in a script) call ImageMagick's 'convert' to make them into .jpg or .png or whatever. Cheers Phil [system("convert foo.bmp foo.png") covers a multitude of sins]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
Reply by ●July 23, 20152015-07-23
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.Java might be a tad slow. SVG might be better. But thers a bunch of API's out there, search javascript stripcharts. Cheers
Reply by ●July 24, 20152015-07-24
On Thu, 23 Jul 2015 20:24:48 -0400, Martin Riddle <martin_ridd@verizon.net> 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. > >Java might be a tad slow. SVG might be better.Yeah, svg looks promising. If I let the FPGA do the acquisition (some clever auto-trigger-oscilloscope algorithm based on the ADC data?) and buffer maybe 250 or so points per waveform, the ARM could read that data and build a not-absurdly long svg/html thing to send back, once a second maybe. -- John Larkin Highland Technology, Inc lunatic fringe electronics jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
Reply by ●July 24, 20152015-07-24
On 23/07/2015 19:18, John Larkin 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.Might be worth you talking to Bob Masta (sp?) who does Daqarta. Not sure if any of his stuff is in Java though. -- Regards, Martin Brown
Reply by ●July 24, 20152015-07-24
On Thu, 23 Jul 2015 21:08:55 -0700, John Larkin <jlarkin@highlandtechnology.com> wrote:>On Thu, 23 Jul 2015 20:24:48 -0400, Martin Riddle ><martin_ridd@verizon.net> 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. >> >>Java might be a tad slow. SVG might be better. > >Yeah, svg looks promising. If I let the FPGA do the acquisition (some >clever auto-trigger-oscilloscope algorithm based on the ADC data?) and >buffer maybe 250 or so points per waveform, the ARM could read that >data and build a not-absurdly long svg/html thing to send back, once a >second maybe.AJAX, works ok. Theres a difference in implemntation between browsers tho. I used that to send indicator/display information. Be willing to support future browsers with a firmware update. Cheers
Reply by ●July 24, 20152015-07-24
On 2015-07-24, Martin Riddle <martin_ridd@verizon.net> wrote:> On Thu, 23 Jul 2015 21:08:55 -0700, John Larkin ><jlarkin@highlandtechnology.com> wrote: > > > AJAX, works ok. Theres a difference in implemntation between browsers > tho. I used that to send indicator/display information. > Be willing to support future browsers with a firmware update.If you get it right you won't need to update. Don't guess, follow the standards, it's just like reading a datasheet, except that errors in the description are fixed by updating the product. -- umop apisdn
Reply by ●July 24, 20152015-07-24
On Thu, 23 Jul 2015 11:18:09 -0700, sipping burgundy and listening to Mahler, 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.Actionscript running in the Flash plugin should be able to do it better than Java or JS. Use the free Flashdevelop editor and compiler. I've done some neat stuff with it. The learning curve is horrendous. A PHP or Perl script on the server end formats and sends off data blocks on request. Or have it streaming continously. - YD.







