Not so long ago, Ben Drew, aka the hip-hop artist Plan B, met his childminder, a woman he had not seen in more than 20 years.

It was a touching moment for both of them and laughs were had while stories were exchanged. Drew was just six years old when he had last been in the woman's care, and she went all misty-eyed as she recalled her strongest memories.

"She told me that when she used to pick me up from school I was always in trouble," recalls the 28-year-old. "She looked after me when I was at infant school and said that while I was often in trouble, I would deal with it. But there was this one time when I was inconsolable. I was crying and shivering and couldn't calm down."

Needless to say, the childminder was concerned. "She asked me what was wrong, and apparently a friend of mine had got in trouble and it wasn't his fault, but no one would believe him. She said I was always in trouble for something I'd done, or was upset when something was really unfair. I don't remember this, but it makes sense."

It does indeed. Drew's first album as Plan B, 2006's Who Needs Actions When You Got Words, is bristling with righteous social comment. With his second album, however, he took a more soulful approach, and 2010's The Defamation Of Strickland Banks debuted at No 1 in the album charts.

"Throughout my hip-hop career I have tried to be the voice of the voiceless, to talk about things that exist among the lower classes in society, that other people choose to ignore or pretend don't exist – things that are unfair," Drew says. "I did that with my first record and then, with Strickland Banks, the soul thing, I kind of took a break from the politics and hip-hop."

In many ways, the success of The Defamation Of Strickland Banks proved both blessing and curse. It raised Drew's profile but also brought pressure from his record label, which didn't want Plan B returning to hard-hitting, venom-spitting hip-hop. It doesn't sell as many records. Drew, therefore, announced that he'd release his third album, the hip-hop-laden Ballad Of Belmarsh, on an independent label.

As it happens, that album will be delayed, and a different hip-hop record will stand in its stead as Plan B's third release. The new album is titled Ill Manors, and it comes out a month after the movie of the same name, which opens this week and is both written and directed by Drew. With an acting career taking off as well (he'll take a leading role in The Sweeney film this September), Drew is proving something of a polymath.

"Basically, I knew that if I was going to carry on doing hip-hop, it had to go through a different channel, because it wasn't working on radio," explains Drew of his shift into moviemaking. "I thought I should incorporate my hip-hop into a film because I just felt it would work better as part of a soundtrack; then it would be in context."

Drew, who grew up in Forest Gate in East London, applied for funding from Film London's Microwave programme, which had helped fund Eran Creevy's 2008 cult hit Shifty, and worked up a series of ideas into a film script.

"People who haven't heard hip-hop or don't like it will often just write it off," he adds. "If you don't give my hip-hop music a chance and actually listen to it, then you might think it's trying to glamorise violence and drug life, but I have never tried to do that. I have only tried to comment on it. That's why I figured if I put it into a film then I could show people this world visually, and you can see that it is a commentary and not something that's trying to glamorise what's going on."

There is nothing glamorous in the Ill Manors movie, that's for sure. The film is a full-length feature starring Shifty and Four Lions star Riz Ahmed (who's also collaborated with Plan B as MC Riz), which rattles along on a bruising and painful journey through the cruelty of life in and around an East End London estate where hard cash, hard drugs and hard violence are the only currencies of value. It's a grim and grimy affair.

The film unfolds a series of interlocking narratives, linked by people, place and Plan B's music, defined by shady characters and upsetting events. Back in 2008, Drew recorded a short film, Michelle, an equally distressing story about a dealer who exacts a shocking retribution on a prostitute for the loss of a mobile phone. The story is expanded in Ill Manors. "Ill Manors is a collection of stories which me or friends of mine have had experience of, and also some that I read in the newspapers," he explains.

Though Drew's father left when he was just six years old, he was raised in a more caring and financially stable household than many of his peers. The world around him was still brimming with temptation and violence, however, and he says he was lucky to escape. "It is a situation where you stay in that environment and you stay in that circle and get blinded by the madness – or get out, like I did."

The film deals with those who can't or won't get out. "For the movie, I took real things that have happened and put them all together in the same place, happening at the same time. The only fiction in the film is that these characters somehow affect each other. In real life it wouldn't happen like that — but the reality is that these things do happen even though some people might think that they're too extreme."

The music in the film and on the album, meanwhile, blends all of Plan B's styles and range. "It is hip-hop, with drum and bass in there — it is what I know best. But the experience of doing Strickland Banks has made me a much better musician. I understand a lot more now, so the Ill Manors record is hip-hop but it has elements of my singing, and maybe stuff I've done with Chase & Status, elements of anything I've been involved in musically. The important thing, though, is that if I am releasing a record with a film, the record needs to have its own depth. I didn't want the album to just be a collection of songs that you see in the film. It's trying to be an album in its own right. That means I can comment on the world we live in right now as well."

Even though Drew had written a lot of the intended music before and during filming, he eventually decided to wait until he had locked the picture before laying down the final music. During that delay, the London riots kicked off, offering Plan B an ideal avenue of approach. "I realised that the people in the riots are the same kind of people that the film's about," Drew notes. "It's the poor, from council estates, without great upbringings or a good support network."

Plan B released the Ill Manors title track in March — the greatest protest song in years, said The Guardian — with a video that plays out against the backdrop of the infernal chaos that the riots brought to the capital city. "That for me is relevant," continues Drew. "I am asking why the riots happened on that scale. These kids should be punished for breaking the law, of course, but if we just punish them and put them jail, they'll just come out worse.

"So we need to ask why these kids are not part of society. They'll risk their future by stealing a pair of trainers, so why do so many kids not care? I hope Ill Manors, the film and the album, give a reason why. Ill Manors deals with the everyday problems they face."

Ill Manors is in cinemas on Wednesday.

Plan B's album of the same name is released on July 16 by Atlantic Records