https://wiki.openstreetmap.org/wiki/Relation:enforcement
That's a little more advanced mapping. One way is just to put the speed camera node onto the way itself.
The other way is creating a relation, which is a non-physical feature describing the feature or relation of some physical elements. In the editor you used (iD), the relation can be added by selecting the node (speed camera) and press the '+' at the bottom of your 'edit feature' window. From the dropdown you can select 'New relation' and assign the correct roles to the correct nodes to complete the relation. The wiki has a more extensive description on member features of this relation. I'll fix this one so you have an example :)