Ways to learn Hamilton HSL code?

Hello, I’m new here!

I recently got put on my laboratory’s Automations team, and we use Hamiltons for a majority of our workflows. They are mostly the STAR model using VENUS 3 or 4. This is my first experience with the VENUS software.

I find the drag-and-drop editor to be very unintuitive and difficult to read. I’m more accustomed to how “regular” programming languages work, like SQL or Python. In other words, I’m accustomed to being able to scroll down one continuous page of legible code where everything is displayed, as opposed to having to open the properties of each and every step of a method to glean each of their functions. It makes me want to pull my hair out!

I was made aware that Hamilton uses a programming language called HSL, which is based in C/C++, which sounds great to me. Except for the fact that I cannot find any documentation for it. I’ve been literally scouring the internet for anything about HSL, and so far I’ve come up with a handful of PowerPoint slideshows about it, and this forum.

Is there any repository or documentation that I can read to teach myself HSL? Not the drag-and-drop VENUS stuff, but the actual, typed code? I know that there are things like PyHamilton or PyVenus out there, but I want to understand the base language itself, HSL, so that I can work off of a good foundation of knowledge.

I saw that Hamilton offers training courses for VENUS, but it seems like HSL is not the focus.

Please help!


Actually, I just made an astounding discovery!

If you open the Hamilton HSL Method Editor, then open the Help option, it will show an HSL reference library! All the keywords, functions, syntax, etc.

Damn I wish I could have found this earlier, because Hamilton does NOT make this obvious. I guess it makes sense that it is contained within the VENUS software itself as a help file, since they likely are very guarded about their proprietary stuff.

I think that’s why I couldn’t find any of it online - they likely want only those who purchase the VENUS software to have access to it. Oh well, I’m making some PDF copies of this stuff anyways. Hope that doesn’t violate copyright.


I think it’s a fantastic idea to learn HSL no matter if you are using Venus, PyHamilton, or any other interface. I also didn’t know about that feature of the HSL method editor.

I use VS Code with C++ syntax highlighting to view HSL files. I find this far more appealing than the HSL editor. It would be incredibly useful to introduce functionality of the HSL editor into VSCode, and I bet this is quite feasible.

Attached pic is HSL in VSCode


The idea that SQL and Python are “regular” languages is making me laugh because I’m old now I guess.



If you’d like to make the standard VENUS Method Editor more readable, you can also switch to View > Icon and Description. That will show more details about each step without having to open each one individually.


This would have saved me so much time


Hi all,

Hamilton Standard Language (HSL) can be a complex topic to talk about and is generally reserved as a means for those who have expertise in similar programming languages, such as C/C++ or C#, to extend the functionality of VENUS in a way that can only be done in a text-based programming environment.

Although there is always room for improvement, we put a lot of emphasis on the Help features in our software to the point that nearly every function has a Help (?) button. The documentation for HSL and HSL Method Editor are built directly into the software with the Help menu. If adding HSL to a Method in Method Editor (rather than HSL Method Editor) you can quickly access the Help documentation by clicking the “Help” button on the bottom right of the “HSL Code” dialog box, which includes topics such as “HSL Essentials” and “HSL Functions” among others.

I have uploaded some materials that you might find helpful as well:

A copy of the HSL Method Editor is included with every installation of the VENUS software. The executable, HxHSLMetEd.exe, can be found in the Hamilton\Bin directory. When you open the editor, you can navigate to the menu and under Help, select Help Topics to bring up the HSL overview help materials.



While I acknowledge that these tools and materials aren’t featured prominently, part of the reason is simply because the majority of solutions can be facilitated using the VENUS software, which is targeted more towards end users and automation specialists. To that end, on the support side, we do not explicitly train our applications or training staff on HSL or author solutions for our customers in HSL. There are exceptions such as when there is a need for a new library or to insert snippets of HSL code into the VENUS method (anyone who has used the assignment with calculation command in VENUS would find HSL a bit more flexible!), but for the most part, you can program what is needed within the various VENUS functions. Because of this, if you venture into the world of HSL programming, your options for support will be limited.

I hope that provides a bit more context and resources for you all!




Is there a consensus in the community about the quickest way to learn programming a Hamilton robot , without prior experience in Venus? Should I focus on HSL, or PyHamilton or Venus itself?

having prior experience in Python I also find Venus difficult to comprehend. It feels that whatever PyHamilton can do should be possible in Venus via a comand/library of some sort? I’m particulary interested in controlling periferal devices , such as heat shaker and thermocyclers

I think it depends on context - are you working for a company which may need to work in regulated areas etc? If so, python-based control of Hamiltons is going to be incredibly hard to implement on a regulatory point of view. If not, and you are flexible, then pyHamilton could be considered.

Either way, I’d suggest learning Venus first. It teaches you the core concepts of liquid handler programming. HSL is only needed for more complex stuff down the road. Hamilton already have lots of HSL libraries for interfacing with peripherals, so you may not need to code HSL yourself. PyHamilton has a lot of advantages which you can move to after learning the basics, but as I said, it depends.


We don’t need to comply with regulatory requirements at present but this may change in future. I programmed a BioMek a number of years ago - found it much easier compared to Venus, hence the question. I tried studying existing Venus methods (like learning to code from examples) but they all appear to be drastically different, even if all are dealing with DNA library preps. I struggle to find common logic or similarities since all icons/commands are somehow customized and visually different.

I’m a big fan of PyHamilton personally, I think it gives you the best of Venus (simulations, tracefiles) while giving you the flexibility and readability of Python. If you use PyHamilton you do inevitably have to learn Venus to some extent, but it’s less about reading complicated methods and more knowing the basic application features.

It’s also a really good foundation for a flexible lab automation infrastructure. It’s much easier to build complicated methods in Python than Venus. Once you have a lot of Venus methods in production though it’s hard to switch over to PyHamilton. If you give PyHamilton a shot I’m usually pretty quick with responding to troubleshooting queries.

1 Like

Didn’t you write most of pyHamilton :wink:

Nikolay, at the end of the day, its a liquid handling robot, so the core function will be based around the aspirate/dispense steps. Sequences are a key part which help to tell the robot where to pipette. Otherwise, the libraries/steps are to do with dealing with the logic of how to run those steps. There are other ways which integrate with Venus, like PyHamilton, PLR, there is a c++ version too, but if you suspect that regulatory approval will be needed at some point I still think going native is probably the way to go, but ultimately its personal preference.


I totally agree with @Gareth. If you are going to go with the regularory way, stay within the native Venus. I have been there and depending on your compliance officers your method might never see the light of day if you incorporate a python script. I am big fan of python, but GxP is a different beast.


I second all of this but want to add that I completed a series of Hamilton projects without any training and it sucked.

I enrolled in the training AFTER I was done and I was mad about the time savings that I was robbed of due to the lack of resources we had at the time. Also the Hamilton trainers are awesome.

Do the training, ask lots of questions!


@EricSindelar_Hamilton : thanks for this. do you have any more material which you can provide me for HSL documentation?

I’ve provided all the materials I have in my post earlier in the thread. The HSL Method Editor includes a help section that provides a considerable amount of content and examples.

1 Like

Thank u very much

1 Like