Code:
#!/bin/bash
time=$(date +"%H:%M:%S")

while :
do
flag=0
until [ $time = '05:47:00' ]
do
echo "1st loop"
flag=1
done
until [ $time = '05:48:00' ]
do
echo "2nd loop"
done
done

How to add the conditional check for time at every step and if time is as mentioned and execute the script and move to nect step if the flag is 1.
At the end move to the first step and again wait until time is '05:47:00' and execute for the next day.