With the development of photovoltaic (PV) power generation technology, more and more families have begun to use solar energy. However, the uncertainty of solar energy production and user electricity demand has brought huge challenges to the development of efficient energy scheduling strategies. To deal with the uncertainty of electricity behavior, Monte Carlo generates the electricity scenario sets based on real data. According to the principle of minimum average distribution error (ADE), the scene with 200 scenes is selected for scheduling. Then, the Transformer model with random error (RE-Trans) is used to predict solar radiation and outdoor temperature. Through verification, it is found that the Mean Absolute Error (MAE) of the former is 0.389 and the Root Mean Square Error (RMSE) is 0.514. The MAE of the latter is 0.212 and RMSE is 0.413. To make effective decisions in the agent with the environment, a Deep Reinforcement Learning model with self-attention mechanism (SAN-DRL) is designed. The model aims to achieve a dynamic balance between electricity costs, carbon emissions and electricity sales income. Through continuous interaction with the environment, the agent finally obtains the optimal disordered charging and discharging behavior of energy storage systems (ESS) and electric vehicle systems (EVs), which greatly improves the utilization of solar energy resources. Finally, through simulation experiments, the proposed method is compared with both the baseline model and the ideal scheduling. The results demonstrate that the proposed method can reduce electricity costs and carbon emissions by 83.72 % and 72.08 %, respectively. Additionally, it achieves a net income of 38.59 CNY.