Test and Measurement Forum

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Post any questions you may have about our current range of USB data loggers

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Sun Mar 06, 2016 8:27 am

DrDAQ System operation (Medium).jpg
DrDAQ operation showing long term stability & Mains outages
11. SYSTEM SPECIFICATIONS & NEW SKETCH RELEASE


SYSTEM SPECIFICATIONS

This RS485 COMM System developed for remoting sensors of PICOLOG Data Acquisition Loggers such as: DrDAQ, Picolog 1012 & 1016 and others.

Transmission standard.............................RS485
Transmission medium 1...........................Standard twisted pair + common ground conductor or
Transmission medium 2...........................Twin coaxial line with shields as common ground.
Nominal line impedance..........................60/120 Ohm. 60 Ohm used to minimise reflections.
Operating temperature range (*)..................0 to 40 °C.
System in/out voltage transmission range......0 to 2500 mV, negative common.
System Resolution (**).............................8 bit or 9.8 mV over the dynamic range.
System accuracy....................................+/- 5mV within stated temperature range.
System Sensor input impedance..................> 0.5 MOhm (Slave inputs).
System output impedance(***)..................1 MOhm (requires 1 MOHm load or better).
System Voltage reference.........................2500 mV.
Line transmission speed............................58600 Baud. Lower speeds possible by software.
PC (USB) transmission speed......................115200 Baud. Lower speeds possible by software.
=======================================================================================
Software programmable settings(****)
Number of Iterations k...........................up to several million.
Minimum recycle time t..........................30 Millis (1000 Millis = 1sec. approx.).
Maximum recycle frequency.......................25 Hz approx.
Byte/Analogue conversion factor................cal. = 9.8 for V. Reference = 2.5 V.
restLvl – preset fixed Slave level................127 corresp. to 1250 m V with mains failure.
=======================================================================================
Serial Monitor programmable settings
Line transmission speeds........................4800, 9600, 14400, 19200, 28800, 38400, 56600 Baud
USB transmission speeds.........................same as above, plus 115200 Baud.
=======================================================================================
Master hardware support..........................Laptop PC with USB upload, control & Serial Mon.
Master supply voltage..............................USB bus, +5V Nom.
Master consumption from USB Bus................< 100 mA.
Slave hardware support............................Laptop PC for USB sketch upload & checking only.
Slave operating support............................Self standing with external +9V Linear PSU.
Slave consumption from +9V PSU.................<100 mA.
Linear PSU requirements...........................9V +/-2V, ripple & noise max: < 40 mV p.p.
Master & Slave software support..................Windows Xp & Windows 7 (tested).
Recommended Arduino 1 IDE.......................1.0.6 with ERW enhancement 1.05.
Recommended PC operating System...............Windows XP.

(*) Microprocessor is rated -45 to + 55°C. The Sytem has been tested in rated range of 0 to 40°C.
(**) Depends on Microprocessor used. More recent devices will allow up to 16 Bit Resolution.
(***) Depends on PWM filtering method. For RC filtering output impedance very high. If low output impedance required, use Operational Amplifier 3 pole Chebyshev Active filters as shown in previous postings.
(****) Software settings written in the sketch, as seldom changed. Serial Monitor parameter setting possible with sketch modification.



NEW SKETCH RELEASE

I have uploaded in the next REPLY: sketch_MASTER_485_7_7 and sketch_SLAVE_485_7_3 for operation with Slave working barefoot. Sketches are in WORD format as the previous ones.

a) Download each word file and copy and paste contents on a new blank IDE sketch.
b) Carefully check all entries of each sketch & compile it. Most problems are given by wrongly transferred inverted commas (“ “) or by missing interdict (// or /*, */) characters.
c) Connect Master & Slave units through the twisted wire line simulator.
d) Connect Slave to linear + 9V supply.
e) Connect Master & Slave to own laptops.
f) LEDS on Micros should turn on.
g) Check Reference voltage on both units and trim it to 2500 mV.
h) Check COMM ports. COMM port 2 recommended.
i) Connect a voltage source (pot giving out any voltage, 1250 mV preferred – in the example 637 mV) to one or all of Slave inputs.
j) Upload sketches and check auto opening of Serial Monitors (ERW 1.0.5 only).
k) If Serial Monitor does not open, check “preferences” on ERW.
l) Check Baud rate on Serial Monitors: must be 115200.
m) “Autoclear” must be on on both Serial Monitors.
n) At opening , Master on Serial monitor looks as SCREEN 1M. Now enter desired parameters in the Master sketch: k, t & restLvl. Re-load the sketch.
o) At opening , Serial Monitor may be blank or show SCREEN 2S, depends on speed of laptop.
p) Write “a” on Master Serial Monitor: it will show SCREEN 3M, Slave will briefly show “SLAVE RESET – SYSTEM ST-BY”, then go back to SCREEN 2S. System is now ready.
q) Write “b” on Master Serial Monitor and System will start operation, as per SCREENS 4M & 5S.
r) For 1250 V input Slave and Master will show “127” for 1250 mv input, in our example it shows “65”, for 637 mV input.


System is now operative and you can carry on checking the PWM output and the analogue output after the RC filters.

