Some of the secrets I encourage with this issue are:
1. Make it a habit, so yes this is about building a routine, but if you create a family habit around when homework is done you will take some of the angst and emotion out of the situation because well it will just happen (to some extent).
2. Allow your child to set the agenda... which is about letting them do the subject they want to do when; but monitor it as we need to ensure we cover all subjects, not just the fun nor easy ones... but in essence let your little ones have strong input into what subject and tasks they want to do.
3. Create a conversation... it is easy to fall into "scream and shout parenting" around homework, so back up the bus a little bit and create a conversation around all that is happening... which is also about not having to know it all - it is okay to let your child know that you don't know the answer, but lets find out together!