No announcement yet.

Scope example

  • Filter
  • Time
  • Show
Clear All
new posts

  • Scope example

    Hi there,

    Can scope trace points be added by 4DGL code or are they ONLY added by external serial commands?

    Ideally I'd like to add points to the scope by both code and external serial.

    Thank you

  • #2

    It's unclear to me under which environment of Workshop4 you are currently developing your project in, could you please indicate it?

    You mentioned adding trace points with "4DGL code", which by inference -- are you referring to Genie Magic which is only available in ViSi-Genie environment? If indeed you are working under this environment, please note that you can only add maximum of 4 scope trace points. You might find this forum post and appnote helpful:

    AN-00028 ViSi Genie Single Trace Scope

    Furthermore, there are 2 Scope examples in Workshop4. You can find them by clicking File, then Samples and then click on Diablo Designer.
    You should find the two program files, namely:

    I hope you find this helpful. If you have further question, please don't hesitate to ask.

    All the best,
    Last edited by sherwin4D; 24 March 2020, 07:57 PM.


    • #3
      Hi Sherwin,

      I haven't started the project yet. I'm in the "early evaluation stage" and so asking questions before I get started.

      We currently only have the free version of workshop and I've only just started looking at it.

      Probably best explain in brief what I want to do, then perhaps you could point me in the right direction:

      For arguments sake, let's say I have a temperature sensor and I want to both log the temperature to a file and plot it (scope).

      I have two options; a) Using just one of your displays - try and communicate with the sensor directly via Modbus RTU and both log and plot the temperature or
      b) Employ microcontroller-based module to talk to the temperature sensor and pass on the information to your display.
      At this time I have no idea which way I'll need to go because I'm not sure what your displays are capable of on their own.

      Ideally I'd go for option a), where your display acts as the core processor AND display - without the need for a 3rd party micro.
      However, I'm OK with b), too.

      The system will typically plot (scope) and log temperature say, once every 10 seconds.

      If option a) then your display will need to poll the sensor for data via Modbus RTU, display, plot and log the temperature.
      Do you think this can be done?



      • #4

        That explains it. Thank you for the added information.

        In any case, if you want to proceed with option A, you might find this example helpful:
        4D-CD-00133 Designer or ViSi Modbus RTU How to Write to Output Coils

        From 4D Maker's:

        You can use Designer or ViSi environment if you want more flexibility and control on your project just like the above example.

        If you want to proceed with option B, you could use ViSi-Genie environment to develop your project. Please have a look at this appnote for your reference:
        AN-00015 ViSi-Genie Displaying Temperature Values from an Arduino Host

        You could also achieve the same result without the host controller if you have Pro license for Workshop4 IDE which would let you have access to all the pins of the display module via Genie Magic.

        So, as you can see, there are multiple ways you could achieve what you want to do using our display solutions.

        Hope these information helps. If you have further query, please don't hesitate to ask.

        Kind regards,
        Last edited by sherwin4D; 25 March 2020, 06:47 PM.