frostadsaxa
Posts: 1
Joined: Wed Jan 12, 2022 12:58 pm

highcharts gauge from mic

Hello,

i'm new to highcharts and javascript in general, but wants to learn.

i want to use the vumeter using highcharts gauge using getusermedia from mic input. Then, i found this code while browsing and try to get an idea from it : https://codepen.io/slatius/pen/BqblG
The code itself doesn't run on the first try and always throwing error about :

Code: Select all

Uncaught TypeError: context.createAudioBuffer is not a function
this line is causing the error :

Code: Select all

var buffer = context.createAudioBuffer(11025,100,0.2);
and then i replace them with :

Code: Select all

var buffer = context.createBuffer(2, 22050, 44100); 
based on this resource : https://developer.mozilla.org/en-US/doc ... eateBuffer
The error is now gone.

However, the vumeter still not moving when i talk to the mic. and i'm run out idea how to fix it.

Can someone here help me solve this please? or at least show me the right direction?
i know this is more related to javascript rather than highcharts gauge issue, but they all recommend to ask here.

Than you very much in advance.
magdalena
Posts: 517
Joined: Tue Aug 24, 2021 1:32 pm

Re: highcharts gauge from mic

Hello frostadsaxa,

Welcome to our forum and thanks for contacting us!

Highcharts is a library that allows you to create a chart based on existing data. Your question is more related to the configuration of audio buffer data collection than setting the Highcharts.

I would recommend asking this directly on StackOverflow. When you will have ready data, you can come back and I'll show you how to parse and show it on the chart.

Regards!
Magdalena Gut
Developer and Highcharts Support Engineer

Return to “Highcharts Usage”