
439 N.W.2d 92 (1989)
CITY OF MANDAN, Plaintiff and Appellee,
v.
Michael WILLMAN, Defendant and Appellant.
Cr. No. 880285.
Supreme Court of North Dakota.
April 19, 1989.
Vinje Law Firm, Bismarck, for defendant and appellant; argued by Ralph A. Vinje.
Sharon A. Gallagher, City Atty., Mandan, for plaintiff and appellee.
LEVINE, Justice.
Michael Willman appeals from a judgment of conviction of driving under revocation. We affirm.
In the early morning hours, a Mandan police officer observed Willman drive a pickup away from a loading ramp in a parking lot of a motorcycle shop, with a motorcycle in the box of the pickup. The motorcycle shop is located on frontage property on Memorial Highway, with two accesses to Memorial Highway. The officer observed Willman drive the pickup to one of the accesses and stop at a stop sign. Suspecting that the motorcycle in the pickup was stolen, the officer stopped his marked police car behind the pickup, turned on the interior light of the police car and jotted down the license plate number of the pickup and a vehicle parked nearby to check the vehicles' registration. Interpreting the officer's movement as a signal to move, Willman drove the pickup onto Memorial Highway. The officer followed, activated his red and blue flashing lights and stopped the pickup. The officer asked Willman for his driver's license, and when Willman was unable to produce it, the officer asked for his Social Security card and the registration for the motorcycle. The officer radioed the dispatcher and discovered that the motorcycle was registered to *93 Willman, but Willman's driver's license was under revocation.
Willman was charged with driving under revocation in violation of city ordinance. A jury found Willman guilty and Willman appealed.
Willman argues that the trial court erred in refusing to give his requested jury instructions on entrapment and excuse. The City counters that, as a matter of law, the defenses are inapplicable to the strict liability offense of driving under revocation and that, as a matter of fact, the defenses are also inapplicable.
We have recently recognized the availability of an affirmative defense to a strict liability offense. See State v. Michlitsch, 438 N.W.2d 175 (N.D.1989). However, we need not address the City's legal argument that there are no affirmative defenses to the strict liability offense of driving under revocation because if there are, we find the defenses inapplicable under the facts of this case. For a thorough analysis of the legal issue, see State v. Brown, 107 Wis.2d 44, 318 N.W.2d 370 (1982) [defense of legal justification is applicable to speeding violation]; see also Annot., 34 A.L.R.4th 1167 [applicability of the affirmative defense of entrapment to strict liability traffic offenses].
Willman argues that the evidence justified jury instructions on entrapment and excuse. The City asserts that because Willman drove the pickup in the parking lot before he drove in response to the officer's hand signals to move, he committed the offense of driving under revocation before the alleged entrapment occurred, making the entrapment and excuse defenses inapplicable. We agree with the City.

I. Entrapment
Entrapment occurs "when a law enforcement agent induces the commission of an offense, using persuasion or other means likely to cause normally law-abiding persons to commit the offense. Conduct merely affording a person an opportunity to commit an offense does not constitute entrapment." NDCC § 12.1-05-11. The affirmative defense of entrapment requires the defendant to prove, by a preponderance of evidence, that the law enforcement agent induced the commission of a crime and the method of inducement was likely to cause normally law-abiding persons to commit the offense. State v. Weisz, 356 N.W. 2d 462, 464 (N.D.1984); State v. Kluck, 340 N.W.2d 446, 447 (N.D.1983).
A defendant is entitled to an instruction based on a legal defense if there is evidence to support it. State v. Michlitsch, supra; State v. Thiel, 411 N.W.2d 66, 67 (N.D.1987). If no dispute exists over the facts or the inferences to be drawn from the facts, the court may determine the existence of entrapment as a matter of law. State v. Rehling, 426 N.W.2d 6, 7 (N.D.1988); State v. Weisz, supra. In determining whether the jury should have been instructed on a particular defense, we view the evidence in a light most favorable to the defendant. Id.
The evidence, cast in a light most favorable to the defendant, reveals that after Willman drove the pickup from the loading ramp to the access, he stopped and the police officer pulled up behind him. As the officer turned on the interior light in the police car and wrote down the license plate numbers of the vehicles, Willman saw the officer moving his hands and interpreted this movement as a signal or command for Willman to move. Willman testified that he drove the pickup "forward away from him so he could get out. I thought he wanted out." Willman was then stopped and arrested for driving under revocation.
Willman was convicted of violating chapter 9-01, § 19-6 of the ordinances of the city of Mandan. Echoing NDCC § 39-06-42, the ordinance provides:
"1. Except as provided in chapters 39-16 and 39-16.1 and section 39-06.1-11, any person who drives a motor vehicle on a highway or on public or private areas to which the public has a right of access for vehicular use in this state while that person's license or privilege so to do is suspended or revoked is guilty of a class B misdemeanor."
In effect, the trial court determined that the undisputed evidence established, as a *94 matter of law, that Willman drove without a valid license before any entrapment occurred. The trial court refused to give the entrapment instruction, reasoning that "[e]ven if the jury would happen to believe that [the police officer] was waving Mr. Willman on, I believe that falls under ... conduct merely affording a person opportunity to commit an offense. And I just cannot find that that's entrapment." The undisputed fact that Willman drove illegally before any entrapment and the undisputed fact that Willman also drove after the officer's ambiguous hand movements established that the officer's conduct did not induce Willman to violate the law, which he had already violated, but simply provided him with an opportunity to commit another offense. If there is no dispute over the facts or the inferences to be drawn from the facts, the court may determine the existence of entrapment as a matter of law. State v. Weisz, supra.
There is no dispute that Willman drove the pickup in the parking lot, or that the police officer observed Willman driving in the parking lot. This occurred prior to any police involvement. Therefore, the trial court did not err in determining, as a matter of law, there was no entrapment. See Evans v. State, 690 S.W.2d 112, 114 (Tex. Ct.App.1985) [entrapment defense inapplicable where offense committed prior to police involvement]. Both parties agree that Willman's driver's license was under revocation at the time. The only disputed issue was whether the parking lot was, under the ordinance, a public or private area to which the public has a right of access. The trial court ruled this was a question for the jury and neither party asserts that the trial court erred in this regard. Nor does Willman attack the sufficiency of the evidence.
A trial court may properly refuse to submit an inapplicable or irrelevant instruction to the jury. State v. Biby, 366 N.W.2d 460, 465 (N.D.1985). We conclude from the undisputed facts that the trial court did not err in refusing to instruct the jury on entrapment.

II. Excuse
Willman also contends that the trial court erred in refusing to instruct the jury on excuse based upon mistake of fact. See NDCC § 12.1-05-08.
Because an offense was committed prior to any police involvement, we conclude that the excuse defense, like the entrapment defense, is inapplicable and the trial court did not err in refusing to instruct the jury on excuse.
Accordingly, we affirm.
ERICKSTAD, C.J., and MESCHKE, GIERKE and VANDEWALLE, JJ., concur.
