Sending messages via RS485 shield

I’ve wired up an RS485 shield per advice given, written a simple test sketch to send a series of 13 bytes to my RS485 device and…nothing happens. Tried swapping A and B on the shield over with no joy (the device has the two inputs labelled as + and -) . I’m not even sure where to begin troubleshooting and if the problem is in the wiring or the code here is what I wrote:
The arduino is a mega.
Pin 18 goes to DI
Pin 7 goes to DE
3.3v goes to RE
GND goes to GND on shield
GND goes to GND of RS485 device
5v goes to VCC

Should this code work? The RS485 device uses 4800, 8O1

/*-----( Import needed libraries )-----*/

//pin 7 DE -need to set high
//pin 18 DI- Serial1 TX Pin


/*-----( Declare Constants and Pin Numbers )-----*/

#define Pin13LED         13
#define DEpin 7


/*-----( Declare Variables )-----*/

byte dataframedown[13]={0x7f,0xf2,0xfa,0x01,0x00,0x00,0x49,0x55,0xfa,0xfb,0xfd,0x05,0xfc}; /

void setup()   {

 pinMode(Pin13LED, OUTPUT);   
 pinMode(DEpin,   OUTPUT);
 digitalWrite(DEpin,HIGH); //enable rs485 transmission on shield
 
 // Start the software serial port, to another device

 Serial1.begin(4800,SERIAL_8O1);   // set the data rate & odd parity on Serial1 (pin 18)

  for(int i=0;i<13;i++)
  {
      
   Serial1.write(dataframedown[i]);          // Send byte stream to Remote device
   delay (100);
  }
     

}//--(end setup )---


void loop()   
{
   digitalWrite(Pin13LED, HIGH);  // Show activity
   delay(1000);
   digitalWrite(Pin13LED, LOW);  // Show activity    
  delay(1000);
 
}//--(end main loop )---

/*-----( Declare User-written Functions )-----*/

//NONE
//*********( THE END )***********

I'm not even sure where to begin troubleshooting and if the problem is in the wiring or the code

Without knowing what RS485 shield you are using, and without knowing which RS485 device you are talking to, how can we be in any position to offer advice?

This Max485 is the shield. Wired up per advice given on an earlier thread. The device is a Somfy RS485 transmitter that has +,- and Ground connectors.

This is the shield.

I would expect, then, to see something that shows which pins are connected to what. I don't. What page did you see that information on?

The device is a Somfy RS485 transmitter that has +,- and Ground connectors.

That link doesn't work.

Normally RS485 chips have an #RE and a DE pin next to each other, and you always connect these together
and drive as one. This then controls direction, LOW = read, HIGH = write.

This is the 'how do I wire it up' thread RS485 - Beginners problems wiring up the shield - Project Guidance - Arduino Forum
BTW - this application is transmit only- no receive needed

I still don't know if the Arduino is the only sending device on the line.

If yes you can connect DE and RE both to Vcc. And you did you connect it to 3v3? It should work but if you power it with 5V then it's normal practice not to use 3v3 to pull things high if you don't have to...

If it's not the only transmitting device (like the device to talk to transmits back or there is another transmitting device) you can connect RE to Vcc and DE to a pin. Or even easier, connect RE and DE to the same pin. But if you're not the only transmitting device you have to be sure no one is transmitting if you want to start your transmission.

And is the resistor Rt already on the Shield? Or did you connect it yourself? (See datasheet for Rt)

Sorry, yes, the Arduino is the only sending device.
I have DE connected to pin 7 which I set as High and RE connected to 3.3v

I don't see anything marked RT on the shield

septillion:
I still don't know if the Arduino is the only sending device on the line.

If yes you can connect DE and RE both to Vcc. And you did you connect it to 3v3? It should work but if you power it with 5V then it's normal practice not to use 3v3 to pull things high if you don't have to...

If it's not the only transmitting device (like the device to talk to transmits back or there is another transmitting device) you can connect RE to Vcc and DE to a pin. Or even easier, connect RE and DE to the same pin. But if you're not the only transmitting device you have to be sure no one is transmitting if you want to start your transmission.

And is the resistor Rt already on the Shield? Or did you connect it yourself? (See datasheet for Rt)

yes, the Arduino is the only sending device.
I have DE connected to pin 7 which I set as High and RE connected to 3.3v

I don't see anything marked RT on the shield

Yeah, of course you don't see a RT connection. I referred to it as resistor Rt. Go look at the datasheet :wink:

But why connect RE to 3v3 instead of 5?

And if you only want to send and you're the only one sending (no other nodes or the device replying) you can just tie DE high as well. Or just put DE and RE together to a pin if you want to drive something receive as well.