Generating a value of output voltage for 100 ms

9 years 2 months ago #29529048 by Beginner
Hi,

I'm beginner for using MicroBasic. I want to generate a value of output voltage for 100 ms.

I've looked through the manual "nxtgen_controllers_userman" and I see in forum.

I make a little MicroBasic program:
BatteryVolts = getvalue(_V, 2) 

setcommand(_G, 1, PowerOutput) 

wait(100) 

On oscilloscope, I don't see a generating signal by my program.

Could you help me ?

Thanks

Please Log in or Create an account to join the conversation.

9 years 2 months ago #29529051 by Griffin Baker
Replied by Griffin Baker on topic Generating a value of output voltage for 100 ms
You did a query for the battery volts and not the poweroutput. Therefore, the value that is being thrown in the PowerOutput is 0. You need to assign it a value from 0 to +1000 or 0 to -1000.

Please Log in or Create an account to join the conversation.

9 years 2 months ago #29529055 by Beginner
Thanks for your answer.

I succeed in generating a signal for 100 ms
BatteryVolts = getvalue(_V, 2)

setcommand(_G, 1, 500) 

Current = getvalue(_A, 1)

print ("Battery = ",BatteryVolts," Current = ",Current,"\r")

wait(100)

But it is a periodic signal:



I want to generate a non-periodic signal:



I don't know how to write Micro Basic programme for a non-periodic signal.
Attachments:

Please Log in or Create an account to join the conversation.

Time to create page: 0.098 seconds