You can say 'speaking as a parent' or 'speaking as a teacher', for example, to indicate that the opinion you are giving is based on your experience as a parent or as a teacher.
You use speaking in expressions such as generally speaking and technically speaking to indicate which things or which particular aspect of something you are talking about.