# Virtual Device Simulator

**URL:** <https://community.cumulocity.com/t/virtual-device-simulator/7376>\
**Category:** Forum\
**Tags:** cumulocity\
**Created:** [February 21, 2023, 1:59pm UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376 "2023-02-21T13:59:52Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Miller](https://avatars.discourse-cdn.com/v4/letter/m/bbce88/32.png) [@Miller](https://community.cumulocity.com/u/Miller)\
**Post date:** [February 21, 2023, 1:59pm UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376/1 "2023-02-21T13:59:52Z")

</div>

#### What product/components do you use and which version/fix level are you on?

Backend: **1014.0.204**  
UI: **1014.0.204**

#### Is your question related to the free trial, or to a production (customer) instance?

Production

#### What are you trying to achieve? Please describe it in detail.

I want to a virtual energy meters that generate example data e.g the followind data

- Current (L1, L2, L3, Sum) [A]

the device shall provide values between 70 to 150 mA in the night (20:00 to 05:00) and 5A and 100A during the day ( (05:00 - 20:00)

any idea how this can be achieved?

#### Do you get any error messages? Please provide a **full error** message screenshot and log file.

no

#### Have you installed all the latest fixes for the products and systems you are using?

yes

---

<div class="post-metadata">

**Author:** ![Robert\_Neale](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/robert_neale/32/31965_2.png) [@Robert\_Neale](https://community.cumulocity.com/u/Robert_Neale)\
**Post date:** [February 21, 2023, 3:34pm UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376/2 "2023-02-21T15:34:57Z")

</div>

There is a device simulator jar file, but it’s pretty basic. IT won’t schedule a different range of results for different time periods like what you want.

---

<div class="post-metadata">

**Author:** ![Harald\_Meyer](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/harald_meyer/32/1959_2.png) [@Harald\_Meyer](https://community.cumulocity.com/u/Harald_Meyer)\
**Post date:** [February 22, 2023, 8:28am UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376/3 "2023-02-22T08:28:24Z")

</div>

As Robert mentioned, the built-in [Device Simulator](https://cumulocity.com/guides/users-guide/device-management/#simulator) does not allow scheduling. There are a few other options:

- [Advanced simulator for Cumulocity](https://github.com/Cumulocity-IoT/cumulocity-advanced-simulator) provides an alternative UI for the built-in simulator but I do not think it allows for scheduled changes.
- [OEE Simulator](https://github.com/Cumulocity-IoT/oee-simulators) was created for the Cumulocity IoT OEE App but is quite flexible in its configuration. You could maybe create different schedules for the same device and control them with a shift plan.
- Streaming Analytics Builder - you could have a model that is controlled by a Cron Timer or a Time Ticker to create simulated data at different times of the day. The [contrib](https://github.com/Cumulocity-IoT/analytics-builder-blocks-contrib/tree/master/simulation-blocks) repository also contains some more advanced simulation blocks you can use if you are able to deploy custom blocks.

---

<div class="post-metadata">

**Author:** ![Darpankumar\_Lalani](https://avatars.discourse-cdn.com/v4/letter/d/e9bcb4/32.png) [@Darpankumar\_Lalani](https://community.cumulocity.com/u/Darpankumar_Lalani)\
**Post date:** [February 23, 2023, 6:58am UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376/4 "2023-02-23T06:58:32Z")

</div>

One more option is [Simulators provided by Application Builder](https://github.com/Cumulocity-IoT/cumulocity-app-builder):

- Random Value Simulator: Here you can change simulation data(value series) based on device operations.  
You could control device operations based on a model in streaming analytics as suggested by Harald.  
See below example:  

- CSV simulator: If you are having historical data in CSV file, then probably you could use csv simulator.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/system/32/31990_2.png) [@system](https://community.cumulocity.com/u/system)\
**Post date:** [August 22, 2023, 6:58am UTC](https://community.cumulocity.com/t/virtual-device-simulator/7376/5 "2023-08-22T06:58:33Z")

</div>

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
