Project 5: Assignment Problem

As in project 5, Project 5:

it says to display the data visuals in the form of a graph showing the buzzer frequence and on and off, we can do the graph part by plotchart(), the matter is, graph is only done by javascript and for the buzzer buttons and all that animations and hide button stuffs we have to write code in HTML,

above i had tried to use js file with the graph but it does not work!

please share how to completed this Project.

You can perform all the task given in activity 5 using javascript:

  • You can set animations to your graph by using setAnimation(true) command.
  • You can add crosshair to your graph by using setCrosshair(true) command.
  • You can disable the download button by dataDownload(false) command after the plotChart() command.

Importantly, you’ve got the project 5 wrong. It says to add animation and crosshairs to the graph you’ve created in previous section (for LDR). Graphs cannot be plotted for output devices like Buzzer.

As for the controlling Buzzer and changing its frequency part is concerned, use analogWrite(“pin_number”,“value_of_freqency”) instead of digitalWrite in your code.

Values for frequency can only range from 0-255

Hope this helps! :smiley:


Thank you your dataDownload() code worked as if i am searching from two days in Bolt Documents i wouldn’t get it.
thanks once again

Can u tell what difference can we see after applying setAnimation(true); and setAnimation(false); code. I am not getting it as if i tried it many times.

1 Like

Thank you,
Your comment really helped me get the activities completed,
I was stuck in this very bad. :smile:

Hi @shriarshanpalli,

By default setAnimation is true. Set the setAnimation to false and look carefully at how the data is getting loaded inside the graph.

Do let me know in case you need further assistance.

Ok Thank you :smiley:

Thank you so much for the help :blush:

Hey @desaijugal14
setAnimation describes how to animate modifications made to a chart, instead of applying them instantly.
And setAnimation default value is true , so there will be no difference shown instantly between the
graphs plotted.