A communication apparatus that includes communication means configured to perform a first communication mode in which the communication means communicates with a terminal apparatus via wireless communication with an external wireless base station and a second communication mode in which the communication means directly performs wireless communication with the terminal apparatus without intervention of the external wireless base station , the communication apparatus comprising: setting means configured to enable at least either one of the first communication mode and the second communication mode; and control means configured to perform communication processing in the first communication mode and the second communication mode to set a communication period of the first communication mode per unit time to be longer than that of the second communication mode in a case where both the first communication mode and the second communication mode are enabled, a connection to a communication partner apparatus in the first communication mode is established, and a connection to a communication partner apparatus in the second communication mode is not established, and perform the communication processing in the first communication mode and the second communication mode to set the communication period of the second communication mode per unit time to be longer than that of the first communication mode in a case where both the first communication mode and the second communication mode are enabled, the connection to the communication partner apparatus in the second communication mode is established, and the connection to the communication partner apparatus in the first communication mode is not established; the communication apparatus further comprising: an antenna configured to support the wireless communication in the first communication mode and the second communication mode, wherein in a case where the first communication mode and the second communication mode are enabled, the wireless communication in the first communication mode and the wireless communication in the second communication mode are sequentially switched, and wherein the first communication mode and the second communication mode use different frequencies. setting means configured to enable at least either one of the first communication mode and the second communication mode; and control means configured to perform communication processing in the first communication mode and the second communication mode to set a communication period of the first communication mode per unit time to be longer than that of the second communication mode in a case where both the first communication mode and the second communication mode are enabled, a connection to a communication partner apparatus in the first communication mode is established, and a connection to a communication partner apparatus in the second communication mode is not established, and perform the communication processing in the first communication mode and the second communication mode to set the communication period of the second communication mode per unit time to be longer than that of the first communication mode in a case where both the first communication mode and the second communication mode are enabled, the connection to the communication partner apparatus in the second communication mode is established, and the connection to the communication partner apparatus in the first communication mode is not established; an antenna configured to support the wireless communication in the first communication mode and the second communication mode, wherein in a case where the first communication mode and the second communication mode are enabled, the wireless communication in the first communication mode and the wireless communication in the second communication mode are sequentially switched, and wherein the first communication mode and the second communication mode use different frequencies. <EOS>