Under the times of the Industrial Internet of Things, the traditional centralized machine learning management method cannot deal with such huge data streams, and the problem of data privacy has aroused widespread concern. In view of these difficulties, in this article, we use the advantages of edge computing and federated learning, combined with the outstanding characteristics of the blockchain, to propose a secure data transmission method. First, we separate the local model updating process from the mobile device independent process; second, we add an edge server so that most of the computation is carried out on the server, which improves the learning efficiency; and finally, we use a distributed architecture of the blockchain to protect data security and privacy. Extensive simulation experiments show that the accuracy of our model can reach 98%. In addition, BC-EdgeFLs interception rate of illegal information can reach 0.8, which has good defensive capabilities. Therefore, the security of data transmission can be strongly guaranteed.