set the analog output to a value

I wanna program the analog output to a value, so if i push on a button in vb.net the value should rise with
for example 1v i dont know how to begin with this, does any have an example or where i can find an example the value shoud vary between 0 and 10V

Thanks in advantage

I wanna program the analog output to a value

Wanna? Leave the slang out of your posts.

Most Arduinos can't do true analog output. They can do PWM, which, to some devices, makes it appear that the output voltage is changing.

so if i push on a button in vb.net the value should rise

How will the Arduino know that you pushed a button in some application on some other computer?

the value shoud vary between 0 and 10V

The Arduino can not output 10V.

The first thing to note is that the analogue output from the Arduino is not a fixed voltage, rather it switches rapidly from 0V to 5V and the duty cycle is set by analogWrite(). The function would have been better named PWMWrite() but it will not be changed now. You can turn the PWM signal into a voltage using external circuitry.

Note that the maximum output voltage of the Arduino is 5V so external circuitry will be required to provide 0 to 10V output.

How will VB control the Arduino ? Probably via a serial link but you have not said.

First of all, most Arduino's don't have an analog output (DAC). analogWrite() is used for PWM. But you did not tell us which board you used. And most definitely no board will go up to 10V.

Okay, let's take a step back. This is what we call a XYproblem. Let's ask a couple of questions:

  • For what device do you need 0-10V?
  • What currents are we talking about?
  • What have you tried?
  • Are you stuck in the 0-10V part or the vb.net communication part? Try to tackle a single problem at a time.