Author Topic: Bluetooth/Controller on MCU Thru Laptop?  (Read 2138 times)

0 Members and 1 Guest are viewing this topic.

Offline MaltiKTopic starter

  • Robot Overlord
  • ****
  • Posts: 300
  • Helpful? 2
Bluetooth/Controller on MCU Thru Laptop?
« on: December 09, 2008, 05:28:04 PM »

Ok, so heres the pseudoschematic:

Windows Controller -> Laptop -> C Code -> Hyperterminal -> Bluetooth Dongle -> BlueSMIRF -> MCU -> Actuators

Does anyone know of any C code that basically transmits packets of information (TX) from bluetooth to a bluetooth modem with UART (RX). I know I will have to configure the Baud rate and everything, and I think Hyperterminal can help with this but I am not sure.

What I basically want to do is use a standard Windows Controller on my Vista Laptop and when I use the left trigger or so, the motors on say Output 1 will go to high, and when I let go of the trigger, it will go to low.

I will have to read what kind of packets(?) are sent when each button is pushed on the controller?

I am thinking what I have to do is interface a controller with Hyperterminal, configure Hyperterminal to send packets thru the bluetooth dongle, and like I said, thru UART, set each output to high or low based on the pressed button


Is this practical or has been done?

Can anyone help me with this?
Warranty

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Bluetooth/Controller on MCU Thru Laptop?
« Reply #1 on: December 15, 2008, 04:38:23 AM »
You can treat your USB/bluetooth port like any other serial port. Most languages for your PC should give you the option to send serial data directly through serial (hyperterminal not required).

Choose a language, then google around for it. Tons of source code online.

Offline MaltiKTopic starter

  • Robot Overlord
  • ****
  • Posts: 300
  • Helpful? 2
Re: Bluetooth/Controller on MCU Thru Laptop?
« Reply #2 on: December 15, 2008, 02:34:48 PM »
I have checked many different codes, none come even close to doing what I want. Can you point me in the right direction? ^^
Warranty

Offline pomprocker

  • Supreme Robot
  • *****
  • Posts: 1,431
  • Helpful? 16
  • Sorry miss, I was giving myself an oil-job.
    • Nerdcore - Programming, Electronics, Mechanics
Re: Bluetooth/Controller on MCU Thru Laptop?
« Reply #3 on: December 15, 2008, 05:28:29 PM »
Yeah I have my $50 robot configured to do that with a BlueSMiRF, I hit "h" for (h)old and it stops moving. I hit 'r' for (r)eset and it activates the watchdog timer and the mcu resets

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: Bluetooth/Controller on MCU Thru Laptop?
« Reply #4 on: December 15, 2008, 08:31:11 PM »
Quote
I have checked many different codes, none come even close to doing what I want. Can you point me in the right direction? ^^
errrrr the photovore sample code that comes with the Axon has good values already ;D

I suspect there is something else that you aren't doing right . . . can you share what you are doing?

 


data_list