added cell mode flag