A WALK around the many stands in one of the halls of McCormick Place, a gigantic convention centre in Chicago, during the annual conference of the International Association of Chiefs of Police (IACP), showed how the debate on policing has changed in America. The Peerless Handcuff Company was still hawking its wares, as was Peacekeeper, which sells batons and lets prospective customers bash “Numb John XT”, a dummy, to try them out. But the buzz, helped by a cohort of forceful public-relations executives, was around vendors of body cameras, data collection and information-sharing technologies with snazzy names such as Vievu, BodyWorn or SceneDoc.

Cops in America have had a tough year. Videos of perceived or real police brutality have gone viral at regular intervals, causing loud public outcry and leading to demands that all police officers should wear body cameras. These troubles are not going away. Violent crime is on the rise in nearly all big cities, and the level of trust between police and the public, and minority communities in particular, is at an all-time low. In Milwaukee, a genteel midwestern town, 104 people have been murdered in the first eight months of the year, more than the 86 who died in the whole of 2014. St Louis reported a 60% rise in killings over the same period. And in Chicago six people were killed and 28 wounded over just the weekend before the conference.

Hence heated discussions there about the reasons for the sudden increase in violent crime and the tense relationship between the police and civilians. In a speech on October 26th James Comey, the boss of the FBI, said he had no conclusive answer. But “something has changed in policing”, he said. Officers feel besieged by videos of arrests and other procedures proliferating on YouTube, a video-sharing website. Cops get taunted by youths holding up their iPhones. Sometimes they just don’t want to get out of their cars any more to ask a group of young men why they are standing around on a dark street corner at one in the morning. It feels too risky.

Mr Comey seemed to be saying that police officers cannot do their job properly if they are under constant scrutiny. This implies that they sometimes need to act in ways that seem brutal or unfair in order to be effective. Similar views have been heard from Chicago’s mayor, Rahm Emanuel, who said recently that worries about being filmed had prompted police in Chicago and across the country to become “fetal” and shy away from tangling with suspects. Some crime experts disagree. “It’s overly simplistic to blame YouTube,” says Brett Goldstein, a former officer who now teaches at the University of Chicago. He thinks that just as no-one could find a good reason for the decrease in crime—over the past 25 years crime rates have fallen almost by half—there is now no one reason to explain its rise. Crime rates are driven by all kinds of trends and events, from shifting gang dynamics and the spread of cheap heroin to a sudden change in the weather.

Barack Obama, the first president in more than 20 years to speak at the conference, also indirectly cast doubt on a link between viral videos and the rise of violent crime. He rejected the divisive notion of “us v them”, communities against the police. He also promised to ensure proper funding for policing, to continue his fight for reform of the criminal-justice system—in particular striving to reduce the high rate of incarceration—and to back officers’ demands for universal background checks on gun-buyers. But he also warned that law enforcement was not always done fairly, and that racial bias existed in the system. Before he had a motorcade, he said, he was sometimes pulled over by police on the road for no apparent reason. And he rejected as a “false choice” any trade-off between fairness and effective policing.

Mr Obama started his speech by mentioning Randolph Holder, a New York policeman recently killed while in pursuit of a gunman. Mr Holder was black, a dedicated member of the New York Police Department (NYPD), which has had a tougher year than many other forces. In December last year a deranged man shot and killed two officers, as they sat in their car eating lunch, in apparent revenge for the death of Eric Garner, a black man who died while being arrested with a chokehold.

Morale among the NYPD’s rank and file was already low. In an internal survey of the department in 2014, around 70% of respondents said that fear of being sued held them back from intervening to curb criminal activity on the streets. Many of the 35,000-strong force said they felt ill-prepared and undervalued. Since then New York has unveiled a community-policing plan, improved officer training and revised their Bible, the Patrol Guide, to say what they may do as well as what they may not.

Police chiefs left Chicago buoyed by the president’s thanks. Mr Obama affirmed that officers risk their lives in the line of duty, and that Mr Holder “ran toward danger because he was a cop”. But alongside that, chiefs will have to convey to their underlings the need to rebuild trust with minority groups. As Mr Obama said, the impression that some police are racially biased “does not come out of nowhere”.