dear friend in order for one to help you will need to provide you system configuration but since you need a guide, download Trysim demo, it has a filler and packer machine as example programs. You can also build your program in here and test it with a physical machine you build in the software, and if okay you can directly send the code to the. CPU. codes created in Trysim are s7 codes.
good luck