Wall Mounted Intelligent Display Module
4Discovery-35 Page 14 of 27 www.4dsystems.com.au
10.4. ViSi-Genie Limitations
While the 4Discovery is capable of being programmed
using the basic ViSi-Genie Environment, there are
limitations that need to be observed. If the 4Discovery
is being programmed as a Slave Device on the RS485
network, it can only function in Polled mode, rather
than Event mode due to the RS485 interface being half
duplex rather than full duplex. 2-wire RS485 is only
half duplex. If the 4Discovery is being programmed as
a Master Device (Host) on the RS485 network, it can
operate using Event mode, however is limited in data
which can be returned from the slaves.
When the 4Discovery is used with the basic ViSi-Genie,
only a single Master/Host and a single Slave, can be
present on the network. This is the limitation with the
ViSi-Genie protocol, as there is no way to direct the
ViSi-Genie protocol to a specific Slave, and there is no
way for Half Duplex RS485 to handle the responses
from the slaves. If more than 1:1 is required, another
Environment such as ViSi will be required.
If the basic ViSi-Genie is to be used when operating as
a Slave Device, which is the typical operation for a 4D
display using ViSi-Genie, when selecting the Event
options on any given widget/object, “Reported
Messages” cannot be used. The Host must poll each
object on the 4Discovery in order to gain the required
information. 4Discovery cannot just send information
when it likes, which is the case of Reported Messages,
as the 4Discovery is a Slave and therefore is only
allowed to speak when spoken to.
If the basic ViSi-Genie is to be used when operating as
a Host Device, the Reported Message option can be
used as it can speak out to the bus as required since it
is the Master of the RS485 bus. However it is not
possible to request information from Slave devices,
such as the value of something, as there are no
standard functions available in ViSi-Genie to request
data from another device. This mode is typically only
useful if the 4Discovery only features controls such as
buttons, switches, sliders and knobs, which do not
require data to be displayed, and only send data out
to the slaves in order for them to do a specific
function. It therefore has limited but still applicable
applications.
Workshop4 PRO has an advanced ViSi-Genie
environment with new widgets which allow 4DGL code
to be executed by the ViSi-Genie environment when
various situations occur, such as button presses, data
being received, touch screen interaction, etc. With
Workshop4 PRO, a number of the above limitations
are lifted and therefore possible.
4D Systems has ViSi-Genie libraries for the Arduino
and the Raspberry Pi. The Arduino library has been
updated to include support for the 4Discovery, to
allow it to communicate as a Slave to an Arduino using
RS485 (external hardware is required on the Arduino).
It utilises the Turn Around pin on the 4Discovery in
order to control the Transmit/Receive functionality of
the RS485 transceiver. This Turn Around Pin control is
required as the ViSi-Genie Protocol is defined already
and therefore control of the 4Discoverys
Transmit/Receive mode needs to be controlled from
the Host, the Arduino. ViSi-Genie can be used with
other hosts, however these are the 2 platforms we
have libraries written for.
10.5. Workshop4 - Serial
The Serial environment in the Workshop 4 IDE
provides the user the ability to transform the
4Discovery into a slave serial graphics controller.
This enables the user to use their favourite
microcontroller or serial device as the Host, without
having to learn 4DGL or program in a separate IDE.
Once the 4Discovery is configured and downloaded to
from the Serial Environment, simple graphic
commands can be sent from the users host
microcontroller to display primitives, images, sound or
even video.
Refer to the “Diablo16 Serial Command Set Reference
Manual” from the Workshop 4 product page on the 4D
Systems website for a complete listing of all the
supported serial commands.