Visual Basic control the servo motor using EB500 Bluetooth
hsiaochung
Posts: 17
I write a bs2 program and visual basic program
By using a EB500 with board of Education(BOE) and a bluetooth dongle connected with PC
I launch my visual basic program and write the bs2 program into BOE
I click the forward , backward , left turn , right turn
It is ok , but for a while after·several moves,
THE Connected led on the EB500 will extinguish
Why ?
I have replaced serval bluetooth dongles to test
But above situation also exist
By using a EB500 with board of Education(BOE) and a bluetooth dongle connected with PC
I launch my visual basic program and write the bs2 program into BOE
I click the forward , backward , left turn , right turn
It is ok , but for a while after·several moves,
THE Connected led on the EB500 will extinguish
Why ?
I have replaced serval bluetooth dongles to test
But above situation also exist
rar
6K
Comments
replace "GOSUB main "
with "RETURN"
Each GOSUB must have a RETURN
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Have Fun
TR
But it does not work
' {$STAMP BS2}
' {$PBASIC 2.5}
command VAR Byte
main:
· DO
··· SERIN 0, 84 ,10 ,move, [noparse][[/noparse]command]
··· 'DEBUG DEC command
··· GOSUB move
· LOOP
move:
· SELECT command
··· CASE 1 'Forward
····· DEBUG "f"
····· PULSOUT 13, 850
····· PULSOUT 12, 650
····· PAUSE 20
··· CASE 2 'Left Turn
····· DEBUG"l"
····· PULSOUT 13, 850
····· PULSOUT 12, 850
····· PAUSE 20
··· CASE 3 'Right Turn
····· DEBUG"r"
····· PULSOUT 13, 650
····· PULSOUT 12, 650
····· PAUSE 20
··· CASE 4 'Backward
····· DEBUG "B"
······ PULSOUT 13, 650
······ PULSOUT 12, 850
······ PAUSE 20
··· CASE 5 'Stop
····· DEBUG "s"
····· PULSOUT 13, 750
····· PULSOUT 12, 750
····· PAUSE 20
· ENDSELECT
·RETURN
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Have Fun
TR
Post Edited (TechnoRobbo) : 7/19/2007 2:11:38 AM GMT
no use
any other suggestion
It would those who are trying to help you if when a suggestion didn’t work you provided more detail as to why or what happened. Responses of “it does not work” and “no use, any other suggestion” don’t convey why the suggestions didn’t work making it difficult to offer anything additional. I hope this helps you to get your problem solved. Take care.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support