element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Sensors
  • Technologies
  • More
Sensors
Sensor Forum Sensor Network
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Sensors to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 18 replies
  • Subscribers 338 subscribers
  • Views 2318 views
  • Users 0 members are here
  • rs485hub
  • mqtt
  • 4g
  • rs485
  • mosquitto
Related

Sensor Network

corel_draw
corel_draw over 1 year ago

I am a newbie to the sensor network world. Any advice would be well appreciated.

My sensor has rs485 connector. So I want to relay my sensor  data  over 4g iot gateway  to my mqtt broker (mosquitto) and then to cloud.

I intend to use an rs485 hub to collect sensor readings from multiple sensors. 

The pipeline in summary sensor ===> rs485 hub ====> iot 4g gateway =====> broker (mosquitto) =====> cloud

/ My question is:

1) I saw modules called rs485 data logger , are those modules needed in this set up ?

2) are there any other considerations for robsutness of this set up

Links to references hardware :

a) rs484 hub: https://www.alibaba.com/product-detail/PINWEI-Industrial-RS-485-HUB-1_1600879469226.html?spm=a2700.galleryofferlist.p_offer.d_title.7eda43a6OXiLmr&s=p

b) iot 4g gateway: https://www.alibaba.com/product-detail/Ebyte-ODM-E840-DTU-EC05-485_1601113842515.html?spm=a2700.wholesale.you_may_like.1.50a23027Z2gCtw

Please kindly advice, and this is my first post so if I am breaking any of community rules so let me know so I can adjust accordingly.

Thank you!

  • Sign in to reply
  • Cancel

Top Replies

  • kmikemoo
    kmikemoo over 1 year ago in reply to corel_draw +2
    corel_draw Please forgive me if I start out too basic. I started learning this stuff by researching MODBUS RTU. MODBUS and RS485 are not the same. My simple approach may offend some, but... crawl, walk…
  • aswinvenu
    aswinvenu over 1 year ago +1
    The IOT 4g gateway already has an RS485 interface, Why do you want to use another RS485 hub? I think all what you want can be done using https://www.cdebyte.com/products/E840-DTU(EC05-485)E You may have…
  • corel_draw
    corel_draw over 1 year ago in reply to Robert Peter Oakes +1
    Thank you, I needed the hub in case I have multiple sensors ... It is not an essential component of the architecture I agree.
Parents
  • kmikemoo
    0 kmikemoo over 1 year ago

    You will need to determine if your gateway can handle multiple addresses on the RS485 bus.  My guess would be that it supports a single node.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • corel_draw
    0 corel_draw over 1 year ago in reply to kmikemoo

    Thank you! I was also worried if the gateway can do that. If I go for a better  gateway as in here https://www.alibaba.com/product-detail/Industrial-Gateways-Modbus-RTU-TCP-Master_1601044443084.html?spm=a2756.order-detail-ta-ta-b.0.0.54f82fc2Uya6yU,

    With the hub, will I be able to connect multiple sensors?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • kmikemoo
    0 kmikemoo over 1 year ago in reply to corel_draw

    corel_draw Please forgive me if I start out too basic.

    I started learning this stuff by researching MODBUS RTU.  MODBUS and RS485 are not the same.  My simple approach may offend some, but... crawl, walk, run.  MODBUS is the language.  It's not that important right now.  RS485 is the hardware - an old school telephone party line your information will travel on.  You can wire one sensor to the next to the next in most cases.  Each node on the line gets a different node address (1, 2, 3...).  Your RS485 "network" will probably be Master/Slave.  The Master asks the questions.  The Slaves answer.  The Master calls the Slave by the Node Address.  "Node 3:  What data is at data point 0x0010?"  Only Node 3 answers.
    When you wire it, A is always A.  B is always B.  For everyone.
    Put a 120 ohm resistor (only 1) at the very end of the line to dampen any "bounce-back" of the transmission.  I liken this to a LONG hallway and all the nodes are rooms along the hallway.  If there's a lot of echo in the hallway, you'll have a hard time hearing when your node number is called.  Hang a blanket on the wall at the end to dampen the echo.

    Where Gateways come in is if you need two or more Masters asking questions.  Now we need a traffic cop.  Your turn.  My turn.  His turn.  Her turn.  Repeat.
    OR if we need to change transport media - say going from our little simple wire party line to Ethernet.  This is your application.
    You should be fine starting out with Gateway -> Device -> Device.

    You will also run into MODBUS TCP/IP.  This is a bit of what your Gateway will be doing - sort of.  MODBUS TCP/IP simply takes the MODBUS RTU data packet, wraps it neatly in an ethernet TCP/IP "box" and puts it on the ethernet network.  That network does it's thing and delivers the box where its supposed to go.  One the other end, MODBUS TCP/IP pulls the MODBUS RTU stuff out of the box and either processes it or plops it onto a different simple party line RS485 network.

    I hope this helps.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • colporteur
    0 colporteur over 1 year ago in reply to kmikemoo

    EXCELLENT! Great high level intro  kmikemoo  .

    Terminating the end with a resistor is a valuable tip. I recall first learning about scsi. The instructor had this complicated description of terminations. I spent almost a lifetime in RF. Understanding that you are terminating the end of a transmission line to eliminate reflections, caused his complicated description to disappear.

    I'm curious about your 120 ohm value. I've used 600, 50 and 75. 120 is a new one on me.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • kmikemoo
    0 kmikemoo over 1 year ago in reply to colporteur

     colporteur I have no idea where the value came from - but we also use it for CAN.  In  teaching basic CAN or RS485 troubleshooting - with the system powered down - check the resistance between A and B.  It should be 60 ohms.  120 ohms from the Master (in most cases but not all) and 120 ohms at the furthest point of the network/cable run.  NO star topography.  Those little branches can become stub attenuators. Laughing

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • colporteur
    0 colporteur over 1 year ago in reply to kmikemoo

    I never played in that space so the values would seem foreign to me. As soon as you mentioned transmission you brought back knowledge gained 30 years ago. Thanks for the trip down memory lane.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • colporteur
    0 colporteur over 1 year ago in reply to colporteur

    https://kvaser.com/developer-blog/how-to-test-your-can-termination-works-correctly/#:~:text=It%20is%20well%20known%2C%20in,each%20end%20of%20the%20bus.

    I found this on quick search of CAN network termination. Wow at 63 I learned something new. Now if I could only remember it:)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • kmikemoo
    0 kmikemoo over 1 year ago in reply to colporteur

    colporteur I didn't understand the problems with star topography until I got into Amateur Radio about 6 years ago.  Now it all makes sense.

    It's not surprising that you found Kvaser.  They make many of the CAN readers/programmers used around the world.  I've used their stuff on German, Swedish, Japanese, Italian and American equipment.  They like customizing their stuff for the different OEMs.  We have 3 readers that look exactly alike but will only work on their respective engine lines.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • kmikemoo
    0 kmikemoo over 1 year ago in reply to colporteur

    colporteur I didn't understand the problems with star topography until I got into Amateur Radio about 6 years ago.  Now it all makes sense.

    It's not surprising that you found Kvaser.  They make many of the CAN readers/programmers used around the world.  I've used their stuff on German, Swedish, Japanese, Italian and American equipment.  They like customizing their stuff for the different OEMs.  We have 3 readers that look exactly alike but will only work on their respective engine lines.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube