Please login or register.

Login with username, password and session length
Pages: [1] 2

Author Topic: Visual Basic 6  (Read 27099 times)

chris

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 1
Visual Basic 6
« on: September 14, 2005, 07:55:57 PM »

I downloaded the ActiveHome Pro SDK and even
though there is a folder for VB 6 samples,
there are none.  Did I miss something,
because I would really like to have those.  I
need to develop a Visual Basic 6 for a senior
design project.
Logged

bob

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 2
Re: Visual Basic 6
« Reply #1 on: September 19, 2005, 03:30:38 PM »

Hey Chris looks like we're both in the same
boat.  I also need info and VB 6 samples
for a Senior design project.
Logged

dwayne

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 5
Re: Visual Basic 6
« Reply #2 on: October 03, 2005, 11:40:40 AM »

Chris, Bob,

VB6 scripting for this device is not that
hard. After playing with it for a while, this
is what I have found:

So after adding the activehome component to
your project, add the  x10 part to your form.

Add a button

Source code for the button:

ActiveHome1.SendAction "sendplc", "a1 on"

This codes works if you use the standard name
for the X10 and the device is a1. It turns
the device on. For other commands the help
file is really good. I still have not found
out how to use the codes for the IR
Comnmander but I am still playing.

You can also:
"a1 off"
"a1 dim 75" dims to 75%
"a1 bright 100" brightens to 100%

I have just been figuring this out by myself.
If anyone else has some advice let me know.
Logged

dwayne

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 5
Re: Visual Basic 6
« Reply #3 on: October 03, 2005, 11:48:56 AM »

Oh, btw, I was probably a little vague in how
the help file helps. The best part is the:

Radio Frequency Command Reference

It lists all the commands that you can send
and receive for all devices.

The help file is located in AHSDK (appath)/
help. Then click on Radio Frequency Command
Reference. Let me know if you guys need any
more help with the scripting. It is a fairly
simple language once you get the syntax.

I am not sure how good the X10 help is after
reading some of the articles, but if we all
work together, I am sure we can figure
everything out.
Logged

bob

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 2
Re: Visual Basic 6
« Reply #4 on: October 31, 2005, 03:39:31 PM »

Thanks for the help Dwayne.

I'm still having a little bit of troubl it
seems.  I've added the ActiveHome component
to the form in VB6 and the X10 interface
along with the X10 control.  So I have 3
controls the ActiveHome1.RecvAction,

the X10Control1_X10Command(ByVal bszCommand
As String, ByVal eCommand As
X10Ctl.EX10Command, ByVal lAddress As Long,
ByVal EKeyState As X10Ctl.EX10Key, ByVal
lSequence As Long, ByVal eCommandType As
X10Ctl.EX10Comm, ByVal varTimestamp As
Variant)

and the
X10Interface1_X10Command(ByVal bszCommand As
String, ByVal eCommand As
X10Ctl.EX10Command, ByVal lAddress As Long,
ByVal EKeyState As X10Ctl.EX10Key, ByVal
lSequence As Long, ByVal eCommandType As
X10Ctl.EX10Comm, ByVal varTimestamp As
Variant)

I've also added a buttton for turning on
light A1. I run the program with the code:
ActiveHome1.SendAction "sendplc", "a1 on" in
the button but nothing happens.  I've
already tested the hardware with the
provided software and it works fine.

So I guess my question is does the code you
suggested go in the ActiveHome1_RecvAction?
And if so can I change it somehow to
ActiveHome1_SendAction?
Logged

bob

  • Full Member
  • ***
  • Helpful Post Rating: 0
  • Posts: 32
Re: Visual Basic 6
« Reply #5 on: November 09, 2005, 03:45:26 PM »

Ok, I think it was the PC I was on at
school.  Cause I just did exactly what you
said in your first message Dwayne and now it
works fine.  Thanks for your help man!
Logged

dwayne

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 5
Re: Visual Basic 6
« Reply #6 on: November 09, 2005, 04:30:29 PM »

np.

Glad I could be of assistance.
Logged

robert hiller

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Visual Basic 6
« Reply #7 on: November 22, 2005, 08:08:12 AM »

What hardware do I need if I only want to
use the SDK to read various X10 remote
controls. Also, Does ActiveHome software
have to purchased and installed? If someone
has a sample of reading remotes in VB6.0 it
would be helpful.
Logged

robert hiller

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Visual Basic 6
« Reply #8 on: November 22, 2005, 11:36:19 AM »

Dwayne,
Could you please explain what np. means?

Thanks,
Bob
Logged

robert hiller

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 9
Re: Visual Basic 6
« Reply #9 on: November 22, 2005, 12:43:48 PM »

I have six different remotes talking to my
application and I am controlling my Ninja
camera mounts. Not bad for a hour or 2 of
work. I guess thats why I make my living
with Visual Basic 6.0, It's so easy!

Bob
Logged

ben dowdy

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 1
Re: Visual Basic 6
« Reply #10 on: December 01, 2005, 02:39:23 PM »

I am getting a windows Exception from time
to time using the x10net.dll. any
sugestions ?
Logged

dwayne

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 5
Re: Visual Basic 6
« Reply #11 on: December 01, 2005, 03:08:44 PM »

np = no problem. Sorry I have been in
Computers for a long time and shorten
everything. I have noticed the x10 exception
once in a while. Make sure no electronic
devices besides the x10 stuff are sending out
static. Try unplugging various devices in
your home to see if it stops. If you find the
culprit, radio shack has a very inexpensive
gadget that you plug the device into and it
cleans up the signal.

Also, make sure no other x10 app is running.
There is something with the string in the
application x10 sends out that keeps running
after you close the program. It looks like a
ghost process. (Bad programming!)

I started programming in Pascal, switched to
Modula 2 in my undergrad, then ifol, then C,
then VB. I love VB but it put a lot of my
fiends out of work. Like you said, it is so
easy! Be careful with VB though, it is not
the most secure compiler on the planet.
Typical Microsoft product!  :)
Logged

amlana

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 1
Re: Visual Basic 6
« Reply #12 on: January 14, 2006, 05:27:14 AM »

when i open excel workbook by getobject it
show the messege box of macro or high
security or relation.what is the solution to
to close this message automatically by
progaramming
Logged

john

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 1
Re: Visual Basic 6
« Reply #13 on: January 26, 2006, 07:40:27 AM »

i need a package that i can use to develop
visual basic interface and analytical
heirarchy process algorithm.
Logged

Malak

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 3
Re: Visual Basic 6
« Reply #14 on: April 11, 2006, 04:15:44 PM »

Can I use the SDK to interface to the firecracker without having the Active Home adaptor
itself?
Logged
Pages: [1] 2
 

X10.com | About X10 | X10 Security Systems | Cameras| Package Deals
© Copyright 2014-2016 X10.com All rights reserved.