Thread: VB6 communication with Atmel

  1. #1
    Registered User
    Join Date
    Aug 2008
    Posts
    33

    Question VB6 communication with Atmel

    hello CProgramming!

    I know I have said some rather stupid things on the forum,
    but I have a (more) serious problem this time:

    I am trying to communicate between a VB6 console app. and an Atmel 328 microprocessor.
    The program executes perfectly and successfully interacts with the Atmel.

    the problem comes before this though: I have to compile the code on the Atmel microprocessor every time or else the two do not communicate successfully.

    Ive been told that I need to look for a detection API of some sort.
    Can anbody offer me a little more specifics on the subject?

    -Thanx

  2. #2
    Registered User jeffcobb's Avatar
    Join Date
    Dec 2009
    Location
    Henderson, NV
    Posts
    875
    Quote Originally Posted by Else View Post
    hello CProgramming!

    I know I have said some rather stupid things on the forum,
    but I have a (more) serious problem this time:

    I am trying to communicate between a VB6 console app. and an Atmel 328 microprocessor.
    The program executes perfectly and successfully interacts with the Atmel.

    the problem comes before this though: I have to compile the code on the Atmel microprocessor every time or else the two do not communicate successfully.

    Ive been told that I need to look for a detection API of some sort.
    Can anbody offer me a little more specifics on the subject?

    -Thanx
    OK I will bite. As you may have noticed this is not a MICROSOFT Visual Basic forum so its unlikely you will get that help here. More, since amtel is not supported by Microsoft you will probably not get any product they make to generate code for it. What you need is a cross-compiler and at least some C knowledge....but doing embedded stuff can be tough for dabblers...you really gotta get your head into it to do it right and its a WAY different world than WinTel...way way different...if you go in that direction you will probably get some help here. VB? Not so much...
    C/C++ Environment: GNU CC/Emacs
    Make system: CMake
    Debuggers: Valgrind/GDB

  3. #3
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229
    Is it on an Arduino?

    What are you using the communicate? Serial port? Other UART-computer interface? Settings?

    Need more info.

    You shouldn't need to "compile the code" every time.

  4. #4
    Registered User
    Join Date
    Aug 2008
    Posts
    33
    Thank you jeffcobb and CyberFish.

    jeffcobb:
    Visual basic only really differs from other C++ compilers through extended librarys, doesnt it? So I should be able to compile my code - albeit swapping cout for printf, ect - through another compiler. No?
    If so, any suggestions?

    CyberFish:
    I though as much, but I do. I have been told to look at the HID library, do you think this will help register or create a connection between the app and the board via USB?

    - Thanks again.

  5. #5
    Registered User jeffcobb's Avatar
    Join Date
    Dec 2009
    Location
    Henderson, NV
    Posts
    875
    No. VB is heavily MS-centric meaning there is a high-dependency count on existing windows runtimes which are almost guaranteed not to work on any non-Intel platform. The exception here might be ARM which is still traditionally not MS-territory but Windows Mobile runs on some ARM chipsets and somewhere I recently read that MS is hiring ARM senior engineers for some server project or the other.

    A cross compiler on the other hand will take your C and/or C++ (most likely C) and compile it to generalized bytecode and then translate to target hardware platform machine code. VB (nor is VC, et al) doing that. Here is some more information: Cross compiler - Wikipedia, the free encyclopedia
    C/C++ Environment: GNU CC/Emacs
    Make system: CMake
    Debuggers: Valgrind/GDB

  6. #6
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229
    You still haven't told us what chip you are using to communicate but I'm going to assume it's a FTDI FT232R or similar.

    It's not an HID device, so I doubt it will help.

    The way it works is it "emulates" a serial port on the computer side, and send everything it receives out the FTDI chip in TTL/CMOS levels (not RS-232).

    As long as your computer detects the chip, your program shouldn't have any trouble communicating with it. Just talk through the virtual serial port.

    What EXACTLY is the problem? What are you trying to do? What's happening? What do you expect to happen? What board are you using? What are you trying to communicate?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Unkown Hang
    By Bladactania in forum C Programming
    Replies: 31
    Last Post: 04-22-2009, 09:33 AM
  2. Looking for communication lib
    By BrownB in forum C Programming
    Replies: 3
    Last Post: 04-27-2005, 10:01 AM
  3. Serial communication packets
    By Roaring_Tiger in forum C Programming
    Replies: 3
    Last Post: 04-26-2003, 08:33 AM
  4. Database Application VC++ or vb6..?
    By gardenair in forum C Programming
    Replies: 0
    Last Post: 04-13-2003, 10:06 PM
  5. communication
    By in need of help in forum C Programming
    Replies: 3
    Last Post: 12-27-2002, 03:56 PM