As many readers probably noticed, the described System was developed using Picoscope software, with a Picoscope 2000 series unit and Picolog software, with Picolog 1012 and DrDAQ Data Loggers. This instrumentation, plus a precision digital Multimeter, was all that was needed, forming a fully fledged Electronics Lab, to complete a relatively complex project.
Attachments
Screen 1M.jpg
Screen 1M
Screen 2S.jpg
Screen 2S
Screen 4M.jpg
Screen 4M
Screen 5S.jpg
SCREEN 5S
Last edited by Glovisol on Tue Mar 22, 2016 4:50 pm, edited 9 times in total.
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Sun Mar 06, 2016 8:37 am

Here are the new sketches.......enjoy!
Attachments
sketch_SLAVE_485_7_3.doc
(45 KiB) Downloaded 91 times
sketch_MASTER_485_7_7.doc
(53.5 KiB) Downloaded 103 times
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Tue Mar 22, 2016 4:32 pm

RS485 MONITOR4.jpg
RS485 data flow monitoring on the RS485 comm line
MONITORING DATA FLOW ON THE RS485 TWISTED PAIR LINE

In this post it will be shown how to monitor Sync and Data flow on the RS485 twisted pair wireline, to check faults or regular operation. The monitoring system is based on a simple, generally available RS485 to USB converter and on standard Serial Monitor Terminal software such as REALTERM, freely downloadable at: realterm.sourceforge.net.

With reference to the PC Screen above, the Realterm Serial Monitor displays Sync & Data in Binary Format in the following order:


255 - Sync Byte sent from Master to Slave.
255 - Sync Byte returned to Master by Slave.
Slave Sensor Channel 0: 110 corresponding to 1080 mV.
Slave Sensor Channel 1: 12 correspnding to 117 mV.
Slave Sensor Channel 2: 68 corresonding to 666 mV.
Slave Sensor Channel 3: 122 corresponding to 1195 mV.
Slave Sensor Channel 4: 218 corresponding to 2136 mV.
Slave Sensor Channel 5: 187 corresponding to 1832 mV.

The PC screen below shows Sync + Data flow for one channel with double precision (see previous Part 9) 16 Bit: here the Slave sends Bytes "1" and "172", e.g. 255 + 172 = 428.

In the next post RS485 Sytem Monitor installation will be covered.
Attachments
RS485 - USB Converter.JPG
RS485 to USB Converter in operation
RS485 MONITOR 2.jpg
RS485 data flow showing 1 channel @ 16 Bit
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Thu Mar 24, 2016 7:28 am

Realterm installation.jpg
PC SCREEN SHOWING COMM 23 FOR THE CONVERTER
INSTALLATION & SET-UP OF THE MONITORING SYSTEM

To set up the RS485 Monitoring System proceed as follows.

1. Go to the site of Future Technology Devices and download the drivers for the RS485 to USB Converter: http://www.ftdichip.com/ and install them.

2. Download the REALTERM software and install.

3. The RS485 to USB converter has three inputs: A, B and Ground. Connect the inputs in parallel to the corresponding twisted wire lines, Master unit side. The Converter has 4 jumpers: 5V - RX - TX and Ground. Remove the 5V jumper, because this unit will use the USB +5V.

4. Plug the USB cable into the converter: the PC will automatically install it. Right click the "My Computer" and go to "Devices", then to COM PORTS and you should see the converter on a new COM Port (probably with a high number such as 20 to 30) please see the PC screen above.

5. With this set-up, TWO windows will be used on the desktop: the Master Micro regular Serial Monitor accessing Arduino's COMM Port (in this example Port 22) and the RS485 to USB converter sending data to REALTERM through its own COMM Port (in this example Port 23).

6. Start the COMM System as usual: open the Serial Monitor and check the iteration sequence, then open REALTERM.

7. On page DISPLAY choose: uint8 - bytes 2[/b ]- [b]Rows 16 - Cols 32.

8. On page PORT choose: Baud 57600 - Port 23 - Parity none - Data bits 8.

9. Do not use pages: CAPTURE - PINS - SEND.

10. On page ECHO PORT choose: Baud 57600 - Port 23=\VCPO - Echo ON - Monitor.

11. Now click on the REALTERM black Monitor window and data sequences will appear. To have the proper Byte alignment click on CLEAR in between two iterations.
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Sun Apr 24, 2016 6:36 pm

Important and up to date information, also concerning the remoting issues on Arduino IDEs and compatibilities, is now available in the PROJECTS section, "BUFFERS/ISOLATORS FOR DrDAQ/1012/1016 DATA LOGGERS PART 3".
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy

Re: REMOTING SIX SENSORS ON ONE TWISTED PAIR - PART 11

Postby Glovisol » Wed May 18, 2016 6:56 am

ENTIRE RS485 COMMS SYSTEM TESTED ON ONE SINGLE LAPTOP

With the methods outlined here:

topic23801.html

the entire RS485 COMM System (Master + Slave Micros) can be tested on just one PC, by using one "C" HD based IDE (1.6.7) and another IDE (1.0.6) based on an USB dongle. PC shot below.
Attachments
RS485 COMMS on ONE PC.jpg
Master unit on left and Slave unit on right
Glovisol
Advanced User
Advanced User
 
Posts: 114
Joined: Sat May 11, 2013 10:03 am
Location: San Marzano Oliveto, Asti, Italy


Return to USB PC Data Loggers

Who is online

Users browsing this forum: No registered users and 0 guests