Rev 1180 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed
| Rev 1180 | Rev 1242 | ||
|---|---|---|---|
| Line 46... | Line 46... | ||
| 46 | var canMessage = new CanMessage("act", "To_Owner", this.myName, this.myId, "Pwm"); |
46 | var canMessage = new CanMessage("act", "To_Owner", this.myName, this.myId, "Pwm"); |
| 47 | canMessage.setData("Id", sensorId); |
47 | canMessage.setData("Id", sensorId); |
| 48 | canMessage.setData("Value", pwmvalue); |
48 | canMessage.setData("Value", pwmvalue); |
| 49 | sendMessage(canMessage); |
49 | sendMessage(canMessage); |
| 50 | } |
50 | } |
| 51 | softPWM.prototype.configure = function(pwmPeriod, |
51 | softPWM.prototype.configure = function(pwmPeriod, pwmResolution) |
| 52 | { |
52 | { |
| 53 | var canMessage = new CanMessage("act", "To_Owner", this.myName, this.myId, "CONFIG"); |
53 | var canMessage = new CanMessage("act", "To_Owner", this.myName, this.myId, "CONFIG"); |
| 54 | canMessage.setData("Period", pwmPeriod); |
54 | canMessage.setData("Period", pwmPeriod); |
| 55 | canMessage.setData("Resolution", pwmResolution); |
55 | canMessage.setData("Resolution", pwmResolution); |
| 56 | sendMessage(canMessage); |
56 | sendMessage(canMessage); |