There is only one medium and that is shared by many hosts or half dulex and you want to transmit data then you can transmit by two ways
1st. just transmit your data without thinking.this approach is contention-based in which there are high chances some collision will occur with some other host transmitting. example ALOHA is contention based protocol
2nd Transmit only if it is your turn to transmit.This is contention-Free approach ( contention-less ), you wait for your turn and are allowed to transmit only when you are up. contention free protocol don't allow posssibility of colliding frame.
The data link layer functionality is usually split it into logical sub-layers, the upper sub-layer, termed as LLC, that interacts with the network layer above and the lower sub-layer, termed as MAC, that interacts with the physical layer.
The primary responsibilities of LLC are:
1. Network Layer protocol Multiplexing/De-Multiplexing
2. Logical Link Services ( Connectionless , Connectionl oriented)
The primary responsibilities of mac are:
1. Framing/De-Framing and interaction with PHYSICAL LAYER
2. Collision Resolution