Go Down

Topic: Major help with VB -> Arduino (Read 3 times) previous topic - next topic

Du-z

#15
Aug 27, 2009, 03:42 pm Last Edit: Aug 27, 2009, 05:08 pm by Du-z Reason: 1
@ Andrew

I changed the names of the buttons, it had more problems that that though. thank you for the download.

Edit: IT WORKS!!!! thank you so much

@uber

thanks mate

jith

HI Andrew,
I am using your firmata VB code to control a simple remote control car.
I am trying to use the FirmataVB1.DigitalPinWrite command so what value would I have to use for the on state and the off state.And what are the pin numbers i can use?

Its like FirmataVB1.DigitalWrite(PinNumber,value)
          Pin NUmber can be 0-12
          what are the values for the keyword 'value' for on and off? :o

Andrew Craigie

Hi jith,

In code you'd pass the value 1 for on and 0 (digit zero) for off.

Regards.

jith

Thank you for that quick reply andrew.

Lets say if i want to use just the digitalpinwrite function,should i include the firmata.dll or digitalpincontrol.dll .which file should i include in the program.?

jith

I get this error when i try to use it.
I have changed the properties of the firmata component in design view to COM4 and baud rate 57600 which works for the sample application from your website.

I think i have to define a method to open the COM port,but dont know how.

Can you tell me what are the components that i need to include to use the  FirmataVB1.digitalpinwrite(Pin number value) option?

I have included only the firmata.dll as mentioned in your site.Nothing else.

Here is the error

Problem with digitalWrite
System.InvalidOperationException:The port is closed.
at System.IO.Ports.SerialPort.Write(Byte[] buffer,Int32 offset,Int32 count) at Firmata.FirmataVB.DigitalWrite(Int32 pin,Int32 value)

Go Up