What is the suggested way to stitch xpdAcq scan plans including a Tramp with hold/equilibration time?

12 views
Skip to first unread message

Soham Banerjee

unread,
Oct 17, 2017, 1:37:53 PM10/17/17
to xpd-users
For example, if I wanted to do the following: 

- Tramp from 300 to 90K, 2K steps
- Hold at 90K for 20 mins
- Tramp from 90K to 300K, 2K steps

Simon Billinge

unread,
Oct 18, 2017, 11:43:48 AM10/18/17
to Soham Banerjee, xpd-users
Thanks soham we will grab this use case and look into it
--
You received this message because you are subscribed to the Google Groups "xpd-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xpd-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xpd-users/eca137ab-97ff-41bf-98de-108480b91fbc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Message has been deleted

Chia-Hao Liu

unread,
Oct 24, 2017, 11:27:21 AM10/24/17
to xpd-...@googlegroups.com
Thanks for posting this question. I think this is a very good UC and you can achieve it following the steps below.

0. Assume you have created two desired ScanPlan with normal syntax and you can see them in ``bt.list()``.

1. define plans in a verbose way

>>> up = bt.scanplans['Tramp_120_90_300_2']
>>> down = bt.scanplans['Tramp_120_300_90_2']

2. import bluesky thingy again to make sure namespace is correct

>>> import bluesky.plans as bp

3. make the master plan which ramps down first, waits for 1200s (20mins) and ramps up

>>> master_plan = bp.pchain(down.factory(), bp.sleep(1200), up.factory())

4. executer the plan!

>>> xrun(<sample_ind>, master_plan)

Note: if for some reason you abort the scan, you need to redefine the ``master_plan``  before firing ``xrun``


In fact, each ScanPlan in xpdAcq is a valid bluesky scan plan and therefore this pattern is more preferred than a script.
Once you define your ScanPlans in a verbose way as in step 1 above, you can extend them freely! 

For example, you can create a master plan with two 60s single-shot scans before and after ramping by:

0. define ``ct_60`` plan in a verbose way

>>> ct60 = bt.scanplans['ct_60']

1. define new master plan

>>>  master_plan = bp.pchain(ct60.factory(), down.factory(), bp.sleep(1200), up.factory(), ct60.factory())

2. execute it!

>>> xrun(<sample_ind>, master_plan)


On Wednesday, October 18, 2017 at 11:43:48 AM UTC-4, Simon Billinge wrote:
Thanks soham we will grab this use case and look into it
On Tue, Oct 17, 2017 at 1:37 PM Soham Banerjee <sbane...@gmail.com> wrote:
For example, if I wanted to do the following: 

- Tramp from 300 to 90K, 2K steps
- Hold at 90K for 20 mins
- Tramp from 90K to 300K, 2K steps

--
You received this message because you are subscribed to the Google Groups "xpd-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xpd-users+unsubscribe@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages