Controlling Blinds via RS232

We have a flexible roof on our terrace with blinds on each side I would like to embed in our Fibaro Home Center.

The controller and remote are from Teleco - since Teleco offers a RS232 module (https://www.telecoautomation.com/de/scheda_prodotto/tvtrx232/) for home automation I ordered it right away assuming it should be easy to control it via an Arduino.

Specs of the module: https://manuals.plus/m/dded6aec2ec2d56f28eeb17e070109312d2e7165f1561dd2dc8bcae845c19c58_optim.pdf

The TVTRX232 module works just fine using my macbook, a random usb2rs232 converter (Amazon: B01LVYR1AB) and Serial (Decisivetactics).

However it doesn't react at all when trying to send the same hex-code from my Arduino - meanwhile tested two different Arduinos as well as two different TTL converters (1: Amazon: B07ZDK4BLH 2: Conrad: 1310314 ).

I've tried both via the hardware serial as well as using SoftwareSerial.h - same no-result. Also tried multiple approaches on how to send it:

#include <SoftwareSerial.h>

int RX_PIN = 2;
int TX_PIN = 3;

const byte DataStream[] = 
{
  0x54, 0x01, 0x2F, 0x00, 0x01, 0x85,
};
const int DataStreamLength = sizeof DataStream;

unsigned long previousMillis = 0;  
const long interval = 5000;    
const int ledPin =  LED_BUILTIN;

void setup() {
  Serial.begin(19200);
  while (!Serial) {
    ; // wait for serial port to connect. Needed for native USB port only
  }
  Serial1.begin(19200);
}

void loop() {
  unsigned long currentMillis = millis();

  if (currentMillis - previousMillis >= interval) {
    // save the last time you blinked the LED
    previousMillis = currentMillis;
    pinMode(ledPin, HIGH);
 
    delay(2000);
    Serial.write(DataStream, DataStreamLength);
    //Serial1.write(DataStream, DataStreamLength);
    delay(2000);
    Serial.write("0x54012F000185");
    //Serial.write("0x54012F000185");
    delay(2000);
    Serial.write(0x54);
    Serial.write(0x01);
    Serial.write(0x2F);
    Serial.write(0x00);
    Serial.write(0x01);
    Serial.write(0x85);
    delay(2000);
    pinMode(ledPin, LOW);
  }
}

I must be missing something - if I connect the Arduino to the mac it seems to send it just fine, however the module does not respond at all - no commands are being sent to the blinds, no response back via rs232 (not even an error).

Any ideas?

Thanks
Michael

PS: sorry I would have put the amazon links, but it was allowing only two links :wink:

could you upload a schematic showing how you have connected the devices?
I assume you are running the code on a Mega? should the Serial.write() statements in loop() be to Serial1 ?

I tried multiple versions - using D0&1 for RX/TX, D2&3 as well as D10/11.

The shield obviously is just plugged ontop of the UNO, the other ttl converter connected to the3v+grnd as well as the digital pins described above.

Sry on my mobile, dont have any descent drawing tool around.

Hello platcraft
Take a view here to gain the knowledge about.

Have a nice day and enjoy coding in C++.
Дайте миру шанс!

const byte RX_PIN = 0; // goes to TX of tranceiver or default setting of jumpers on the shield
const byte TX_PIN = 1; // goes to RX
const byte ledPin =  13;

void setup() {
  Serial.begin(19200);
  while (!Serial) ;
  digitalWrite(ledPin, HIGH);

  Serial.write(0x54);
  Serial.write(0x01);
  Serial.write(0x2F);
  Serial.write(0x00);
  Serial.write(0x01);
  Serial.write(0x85);
  delay(200);
  digitalWrite(ledPin, LOW);
}

void loop() {
  if (Serial.available()>=1)Serial.read();
}

if uploading of sketch not successful then unplug the shield

Are you using an UNO or a Mega? Using Serial1 implies a Mega...

You don't really want to use D0/D1 on the conrad shield since that is Serial and it is best to use that for debug. If you change the jumpers on the shield to use D2/D3, then you should be able to use SoftwareSerial to communicate.

Hi, @platcraft
Welcome to the forum.

The only drawing tool you need is a pen(cil) and you can draw your circuit and post an image.

Please include power supplies, component names and pin labels.

Thanks for using code tags.. :+1:

Tom..... :smiley: :+1: :coffee: :australia:

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.