imabot2 / serialib

Serial library for Linux & Windows
MIT License
195 stars 45 forks source link

cannot connect to my ft232 #7

Closed Basilisvirus closed 2 years ago

Basilisvirus commented 3 years ago

I think I am missing something, but both of your examples cannot connect to my ft232.

I am on windows 10, with code:blocks 20.03, mingw compiler (and i also tried cygwin compiler), with both of your examples.

Both fail on

if (errorOpening!=1) return errorOpening;

I have a atmega328p connected to the ft232 (so an arduino), which i can access from both arduino IDE and TeraTerm. I can send/receive data from both arduino and TeraTerm, So the device is there, working properly.

i defined/changed the com port to match my com port #define SERIAL_PORT "COM5" and i have no errors when compiling.

I include the libraries are shown from your examples:

#include "serialib.h"
#include <unistd.h>
#include <stdio.h>

I think there might be an issue with drivers?

maxgerhardt commented 3 years ago

Can you open the serial adapter using hterm.exe?

Basilisvirus commented 3 years ago

Thank you for your comment. I gave up on that and ended up using this library: https://www.teuniz.net/RS-232/ which works great